Endpoint Get List of Messages for the Current User
Name
get_my_messages
Description
Lists the messages for the current user
Related Tables
Parameters
| Parameter | Required | Options | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Name:
Label: ApiVersion The version of the API to use. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Name:
Label: UserId Enter the Gmail user ID. |
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Name:
Label: Search Expression Expression to return messages matching the specified query. Supports the same query format as the Gmail search box. |
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Name:
Label: IncludeSpamTrash Include messages from SPAM and TRASH in the results. |
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Name:
Label: LabelIds Only return messages with labels that match all of the specified label IDs. Messages in a thread might have labels that other messages in the same thread don't have. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Name:
Label: MaxResults Maximum number of messages to return. This field defaults to 100. The maximum allowed value for this field is 500. |
Output Columns
| Label | Data Type (SSIS) | Data Type (SQL) | Length | Description |
|---|---|---|---|---|
| Id |
DT_WSTR
|
nvarchar(500)
|
500 | |
| Subject |
DT_WSTR
|
nvarchar(300)
|
300 | |
| BodySnippet |
DT_WSTR
|
nvarchar(4000)
|
4000 | |
| To |
DT_WSTR
|
nvarchar(200)
|
200 | |
| ToEmail |
DT_WSTR
|
nvarchar(200)
|
200 | |
| Date |
DT_WSTR
|
nvarchar(200)
|
200 | |
| From |
DT_WSTR
|
nvarchar(200)
|
200 | |
| FromEmail |
DT_WSTR
|
nvarchar(200)
|
200 | |
| PlainTextBody |
DT_NTEXT
|
nvarchar(MAX)
|
||
| HtmlBody |
DT_NTEXT
|
nvarchar(MAX)
|
||
| ContentType |
DT_WSTR
|
nvarchar(200)
|
200 | |
| LabelIds |
DT_WSTR
|
nvarchar(500)
|
500 | |
| ThreadId |
DT_WSTR
|
nvarchar(500)
|
500 | |
| PayloadMimeType |
DT_WSTR
|
nvarchar(200)
|
200 | |
| PayloadBodySize |
DT_I4
|
int
|
||
| SizeEstimate |
DT_I4
|
int
|
||
| HistoryId |
DT_WSTR
|
nvarchar(500)
|
500 | |
| InternalDate |
DT_WSTR
|
nvarchar(200)
|
200 | |
| MessageDate |
DT_DBTIMESTAMP
|
datetime
|
||
| GoogleSmtpSource |
DT_WSTR
|
nvarchar(4000)
|
4000 | |
| ReturnPath |
DT_WSTR
|
nvarchar(500)
|
500 | |
| ReceivedSPF |
DT_WSTR
|
nvarchar(500)
|
500 | |
| Rfc822MessageID |
DT_WSTR
|
nvarchar(200)
|
200 | |
| MIMEVersion |
DT_WSTR
|
nvarchar(20)
|
20 | |
| Mailer |
DT_WSTR
|
nvarchar(200)
|
200 | |
| ThreadIndex |
DT_WSTR
|
nvarchar(500)
|
500 | |
| ContentLanguage |
DT_WSTR
|
nvarchar(100)
|
100 |
Input Columns
| Label | Data Type (SSIS) | Data Type (SQL) | Length | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| There are no Static columns defined for this endpoint. This endpoint detects columns dynamically at runtime. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Examples
SSIS
Use Gmail Connector in API Source or in API Destination SSIS Data Flow components to read or write data.
API Source
This Endpoint belongs to the MyMessages table, therefore it is better to use it, instead of accessing the endpoint directly:
| There are no parameters to configure. |
API Destination
This Endpoint belongs to the MyMessages table, therefore it is better to use it, instead of accessing the endpoint directly. Use this table and table-operation pair to get list of messages for the current user:
| There are no parameters to configure. |
ODBC application
Use these SQL queries in your ODBC application data source:
Get MyMessages
SELECT * FROM MyMessages
get_my_messages endpoint belongs to
MyMessages
table(s), and can therefore be used via those table(s).
SQL Server
Use these SQL queries in SQL Server after you create a data source in Data Gateway:
Get MyMessages
DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM MyMessages';
EXEC (@MyQuery) AT [LS_TO_GMAIL_IN_GATEWAY];
get_my_messages endpoint belongs to
MyMessages
table(s), and can therefore be used via those table(s).