GetMyMessages

Use this call to gather information about the alerts and threaded messages sent to a given user's My Messages mailbox. Depending on the detail level setting, the information returned can include message and alert counts, resolution status and flagged status, message and/or alert headers, and the body text of the messages and alerts.

Note: GetMyMessages requires that you set a DetailLevel in the request. eBay returns an error if you omit a detail level value.

GetMyMessages returns less data than other related API calls, but it returns more message types. For example, GetMemberMessages retrieves messages sent between buyers and sellers about a particular item or transaction. That call provides item details in an Item node (including the ItemID), but it does not retrieve alert information. However, you can parse the data returned in GetMyMessages to get more details. For example, although the item ID isn't directly available in an ItemID node, you can get it by parsing the data in Messages.Message.Text.

GetMyMessages output data is also available as a notification message. See MyMessages Notification for specific information on this, and Working with Platform Notifications for general information on notifications. Be aware that notifications in the Production environment are restricted to certain membership tiers.

To maximize efficiency when working with My Messages, make sure your application can first call GetMyMessages with DetailLevel set to ReturnHeaders. Do not specify any initial alert ID or message ID values. With this call, your application should be able to cache the returned alert ID and message ID values. The application should also be able to create new My Messages requests, with up to ten cached alert ID and message ID values per request.

Request Details

With a detail level of ReturnHeaders or ReturnMessages, GetMyMessages only accepts ten unique alert ID and message ID values per request.

Controlling the Volume of the Response

Depending on the activity of the user, GetMyMessages can return an overwhelming amount of data. To reduce the volume of the response, you can restrict the number of messages returned by adding different filters to your request. Below, are several different filtering methods:

See the Samples section for calls that use these filtering mechanisms.

This call returns the text of the alerts and messages embedded in HTML code. You can parse the content from the HTML, or you can pass along the code as-is, depending on your needs.

Optimizing Your Calls

To make the most of your GetMyMessages calls, make one call with DetailLevel set to ReturnHeaders, without including AlertID or MessageID values. This will return a complete list of alert and message headers with their corresponding alert ID and message ID values. Cache these ID values and use them in a second call to GetMyMessages with DetailLevel set to ReturnMessages. Using this method, you can retrieve details of up to ten specific alerts and ten specific messages at a time.

Testing GetMyMessages

You can test GetMyMessages in the Sandbox.

Several API calls allow you to replenish your supply of messages in the Sandbox. See Sending Messages for information on adding new messages. Contact Developer Support to replenish your supply of alerts and to obtain further testing information.

Related Information

See:
    Communication Between Members
    Notifications for Buyers and Sellers

See also the reference documentation for these calls:



Back to top

GetMyMessages Input

The box below lists all fields that could be included in the call request. To learn more about an individual field or its type, click its name in the box (or scroll down to find it in the table below the box).

See also Samples.

See also the Deprecated Objects link above. Fields presented in this color are deprecated, and fields presented in this color are (or soon will be) non-operational.

The XML prototype does not include requester credentials. This is a documentation limitation only (see Standard Requester Credentials for Making Calls).

<?xml version="1.0" encoding="utf-8"?>
<GetMyMessagesRequest xmlns="urn:ebay:apis:eBLBaseComponents">
  <!-- Standard Input Fields -->
  <DetailLevel> DetailLevelCodeType </DetailLevel>
  <!-- ... more DetailLevel nodes here ... -->
  <ErrorLanguage> string </ErrorLanguage>
  <MessageID> string </MessageID>
  <OutputSelector> string </OutputSelector>
  <!-- ... more OutputSelector nodes here ... -->
  <Version> string </Version>
  <WarningLevel> WarningLevelCodeType </WarningLevel>
  <!-- Call-specific Input Fields -->
  <AlertIDs> MyMessagesAlertIDArrayType 
    <AlertID> MyMessagesAlertIDType (string) </AlertID>
    <!-- ... more AlertID nodes here ... -->
  </AlertIDs>
  <EndTime> dateTime </EndTime>
  <ExternalMessageIDs> MyMessagesExternalMessageIDArrayType 
    <ExternalMessageID> MyMessagesExternalMessageIDType (string) </ExternalMessageID>
    <!-- ... more ExternalMessageID nodes here ... -->
  </ExternalMessageIDs>
  <FolderID> long </FolderID>
  <MessageIDs> MyMessagesMessageIDArrayType 
    <MessageID> MyMessagesMessageIDType (string) </MessageID>
    <!-- ... more MessageID nodes here ... -->
  </MessageIDs>
  <StartTime> dateTime </StartTime>
</GetMyMessagesRequest>
Argument Type Occurrence Meaning
Standard Input Fields   [Jump to call-specific fields]
DetailLevel DetailLevelCodeType Optional,
repeatable: [0..*]
Detail levels are instructions that define standard subsets of data to return for particular data components (e.g., each Item, Transaction, or User) within the response payload. For example, a particular detail level might cause the response to include buyer-related data in every result (e.g., for every Item), but no seller-related data. Specifying a detail level is like using a predefined attribute list in the SELECT clause of an SQL query. Use the DetailLevel element to specify the required detail level that the client application needs pertaining to the data components that are applicable to the request.

The DetailLevelCodeType defines the global list of available detail levels for all request types. Most request types support certain detail levels or none at all. If you pass a detail level that exists in the schema but that isn't valid for a particular request, eBay ignores it processes the request without it. For each request type, see the detail level tables in the Input/Output Reference to determine which detail levels are applicable and which elements are returned for each applicable detail level. (Some detail level tables are still in the eBay Web Services guide. They will be moved to the Input/Output Reference in a future release.)

Note that DetailLevel is required input for GetMyMessages.

With GetSellerList and other calls that retrieve large data sets, please avoid using ReturnAll when possible. For example, if you use GetSellerList, use a GranularityLevel or use the GetSellerEvents call instead. If you do use ReturnAll with GetSellerList, use a small EntriesPerPage value and a short EndTimeFrom/EndTimeTo range for better performance.

Applicable values:

•   ReturnHeaders

(in) Returns message headers. For GetMyMessages, if you include MessageIDs or AlertIDs in the request, this detail level returns header information, without body text, for the specified message ID or alert ID values. If you include a FolderID, header information is returned only for the messages and alerts in the specified folder. If you do not include MessageIDs or AlertIDs, this detail level returns header information for Alerts and Messages as follows: - If all the Alerts have been read, they are sorted in date order, with the most recent first. - If one of the Alerts has not been read, the Read Alerts come first, sorted most recent first, followed by the Unread Alert(s). - All messages in ascending order by date received with the oldest messages first. Note that even when restricted by this detail level to return only header information, GetMyMessages may return a high volume of data.

•   ReturnMessages

(in) Returns full message information. For GetMyMessages, if you include MessageIDs or AlertIDs in the request, this detail level returns message information for the specified message ID or alert ID values. If you include a FolderID, message information is returned only for the messages and alerts in the specified folder.

•   ReturnSummary

(in) Returns the summary data. For GetMyMessages, this detail level returns the same data whether or not you include MessageIDs or AlertIDs in the request. Returns up to 10 FolderID and FolderName values. Currently, this detail level is the only way to retrieve FolderID and FolderName values. See "GetMyMessages" in the eBay Web Services Guide for a code sample that demonstrates this.


(Not all values in DetailLevelCodeType apply to this field.)
ErrorLanguage string Optional Use ErrorLanguage to return error strings for the call in a different language from the language commonly associated with the site that the requesting user is registered with. Specify the standard RFC 3066 language identification tag (e.g., en_US).
ID--- country
----- -----
de_AT Austria
de_CH Switzerland
de_DE Germany
en_AU Australia
en_CA Canada
en_GB United Kingdom
en_SG Singapore
en_US United States
es_ES Spain
fr_BE Belgium (French)
fr_CA Canada (French)
fr_FR France
it_IT Italy
nl_BE Belgium (Dutch)
nl_NL Netherlands
zh_CN China
en_IN India
en_IE Ireland
zh_HK Hong Kong

See Tags for the Identification of Languages.

MessageID string Optional In most cases, all calls support a MessageID element in the request and a CorrelationID element in the response. If you pass a message ID in a request, we will return the same value in CorrelationID in the response. You can use this for tracking that a response is returned for every request and to match particular responses to particular requests. If you do not pass MessageID in the request, CorrelationID is not returned.

Note: GetCategories, GetAttributesCS, GetCategory2CS, GetAttributesXSL, GetProductFinder, GetProductFinderXSL, and GetProductSearchPage are designed to retrieve very large sets of metadata that change once a day or less often. To improve performance, these calls return cached responses when you request all available data (with no filters). When this occurs, the MessageID and CorrelationID fields aren't applicable. However, if you specify an input filter to reduce the amount of data returned, the calls retrieve the latest data (not cached). When this occurs, MessageID and CorrelationID are applicable.
OutputSelector string Optional,
repeatable: [0..*]
You can use the OutputSelector field to restrict the data returned by this call. When you make a call such as GetItem that retrieves data from eBay, the OutputSelector field is useful for restricting the data returned. This field makes the call response easier to use, especially when a large payload would be returned. If you use the OutputSelector field, the output data will include only the fields you specified in the request. For example, if you are using GetItem and you want the item data in the response to be restricted to the ViewItemURL (the URL where a user can view the listing) and BuyItNowPrice, then within the GetItem request, specify those output fields. To use this field, see the information at the following link.

See Selecting Fields to Retrieve.

Version string Conditional The version number of the API code that you are programming against (e.g., 549). The version you specify for a call has these basic effects:
- It indicates the version of the code lists and other data that eBay should use to process your request.
- It indicates the schema version you are using.
You need to use a version that is greater than or equal to the lowest supported version.

For the SOAP API: If you are using the SOAP API, this field is required. Specify the version of the WSDL your application is using.

For the XML API: If you are using the XML API, this field has no effect. Instead, specify the version in the X-EBAY-API-COMPATIBILITY-LEVEL HTTP header. (If you specify Version in the body of an XML API request and it is different from the value in the HTTP header, eBay returns an informational warning that the value in the HTTP header was used instead.)

See:
    HTTP Headers (XML API Only)
    eBay Schema Versioning Strategy
    Lowest Supported Version

WarningLevel WarningLevelCodeType Optional Controls whether or not to return warnings when the application passes unrecognized or deprecated elements in a request.

An unrecognized element is one that is not defined in any supported version of the schema. Schema element names are case-sensitive, so using WarningLevel can also help you remove any potential hidden bugs within your application due to incorrect case or spelling in field names before you put your application into the Production environment.

WarningLevel only validates elements; it doesn't validate XML attributes. It also doesn't control warnings related to user-entered strings or numbers, or warnings for logical errors.

We recommend that you only use this during development and debugging. Do not use this in requests in your production code.

Applicable values:

•   High

(in) Return warnings when the application passes unrecognized or deprecated elements in a request.

•   Low

(in) Do not return warnings when the application passes unrecognized or deprecated elements in a request. This is the default value if WarningLevel is not specified.


See Warning Level.

Call-specific Input Fields
AlertIDs MyMessagesAlertIDArrayType Conditional Contains a list of up to 10 AlertID values. When AlertID values are used as input, you must generally specify either AlertID values, or MessageID values, or both.
AlertIDs.AlertID MyMessagesAlertIDType (string) Conditional,
repeatable: [0..*]
An ID that uniquely identifies an alert for a given user. When AlertID values are used as input, you must generally specify either AlertID values, or MessageID values, or both.
EndTime dateTime Conditional Used as end of date range filter.
ExternalMessageIDs MyMessagesExternalMessageIDArrayType Optional This field is currently available on the US site. A container for IDs that uniquely identify messages for a given user. If provided at the time of message creation, this ID can be used to retrieve messages and will take precedence over message ID.
ExternalMessageIDs
  .ExternalMessageID
MyMessagesExternalMessageIDType (string) Optional,
repeatable: [0..*]
Currently available on the US site. A message ID that uniquely identifies a message for a given user. If provided at the time of message creation, this ID can be used to retrieve messages, and will take precedence over the message ID. A total of 10 message IDs can be specified.
FolderID long Optional An ID that uniquely identifies the My Messages folder from which to retrieve alerts or messages.
MessageIDs MyMessagesMessageIDArrayType Conditional Contains a list of up to 10 MessageID values. When MessageID values are used as input, you must generally specify either AlertID values, or MessageID values, or both.
MessageIDs.MessageID MyMessagesMessageIDType (string) Conditional,
repeatable: [0..*]
An ID that uniquely identifies a message for a given user. When MessageID values are used as input, you must generally specify either AlertID values, or MessageID values, or both.
StartTime dateTime Optional Used as beginning of date range filter.



Back to top

GetMyMessages Output

The box below lists all fields that might be returned in the response. To learn more about an individual field or its type, click its name in the box (or scroll down to find it in the table below the box).

See also Samples.

See also the Deprecated Objects link above. Fields presented in this color are deprecated, and fields presented in this color are not returned (or soon will not be returned) or are not operational (or soon will be non-operational).

The XML prototype does not include requester credentials. This is a documentation limitation only (see Standard Requester Credentials for Making Calls).

<?xml version="1.0" encoding="utf-8"?>
<GetMyMessagesResponse xmlns="urn:ebay:apis:eBLBaseComponents">
  <!-- Standard Output Fields -->
  <Ack> AckCodeType </Ack>
  <Build> string </Build>
  <CorrelationID> string </CorrelationID>
  <Errors> ErrorType 
    <ErrorClassification> ErrorClassificationCodeType </ErrorClassification>
    <ErrorCode> token </ErrorCode>
    <ErrorParameters ParamID="string"> ErrorParameterType 
      <Value> string </Value>
    </ErrorParameters>
    <!-- ... more ErrorParameters nodes here ... -->
    <LongMessage> string </LongMessage>
    <SeverityCode> SeverityCodeType </SeverityCode>
    <ShortMessage> string </ShortMessage>
  </Errors>
  <!-- ... more Errors nodes here ... -->
  <HardExpirationWarning> string </HardExpirationWarning>
  <Timestamp> dateTime </Timestamp>
  <Version> string </Version>
  <!-- Call-specific Output Fields -->
  <Alerts> MyMessagesAlertArrayType 
    <Alert> MyMessagesAlertType 
      <ActionURL> string </ActionURL>
      <AlertID> MyMessagesAlertIDType (string) </AlertID>
      <ExpirationDate> dateTime </ExpirationDate>
      <ExternalAlertID> string </ExternalAlertID>
      <Folder> MyMessagesFolderType 
        <FolderID> long </FolderID>
      </Folder>
      <ForwardDetails> MyMessagesForwardDetailsType 
        <ForwardMessageEncoding> string </ForwardMessageEncoding>
        <UserForwardDate> dateTime </UserForwardDate>
      </ForwardDetails>
      <IsTimedResolution> boolean </IsTimedResolution>
      <ItemID> ItemIDType (string) </ItemID>
      <LastReadDate> dateTime </LastReadDate>
      <Priority> string </Priority>
      <Read> boolean </Read>
      <ReceiveDate> dateTime </ReceiveDate>
      <RecipientUserID> string </RecipientUserID>
      <ResolutionStatus> MyMessagesAlertResolutionStatusCode </ResolutionStatus>
      <ResponseDetails> MyMessagesResponseDetailsType 
        <ResponseEnabled> boolean </ResponseEnabled>
        <ResponseURL> anyURI </ResponseURL>
      </ResponseDetails>
      <Sender> string </Sender>
      <Subject> string </Subject>
      <Text> string </Text>
    </Alert>
    <!-- ... more Alert nodes here ... -->
  </Alerts>
  <Messages> MyMessagesMessageArrayType 
    <Message> MyMessagesMessageType 
      <Content> string </Content>
      <ExpirationDate> dateTime </ExpirationDate>
      <ExternalMessageID> string </ExternalMessageID>
      <Flagged> boolean </Flagged>
      <Folder> MyMessagesFolderType 
        <FolderID> long </FolderID>
      </Folder>
      <ForwardDetails> MyMessagesForwardDetailsType 
        <ForwardMessageEncoding> string </ForwardMessageEncoding>
        <UserForwardDate> dateTime </UserForwardDate>
      </ForwardDetails>
      <ItemID> ItemIDType (string) </ItemID>
      <ListingStatus> ListingStatusCodeType </ListingStatus>
      <MessageID> MyMessagesMessageIDType (string) </MessageID>
      <MessageType> MessageTypeCodeType </MessageType>
      <QuestionType> QuestionTypeCodeType </QuestionType>
      <Read> boolean </Read>
      <ReceiveDate> dateTime </ReceiveDate>
      <RecipientUserID> string </RecipientUserID>
      <ResponseDetails> MyMessagesResponseDetailsType 
        <ResponseEnabled> boolean </ResponseEnabled>
        <ResponseURL> anyURI </ResponseURL>
      </ResponseDetails>
      <Sender> string </Sender>
      <SendToName> string </SendToName>
      <Subject> string </Subject>
      <Text> string </Text>
    </Message>
    <!-- ... more Message nodes here ... -->
  </Messages>
  <Summary> MyMessagesSummaryType 
    <FlaggedMessageCount> int </FlaggedMessageCount>
    <FolderSummary> MyMessagesFolderSummaryType 
      <FolderID> long </FolderID>
      <FolderName> string </FolderName>
      <NewAlertCount> int </NewAlertCount>
      <NewMessageCount> int </NewMessageCount>
      <TotalAlertCount> int </TotalAlertCount>
      <TotalMessageCount> int </TotalMessageCount>
    </FolderSummary>
    <!-- ... more FolderSummary nodes here ... -->
    <NewAlertCount> int </NewAlertCount>
    <NewMessageCount> int </NewMessageCount>
    <TotalAlertCount> int </TotalAlertCount>
    <TotalMessageCount> int </TotalMessageCount>
    <UnresolvedAlertCount> int </UnresolvedAlertCount>
  </Summary>
</GetMyMessagesResponse>
Return Value Type Occurrence Meaning
Standard Output Fields   [Jump to call-specific fields]
Ack AckCodeType Always A token representing the application-level acknowledgement code that indicates the response status (e.g., success). The AckCodeType list specifies the possible values for Ack.

Applicable values:

•   CustomCode

(out) Reserved for internal or future use.

•   Failure

(out) Request processing failed

•   Success

(out) Request processing succeeded

•   Warning

(out) Request processing completed with warning information being included in the response message


(Not all values in AckCodeType apply to this field.)
Build string Always This refers to the specific software build that eBay used when processing the request and generating the response. This includes the version number plus additional information. eBay Developer Support may request the build information when helping you resolve technical issues.
CorrelationID string Conditionally In most cases, all calls support a MessageID element in the request and a CorrelationID element in the response. If you pass a message ID in a request, we will return the same value in CorrelationID in the response. You can use this for tracking that a response is returned for every request and to match particular responses to particular requests. If you do not pass MessageID in the request, CorrelationID is not returned.

Note: GetCategories, GetAttributesCS, GetCategory2CS, GetAttributesXSL, GetProductFinder, GetProductFinderXSL, and GetProductSearchPage are designed to retrieve very large sets of metadata that change once a day or less often. To improve performance, these calls return cached responses when you request all available data (with no filters). When this occurs, the MessageID and CorrelationID fields aren't applicable. However, if you specify an input filter to reduce the amount of data returned, the calls retrieve the latest data (not cached). When this occurs, MessageID and CorrelationID are applicable.
Errors ErrorType Conditionally,
repeatable: [0..*]
A list of application-level errors (if any) that occurred when eBay processed the request.

See Error Handling.

Errors.ErrorClassification ErrorClassificationCodeType Conditionally API errors are divided between two classes: system errors and request errors.

Applicable values:

•   CustomCode

(out) Reserved for internal or future use.

•   RequestError

(out) An error has occurred either as a result of a problem in the sending application or because the application's end-user has attempted to submit invalid data (or missing data). In these cases, do not retry the request. The problem must be corrected before the request can be made again. If the problem is due to something in the application (such as a missing required field), the application must be changed. If the problem is a result of end-user data, the application must alert the end-user to the problem and provide the means for the end-user to correct the data. Once the problem in the application or data is resolved, resend the request to eBay with the corrected data.

•   SystemError

(out) Indicates that an error has occurred on the eBay system side, such as a database or server down. An application can retry the request as-is a reasonable number of times (eBay recommends twice). If the error persists, contact Developer Technical Support. Once the problem has been resolved, the request may be resent in its original form.


Errors.ErrorCode token Conditionally A unique code that identifies the particular error condition that occurred. Your application can use error codes as identifiers in your customized error-handling algorithms. See the "Errors by Number" document.
Errors.ErrorParameters ErrorParameterType Conditionally,
repeatable: [0..*]
This optional element carries a list of context-specific error variables that indicate details about the error condition. These are useful when multiple instances of ErrorType are returned.
Errors.ErrorParameters
  [ attribute ParamID ]
string Conditionally The index of the parameter in the list of parameter types returned within the error type.
Errors.ErrorParameters.Value string Conditionally The value of the variable (e.g., the attribute set ID)
Errors.LongMessage string Conditionally A more detailed description of the condition that raised the error.
Errors.SeverityCode SeverityCodeType Conditionally Indicates whether the error is a severe error (causing the request to fail) or an informational error (a warning) that should be communicated to the user.

Applicable values:

•   CustomCode

(out) Reserved for internal or future use

•   Error

(out) Application-level error

•   Warning

(out) Warning or informational error


Errors.ShortMessage string Conditionally A brief description of the condition that raised the error.
HardExpirationWarning string Conditionally Expiration date of the user's authentication token. Only returned within the 7-day period prior to a token's expiration. To ensure that user authentication tokens are secure and to help avoid a user's token being compromised, tokens have a limited life span. A token is only valid for a period of time (set by eBay). After this amount of time has passed, the token expires and must be replaced with a new token.
Timestamp dateTime Always This value represents the date and time when eBay processed the request. The time zone of this value is GMT and the format is the ISO 8601 date and time format (YYYY-MM-DDTHH:MM:SS.SSSZ). See Time Values in the eBay Web Services guide for information about this time format and converting to and from the GMT time zone.

Note: GetCategories, GetAttributesCS, GetCategory2CS, GetAttributesXSL, GetProductFinder, GetProductFinderXSL, and GetProductSearchPage are designed to retrieve very large sets of metadata that change once a day or less often. To improve performance, these calls return cached responses when you request all available data (with no filters). When this occurs, this time value reflects the time the cached response was created. Thus, this value is not necessarily when the request was processed. However, if you specify an input filter to reduce the amount of data returned, the calls retrieve the latest data (not cached). When this occurs, this time value does reflect when the request was processed.
Version string Always The version of the response payload schema. Indicates the version of the schema that eBay used to process the request. See "Standard Data for All Calls" in the eBay Web Services Guide for information on using the response version when troubleshooting "CustomCode" values that appear in the response.
Call-specific Output Fields
Alerts MyMessagesAlertArrayType Conditionally Contains the alert information for each alert specified in AlertIDs. The amount and type of information returned varies based on the requested detail level. Contains one MyMessagesAlertType object per alert. Returned as an empty node if user has no alerts.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert MyMessagesAlertType Conditionally,
repeatable: [0..*]
Contains the data for one alert. Returned for detail levels ReturnHeaders and ReturnMessages. Parent returned as an empty node if user has no alerts.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ActionURL string Conditionally A URL that the recipient must visit to resolve an alert. May be returned as an empty tag if there is no applicable URL.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.AlertID MyMessagesAlertIDType (string) Conditionally An ID that uniquely identifies an alert for a given user.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ExpirationDate dateTime Conditionally The date and time at which an alert expires.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ExternalAlertID string Conditionally An ID used by an external application to uniquely identify an alert.

DetailLevel: ReturnHeaders.
Alerts.Alert.Folder MyMessagesFolderType Conditionally Details relating to a My Messages folder.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.Folder.FolderID long Conditionally An ID that uniquely identifies a My Messages folder.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ForwardDetails MyMessagesForwardDetailsType Conditionally Details relating to the forwarding of an alert or message. Only returned if the alert or message is forwarded.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ForwardDetails
  .ForwardMessageEncoding
string Conditionally Encoding used to forward an alert or message.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ForwardDetails
  .UserForwardDate
dateTime Conditionally The date and time a user forwarded an alert or message.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.IsTimedResolution boolean Conditionally Indicates whether or not a time-delayed resolution is applicable for an alert.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ItemID ItemIDType (string) Conditionally A unique eBay item ID associated with an alert.
Max length: 19 (Note: The eBay database specifies 38. Currently, Item IDs are usually 9 to 12 digits).

DetailLevel: ReturnHeaders.
Alerts.Alert.LastReadDate dateTime Conditionally The date and time an alert was last viewed by a given user.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.Priority string Conditionally A number ranging from 0 to 10000 (inclusive), with 10000 having the highest priority.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.Read boolean Conditionally Whether or not an alert was viewed by a given user. Note that retrieving an alert with the API does not mark it as read.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ReceiveDate dateTime Conditionally The date and time that an alert was received by My Messages and stored in a database for the recipient.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.RecipientUserID string Conditionally The displayable user ID of the recipient.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ResolutionStatus MyMessagesAlertResolutionStatusCode Conditionally Whether or not an alert was resolved, and how.

Applicable values:

•   CustomCode

(out)

•   ResolvedByAutoResolution

(out) The alert was resolved by auto resolution, for example, by expiring after a certain date.

•   ResolvedByUser

(out) The alert was resolved by user. If the alert requires user action, resolved status means that the user took the necessary action on the alert. If the alert does not require user action, resolved status means that the alert was read by the user.

•   Unresolved

(out) The alert has not been resolved. If the alert requires user action, an unresolved status means that the user did not take action on the alert. If the alert does not require user action, an unresolved status means that the alert has not been read. Note that an unresolved alert can not be deleted.




DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ResponseDetails MyMessagesResponseDetailsType Conditionally Details relating to the response to an alert or message.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ResponseDetails
  .ResponseEnabled
boolean Conditionally Whether or not an alert or message can be responded to. To respond to an alert or message, use the URL in ResponseURL. You may need to log into the eBay Web site to complete the response.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.ResponseDetails
  .ResponseURL
anyURI Conditionally A URL that the recipient must visit to respond to an alert or message. Responding may require logging into the eBay Web site.

DetailLevel: ReturnMessages.
Alerts.Alert.Sender string Conditionally The display name of the eBay application that sends the alert.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.Subject string Conditionally The subject of the alert.

DetailLevel: ReturnHeaders, ReturnMessages.
Alerts.Alert.Text string Conditionally The alert body. This can be either plain text or HTML, depending on which format the alert was originally written in. Note that the API does not currently check the user email format preferences that can be specified in My Messages on the eBay.com Web site.

DetailLevel: ReturnMessages.
Messages MyMessagesMessageArrayType Conditionally Contains the message information for each message specified in MessageIDs. The amount and type of information returned varies based on the requested detail level. Contains one MyMessagesMessageType object per message. Returned as an empty node if user has no messages.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message MyMessagesMessageType Conditionally,
repeatable: [0..*]
Contains the data for one message.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Content string Conditionally The message body. Plain text. The API does not currently check the user email format preferences that can be specified in My Messages on the eBay.com Web site.

DetailLevel: ReturnMessages.
Messages.Message
  .ExpirationDate
dateTime Conditionally The date and time at which a message expires.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ExternalMessageID
string Conditionally An ID used by an external application to uniquely identify a message. Returned only when specified by the external application on message creation.

This value is equivalent to the value used for MessageID in GetMemberMessages.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Flagged boolean Conditionally Whether or not a message has been flagged.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Folder MyMessagesFolderType Conditionally Details relating to a My Messages folder.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Folder
  .FolderID
long Conditionally An ID that uniquely identifies a My Messages folder.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ForwardDetails
MyMessagesForwardDetailsType Conditionally Details relating to the forwarding of an alert or message. Only returned if the alert or message is forwarded.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ForwardDetails
  .ForwardMessageEncoding
string Conditionally Encoding used to forward an alert or message.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ForwardDetails
  .UserForwardDate
dateTime Conditionally The date and time a user forwarded an alert or message.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.ItemID ItemIDType (string) Conditionally A unique eBay Item ID associated with a message.
Max length: 19 (Note: The eBay database specifies 38. Currently, Item IDs are usually 9 to 12 digits).

DetailLevel: ReturnHeaders.
Messages.Message.ListingStatus ListingStatusCodeType Conditionally Coming soon. Specifies an active or ended listing's status in eBay's processing workflow. If a listing ends with a sale (or sales), eBay needs to update the sale details (e.g., total price and buyer/high bidder) and the final value fee. This processing can take several minutes. If you retrieve a sold item and no details about the buyer/high bidder are returned or no final value fee is available, use this listing status information to determine whether eBay has finished processing the listing.

Note: For GetMyMessages, the listing status reflects the status of the listing at the time the question was created. The listing status for this call must not match the listing status returned by other calls (such as GetItemTransactions). This is returned only if Messages.Message.MessageType is AskSellerQuestion. This tag is no longer returned in the Sandbox environment.

Applicable values:

•   Active

(out) The listing is still active or the listing has ended with a sale but eBay has not completed processing the sale details (e.g., total price and high bidder). A multi-item listing is considered active until all items have winning bids or purchases or the listing ends with at least one winning bid or purchase. If the listing has ended with a sale but this Active status is returned, please allow several minutes for eBay to finish processing the listing.

•   Completed

(out) The listing has closed and eBay has completed processing the sale. All sale information returned from eBay (e.g., total price and high bidder) should be considered accurate and complete. Although the Final Value Fee (FVF) for FixedPriceItem and StoresFixedPrice items is returned by GetSellerTransactions and GetItemTransactions, all other listing types (excluding Buy It Now purchases) require the listing status to be Completed before the Final Value Fee is returned.

Dutch (multi-listing) Buy It Now auctions are Completed on a transaction-by-transaction basis, and the Final Value Fee is returned by GetSellerTransactions and GetItemTransactions.

Note: As of version 619, Dutch-style (multi-item) competitive-bid auctions are deprecated. eBay throws an error if you submit a Dutch item listing with AddItem or VerifyAddItem. If you use RelistItem to update a Dutch auction listing, eBay generates a warning and resets the Quantity value to 1.

•   Custom

(out) Reserved for internal or future use.

•   CustomCode

(out) Reserved for internal or future use.

•   Ended

(out) The listing has ended. If the listing ended with a sale, eBay has completed processing of the sale. All sale information returned from eBay (e.g., total price and high bidder) should be considered accurate and complete. However, the final value fee is not yet available.


Messages.Message.MessageID MyMessagesMessageIDType (string) Conditionally An ID that uniquely identifies a message for a given user.

This value is not the same as the value used for the GetMemberMessages MessageID. Use the GetMemberMessages value (used as the GetMyMessages ExternalID) instead.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.MessageType MessageTypeCodeType Conditionally Currently available on the US site. Specifies the type of message being retrieved through GetMyMessages.

Applicable values:

•   All

(in/out) All message types.

•   AskSellerQuestion

(in/out) Member to Member message initiated by bidder/potential bidder to a seller of a particular item.

•   ContactEbayMember

(in/out) Member to Member message initiated by any eBay member to another eBay member.

•   ContacteBayMemberViaAnonymousEmail

(in/out) Member message initiated after eBay receives an email sent by an eBay member's email client to another eBay member.

•   ContacteBayMemberViaCommunityLink

(in/out) Member to Member message initiated by any eBay member to another eBay member who has posted on a community forum within the past 7 days.

•   ContactMyBidder

(in/out) Member to Member message initiated by sellers to their bidders during an active listing.

•   ContactTransactionPartner

(in/out) Member message between transaction partners within 90 days after the transaction.

•   CustomCode

(in/out) Reserved for future or internal use.

•   ResponseToASQQuestion

(in/out) Member to Member message initiated as a response to an Ask A Question message.

•   ResponseToContacteBayMember

(in/out) Member to Member message initiated as a response to a Contact eBay Member message.


Messages.Message.QuestionType QuestionTypeCodeType Conditionally Coming soon. Currently available on the US site. Specifies the context of the question. Corresponds to the message subject. Applies if Messages.Message.MessageType is AskSellerQuestion.

Applicable values:

•   CustomCode

(in/out) Reserved for future or internal use.

•   CustomizedSubject

(in/out) Customized subjects set by the seller using SetMessagePreferences or the eBay Web site.

•   General

(in/out) General questions about the item.

•   MultipleItemShipping

(in/out) Questions related to the shipping of this item bundled with other items also purchased on eBay.

•   None

(in/out) No question type applies. The QuestionTypeCodeType value of None is applicable when Messages.Message.MessageType isn't set to AskSellerQuestion.

•   Payment

(in/out) Questions related to the payment for the item.

•   Shipping

(in/out) Questions related to the shipping of the item.


Messages.Message.Read boolean Conditionally Whether or not a message has been viewed by a given user. Note that retrieving a message with the API does not mark it as read.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.ReceiveDate dateTime Conditionally The date and time that a message was received by My Messages and stored in a database for the recipient.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .RecipientUserID
string Conditionally The displayable user ID of the recipient.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ResponseDetails
MyMessagesResponseDetailsType Conditionally Details relating to the response to an alert or message.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ResponseDetails
  .ResponseEnabled
boolean Conditionally Whether or not an alert or message can be responded to. To respond to an alert or message, use the URL in ResponseURL. You may need to log into the eBay Web site to complete the response.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message
  .ResponseDetails.ResponseURL
anyURI Conditionally A URL that the recipient must visit to respond to an alert or message. Responding may require logging into the eBay Web site.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Sender string Conditionally The display name of the eBay user that sent the message.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.SendToName string Conditionally The displayable name of the user or eBay application to which the message is sent. Only returned for M2M, and if a value exists.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Subject string Conditionally The subject of the message.

DetailLevel: ReturnHeaders, ReturnMessages.
Messages.Message.Text string Conditionally This field contains message content, and can contain a threaded message. This field can contain plain text or HTML, depending on the format of the original message. The API does not check the email-format preferences in My Messages on the eBay Web site.
Max length: 2 megabytes in size.

DetailLevel: ReturnMessages.
Summary MyMessagesSummaryType Conditionally Summary data for a given user's alerts and messages. This includes the numbers of new alerts and messages, unresolved alerts, flagged messages, and total alerts and messages. The amount and type of data returned is the same whether or not the request included specific AlertID or MessageID values. Always/Conditionally returned logic assumes a detail level of ReturnMessages.

DetailLevel: ReturnSummary.
Summary.FlaggedMessageCount int Conditionally The number of messages that have been flagged. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.FolderSummary MyMessagesFolderSummaryType Conditionally,
repeatable: [0..*]
Folder summary for each folder. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.FolderSummary.FolderID long Conditionally An ID that uniquely identifies a My Messages folder. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.FolderSummary
  .FolderName
string Conditionally The name of a specified My Messages folder. For GetMyMessages, Inbox (FolderID = 0) and Sent (FolderID = 1) are not returned.

DetailLevel: ReturnSummary.
Summary.FolderSummary
  .NewAlertCount
int Conditionally The number of new alerts in a given folder. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.FolderSummary
  .NewMessageCount
int Conditionally The number of new messages in a given folder. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.FolderSummary
  .TotalAlertCount
int Conditionally The total number of alerts in a given folder. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.FolderSummary
  .TotalMessageCount
int Conditionally The total number of messages in a given folder. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.NewAlertCount int Conditionally The number of new alerts that a given user has. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.NewMessageCount int Conditionally The number of new messages that a given user has. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.TotalAlertCount int Conditionally The total number of alerts for a given user. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.TotalMessageCount int Conditionally The total number of messages for a given user. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.
Summary.UnresolvedAlertCount int Conditionally The number of alerts that are not yet resolved. Always returned for detail level ReturnSummary.

DetailLevel: ReturnSummary.



Back to top

GetMyMessages Detail Controls


Detail Control: DetailLevel

The DetailLevel input field influences which call-specific fields may be returned. (All standard output fields are returned regardless of DetailLevel.)

The none column indicates the fields that are returned when you do not specify a DetailLevel.

YThe field is always returned.
(Y)The field is conditionally returned. See the field description for clarification of conditions.
-The field is not returned.

Output Field ReturnHeaders ReturnMessages ReturnSummary
Alerts(Y)(Y)-
Alerts.Alert(Y)(Y)-
Alerts.Alert.ActionURL(Y)(Y)-
Alerts.Alert.AlertID(Y)(Y)-
Alerts.Alert.ExpirationDate(Y)(Y)-
Alerts.Alert.ExternalAlertID(Y)--
Alerts.Alert.Folder(Y)(Y)-
Alerts.Alert.Folder.FolderID(Y)(Y)-
Alerts.Alert.ForwardDetails(Y)(Y)-
Alerts.Alert.ForwardDetails.ForwardMessageEncoding(Y)(Y)-
Alerts.Alert.ForwardDetails.UserForwardDate(Y)(Y)-
Alerts.Alert.IsTimedResolution(Y)(Y)-
Alerts.Alert.ItemID(Y)--
Alerts.Alert.LastReadDate(Y)(Y)-
Alerts.Alert.Priority(Y)(Y)-
Alerts.Alert.Read(Y)(Y)-
Alerts.Alert.ReceiveDate(Y)(Y)-
Alerts.Alert.RecipientUserID(Y)(Y)-
Alerts.Alert.ResolutionStatus(Y)(Y)-
Alerts.Alert.ResponseDetails(Y)(Y)-
Alerts.Alert.ResponseDetails.ResponseEnabled(Y)(Y)-
Alerts.Alert.ResponseDetails.ResponseURL-(Y)-
Alerts.Alert.Sender(Y)(Y)-
Alerts.Alert.Subject(Y)(Y)-
Alerts.Alert.Text-(Y)-
Messages(Y)(Y)-
Messages.Message(Y)(Y)-
Messages.Message.Content-(Y)-
Messages.Message.ExpirationDate(Y)(Y)-
Messages.Message.ExternalMessageID(Y)(Y)-
Messages.Message.Flagged(Y)(Y)-
Messages.Message.Folder(Y)(Y)-
Messages.Message.Folder.FolderID(Y)(Y)-
Messages.Message.ForwardDetails(Y)(Y)-
Messages.Message.ForwardDetails.ForwardMessageEncoding(Y)(Y)-
Messages.Message.ForwardDetails.UserForwardDate(Y)(Y)-
Messages.Message.ItemID(Y)--
Messages.Message.MessageID(Y)(Y)-
Messages.Message.Read(Y)(Y)-
Messages.Message.ReceiveDate(Y)(Y)-
Messages.Message.RecipientUserID(Y)(Y)-
Messages.Message.ResponseDetails(Y)(Y)-
Messages.Message.ResponseDetails.ResponseEnabled(Y)(Y)-
Messages.Message.ResponseDetails.ResponseURL(Y)(Y)-
Messages.Message.Sender(Y)(Y)-
Messages.Message.SendToName(Y)(Y)-
Messages.Message.Subject(Y)(Y)-
Messages.Message.Text-(Y)-
Summary--(Y)
Summary.FlaggedMessageCount--(Y)
Summary.FolderSummary--(Y)
Summary.FolderSummary.FolderID--(Y)
Summary.FolderSummary.FolderName--(Y)
Summary.FolderSummary.NewAlertCount--(Y)
Summary.FolderSummary.NewMessageCount--(Y)
Summary.FolderSummary.TotalAlertCount--(Y)
Summary.FolderSummary.TotalMessageCount--(Y)
Summary.NewAlertCount--(Y)
Summary.NewMessageCount--(Y)
Summary.TotalAlertCount--(Y)
Summary.TotalMessageCount--(Y)
Summary.UnresolvedAlertCount--(Y)



Back to top

GetMyMessages Samples

New to making API calls? Please see Routing the Request.

Note: Some item IDs, user IDs, or other data in these samples might no longer be active on eBay. If necessary, you can substitute current eBay data in your requests.

Available samples:

Sample: Basic Call

Retrieves Alert and Message headers for the authenticated user.

Description

This sample shows how to retrieve the headers for messages and alerts. Once retrieved, you can cache the AlertID and MessageID values, which you can then use to get more details on specific messages with another GetMyMessages call.

Input

XML format (HTTP POST). Also available is the .txt version of this XML.

<?xml version="1.0" encoding="utf-8"?>
<GetMyMessagesRequest xmlns="urn:ebay:apis:eBLBaseComponents">
  <RequesterCredentials>
    <eBayAuthToken>ABC...123</eBayAuthToken>
  </RequesterCredentials>
  <WarningLevel>High</WarningLevel>
  <DetailLevel>ReturnHeaders</DetailLevel>
</GetMyMessagesRequest>

Output

XML format. Also available is the .txt version of this XML.

<GetMyMessagesResponse xmlns="urn:ebay:apis:eBLBaseComponents">
  <Timestamp>2010-02-19T17:46:17.619Z</Timestamp>
  <Ack>Success</Ack>
  <Version>655</Version>
  <Build>E655_CORE_BUNDLED_10639415_R1</Build>
  <Alerts/>
  <Messages>
    <Message>
      <Sender>bigbuyer</Sender>
      <SendingUserID>132952146</SendingUserID>
      <RecipientUserID>magicalbookseller</RecipientUserID>
      <SendToName>magicalbookseller</SendToName>
      <Subject>bigbuyer has sent a question about item #110043598202,
          ending on Feb-18-10 18:52:35 PST - Acura : CL</Subject>
      <MessageID>1095480</MessageID>
      <ExternalMessageID>763010</ExternalMessageID>
      <Flagged>false</Flagged>
      <Read>false</Read>
      <ReceiveDate>2010-02-12T02:54:32.000Z</ReceiveDate>
      <ExpirationDate>2011-02-12T02:54:31.000Z</ExpirationDate>
      <ItemID>110043598202</ItemID>
      <ResponseDetails>
        <ResponseEnabled>true</ResponseEnabled>
        <ResponseURL>http://contact.sandbox.ebay.com/ws/eBayISAPI.dll?M2MContact&
            item=110043598202&requested=bigbuyer&qid=763010&redirect=0&messageid=m1095480</ResponseURL>
      </ResponseDetails>
      <Folder>
        <FolderID>0</FolderID>
      </Folder>
      <Replied>false</Replied>
    </Message>
    <Message>
      <Sender>bountifulbuyer</Sender>
      <SendingUserID>132952146</SendingUserID>
      <RecipientUserID>magicalbookseller</RecipientUserID>
      <SendToName>magicalbookseller</SendToName>
      <Subject>bountifulbuyer has sent a question about :Question about book Edition for item #110043547115,
          ending on Feb-16-10 15:45:13 PST - Harry Potter and the Philosopher's Stone</Subject>
      <MessageID>1095270</MessageID>
      <ExternalMessageID>762802</ExternalMessageID>
      <Flagged>false</Flagged>
      <Read>false</Read>
      <ReceiveDate>2010-02-10T18:03:43.000Z</ReceiveDate>
      <ExpirationDate>2011-02-10T18:03:43.000Z</ExpirationDate>
      <ItemID>110043547115</ItemID>
      <ResponseDetails>
        <ResponseEnabled>true</ResponseEnabled>
        <ResponseURL>http://contact.sandbox.ebay.com/ws/eBayISAPI.dll?M2MContact&
            item=110043547115&requested=bountifulbuyer&qid=762802&redirect=0&messageid=m1095270</ResponseURL>
        <UserResponseDate>2010-02-10T18:51:33.000Z</UserResponseDate>
      </ResponseDetails>
      <Folder>
        <FolderID>0</FolderID>
      </Folder>
      <Replied>true</Replied>
    </Message>
  </Messages>
</GetMyMessagesResponse>

Back to list of samples

Sample: Specific Message IDs

Retrieves specific Messages and Alerts, according to the provided message ID values.

Description

Retrieve a summary of your messages and alerts by calling GetMyMessages with DetailLevel set to ReturnHeaders. Make a second call to GetMyMessages with DetailLevel set to ReturnMessages, and specify the alert and message ID values of the messages you want to review. This returns detailed information for each specified alert and message.

Input

You can specify up to to 10 AlertID values and MessageID values per request.

XML format (HTTP POST). Also available is the .txt version of this XML.

<?xml version="1.0" encoding="utf-8"?> 
<GetMyMessagesRequest xmlns="urn:ebay:apis:eBLBaseComponents"> 
  <Version>467</Version> 
  <DetailLevel>ReturnMessages</DetailLevel> 
  <RequesterCredentials> 
    <eBayAuthToken>123...ABC</eBayAuthToken> 
  </RequesterCredentials> 
  <AlertIDs> 
    <AlertID>103031893</AlertID> 
  </AlertIDs> 
  <MessageIDs> 
    <MessageID>2848093</MessageID> 
  </MessageIDs> 
</GetMyMessagesRequest> 

Output

Notice that the response for both the Alert and the Message contain HTML code within the Text node.

XML format. Also available is the .txt version of this XML.

<?xml version="1.0" encoding="UTF-8"?>
<GetMyMessagesResponse xmlns="urn:ebay:apis:eBLBaseComponents">
  <Timestamp>2006-06-22T21:37:44.984Z</Timestamp>
  <Ack>Success</Ack>
  <Version>465</Version>
  <Build>e465_core_Bundled_3107419_R1</Build>
  <Alerts>
    <Alert>
      <Sender>eBay</Sender>
      <RecipientUserID>sampleseller</RecipientUserID>
      <Subject>eBay Change Email Notice</Subject>
      <Priority>0</Priority>
      <AlertID>103031893</AlertID>
      <Text>
        <br/>
        Dear sampleseller,<br/>
        <br/>
Thank you for submitting your change of email address request. Instructions on completing
the change have been sent to your new email address.<br/>
        <br/>
If you did not make this change, check with family members and others who may have access
to your account first. If<br/>
you still feel that an unauthorized person has changed your email, get help here:<br/>
        <a href="http://pages.ebay.com/help/confidence/problems-account-theft.html">http:/
/pages.ebay.com/help/confidence/problems-account-theft.html</a>
        <br/>
Thank you for using eBay!<br/>
      </Text>
      <ResolutionStatus>ResolvedByAutoResolution</ResolutionStatus>
      <Read>false</Read>
      <ReceiveDate>2006-05-24T18:15:57.000Z</ReceiveDate>
      <ExpirationDate>2006-08-02T18:15:55.000Z</ExpirationDate>
      <IsTimedResolution>true</IsTimedResolution>
      <ActionURL/>
      <ResponseDetails>
        <ResponseEnabled>false</ResponseEnabled>
      </ResponseDetails>
      <Folder>
        <FolderID>0</FolderID>
      </Folder>
    </Alert>
  </Alerts>
  <Messages>
    <Message>
      <Sender>eBay</Sender>
      <RecipientUserID>sampleseller</RecipientUserID>
      <Subject>eBay Offer Submitted: Austin Healey</Subject>
      <MessageID>2848093</MessageID>
      <Text>
        <html>
          <head>
            <title>eBay Offer Submitted: Austin Healey</title>
          </head>
          <body bgcolor="#FFFFFF">
            <table cellpadding="0" cellspacing="0" width="100%">
              <tr>
                <td width="100%" style="word-wrap: break-word;">
                  <table cellpadding="0" cellspacing="0" border="0" class="BodyFont"
                    width="100%">
                    <tr>
                      <td><img src="http://pics.qa.ebaystatic.com/aw/pics/logos/
                        ebay_95x39.gif" alt="eBay"/></td>
                      <td valign="bottom" align="left" class="Help"><b>eBay sent this
                        message to Sample Seller (sampleseller).</b>
                      <br/>
Your registered name is included to show this message originated from eBay. <a
href="http://pages.ebay.com/help/confidence/name-userid-emails.html">Learn more</a>.
                      </td>
                    </tr>
                  </table>
                </td>
              </tr>
            </table>
          </body>
        </html>
      </Text>
      <Flagged>false</Flagged>
      <Read>false</Read>
      <ReceiveDate>2006-06-21T14:17:27.000Z</ReceiveDate>
      <ExpirationDate>2006-08-20T14:17:04.000Z</ExpirationDate>
      <ResponseDetails>
        <ResponseEnabled>false</ResponseEnabled>
      </ResponseDetails>
      <Folder>
        <FolderID>0</FolderID>
      </Folder>
    </Message>
  </Messages>
</GetMyMessagesResponse>

Back to list of samples

Sample: Message Folders

Retrieves alert and message headers for the specified folder.

Description

If you get too much data when retrieving only alert and message headers, you can further restrict the amount of data returned by specifying a FolderID in the request. Doing so returns only the alert and message headers from the specified folder.

Retrieve the FolderID values for the My Messages folders by calling GetMyMessages with a DetailLevel of ReturnSummary. Note that the FolderID for the Inbox is 0.

Input

This example uses a FolderID of 2.

XML format (HTTP POST). Also available is the .txt version of this XML.

<?xml version="1.0" encoding="utf-8"?> 
<GetMyMessagesRequest xmlns="urn:ebay:apis:eBLBaseComponents"> 
  <Version>467</Version> 
  <DetailLevel>ReturnMessages</DetailLevel> 
  <RequesterCredentials> 
    <eBayAuthToken>123...ABC</eBayAuthToken> 
  </RequesterCredentials> 
  <FolderID>2</FolderID> 
</GetMyMessagesRequest> 

Output

The following sample shows the results from this call. Notice that the message is from FolderID 2 and that the empty Alerts node indicates that there are no alerts in that folder.

XML format. Also available is the .txt version of this XML.

<?xml version="1.0" encoding="utf-8"?>
<GetMyMessagesResponse xmlns="urn:ebay:apis:eBLBaseComponents">
  <Timestamp>2006-06-27T00:48:48.734Z</Timestamp>
  <Ack>Success</Ack>
  <Version>465</Version>
  <Build>e465_core_Bundled_3107419_R1</Build>
  <Alerts/>
  <Messages>
    <Message>
      <Sender>eBay</Sender>
      <RecipientUserID>sampleuser</RecipientUserID>
      <Subject>eBay Second Chance Offer for Item #330000037619: Auction Title</Subject>
      <MessageID>2809419</MessageID>
      <Flagged>false</Flagged>
      <Read>false</Read>
      <ReceiveDate>2006-06-20T23:34:37.000Z</ReceiveDate>
      <ExpirationDate>2006-07-20T23:34:30.000Z</ExpirationDate>
      <ResponseDetails>
        <ResponseEnabled>true</ResponseEnabled>
        <ResponseURL>http://respondtothis.com</ResponseURL>
      </ResponseDetails>
      <Folder>
        <FolderID>2</FolderID>
      </Folder>
    </Message>
  </Messages>
</GetMyMessagesResponse>

Back to list of samples



Back to top

GetMyMessages Change History
Version Description
657
2010-02-17
  • Messages.Message.Text (doc change): The documentation has been updated to state that the content of the field can contain up to 2 MB of data.
635
2009-09-16
  • Messages.Message.Text (modified): Threaded messages are returned. Additionally, emails that were sent by an eBay member's email client (to another eBay member) are returned; their message type is indicated as MessageTypeCodeType.ContacteBayMemberViaAnonymousEmail.
583
2008-09-17
  • Messages.Message.QuestionType.None (added): New value indicating that no question type applies.
573
2008-07-09
  • Messages.Message.ListingStatus (added): Specifies the listing status at the time the question was created.
  • Messages.Message.MessageType (added): Available on the US site as of September 2009. Specifies the type of message being retrieved through GetMyMessages.
  • Messages.Message.QuestionType (added): Available on the US site as of September 2009. Specifies the context of the question, and corresponds to the subject of the message.
  • Messages.Message.ExternalMessageID (added): Available on the US site as of September 2009. An ID used by an external application to uniquely identify a message.
  • Messages.Message.Content (added): The message body. This can be plain text.
479
2006-09-20
  • Messages.Message.Folder (doc change): Messages.Message.Folder is conditionally returned.
445
2006-1-25
  • Messages.Message.SendToName (added): A new value is returned, the displayable name of the user or eBay application to which the message is sent. Only returned for M2M, and if a value exists.
439
2005-12-28
  • Alerts.Alert.ResponseDetails.ResponseEnabled (added): Indicates whether or not an alert or message can be responded to. To respond to an alert or message, use the URL in ResponseURL. You may need to log into the eBay Web site to complete the response.
  • Messages.Message.ResponseDetails.ResponseEnabled (added): Indicates whether or not an alert or message can be responded to. To respond to an alert or message, use the URL in ResponseURL. You may need to log into the eBay Web site to complete the response.



Back to top

User-Contributed Notes
   
 
 
 

This document was generated with a customized version of the apireferencedocs tool.

© 2005–2010 eBay, Inc. All rights reserved. This documentation and the API may only be used in accordance with the eBay Developers Program and API License Agreement.