Retrieve List Recipient using query attribute

get

/rest/api/v1.3/lists/{listName}/members

This endpoint retrieves a count of profile list recipients in a profile list. You can use query attributes to filter the results by specifying a query attribute type and values. If no query attributes are specified, the total count of profile list recipients is returned.

The count property in the response determines the amount of matching profile list recipients.

Request

Supported Media Types
Path Parameters
Query Parameters
  • Comma separated list of fields to retrieve or 'all'
  • ID corresponding to the query attribute
  • Query Attribute. Can be either 'r' (RIID_), 'e' (EMAIL_ADDRESS_), 'c' (CUSTOMER_ID_), or 'm' (MOBILE_NUMBER_), 'e_md5' (EMAIL_MD5_HASH_), 'e_sha256' (EMAIL_SHA256_HASH_).
Back to Top

Response

Supported Media Types

Default Response

Body ()
Root Schema : Profile List Recipients
Type: object
Title: Profile List Recipients
Show Source
Nested Schema : mergeRule
Type: object
Merge rule used to merge recipient records in a Profile List. Only used during the merge operation.
Show Source
  • Allowed Values: [ "OPTIN", "OPTOUT" ]
    This value must be specified as either OPTIN or OPTOUT and would be applied to all of the records contained in the API call. If this value is not explicitly specified, then it is set to OPTOUT.
  • Value of incoming preferred email format data. For example, 'H' may represent a preference for HTML formatted email.
  • Indicates what should be done for records where a match is not found (true = insert / false = no insert).
  • Allowed Values: [ "RIID_", "CUSTOMER_ID_", "EMAIL_ADDRESS_", "MOBILE_NUMBER_", "EMAIL_MD5_HASH_", "EMAIL_SHA256_HASH_" ]
    First match column for determining whether an insert or update should occur.
  • Allowed Values: [ "RIID_", "CUSTOMER_ID_", "EMAIL_ADDRESS_", "MOBILE_NUMBER_", "EMAIL_MD5_HASH_", "EMAIL_SHA256_HASH_" ]
    Second match column for determining whether an insert or update should occur. (optional).
  • Allowed Values: [ "NONE", "AND" ]
    Operator to join match column names
  • Value of incoming opt-in status data that represents an opt-in status. For example, 'I' may represent an opt-in status.
  • Value of incoming opt-out status data that represents an optout status. For example, '0' may represent an opt-out status.
  • String containing comma-separated channel codes that if specified will result in record rejection when the channel address field is null. Channel codes are 'E' (Email), 'M' (Mobile), 'P' (Postal Code). For example 'E,M' would indicate that a record that has a null for Email or Mobile Number value should be rejected. This parameter can also be set to null or to an empty string, which will cause the validation to not be performed for any channel, except if the matchColumnName1 parameter is set to EMAIL_ADDRESS_ or MOBILE_NUMBER_. When matchColumnName1 is set to EMAIL_ADDRESS_ or MOBILE_NUMBER_, then the null or empty string setting is effectively ignored for that channel.
  • Value of incoming preferred email format data. For example, 'T' may represent a preference for Text formatted email.
  • Allowed Values: [ "REPLACE_ALL", "NO_UPDATE" ]
    Controls how the existing record should be updated.
Nested Schema : recordData
Type: object
Record data that represents Field Names and corresponding values for the recipient.
Show Source
Nested Schema : fieldNames
Type: array
Field Names in the Profile List
Show Source
Nested Schema : records
Type: array
Array of values corresponding to the fieldNames. Each element in the array represents a single recipient.
Show Source
Nested Schema : items
Type: array
Field Values for the recipient in the Profile List
Show Source
Back to Top

Examples

Existing members of a profile list can be retrieved one at a time by using a query attribute if the Responsys ID (RIID) for the member is not available. Please note that the total length of the string passed in for the fs parameter (containing the comma separated field names) cannot exceed 150 characters. To retrieve values of all columns, you can specify only one field with value set to "all" (if you have a column called "all", you should use two or more specific column names to avoid getting all of the columns).

FIELDS DESCRIPTION
Authorization <AUTH_TOKEN>
FIELDS DESCRIPTION
qa Can be either r (RIID), e (EMAIL_ADDRESS), c (CUSTOMER_ID), m (MOBILE_NUMBER), e_md5 (EMAIL_MD5_HASH_consisting of 32 characters), or e_sha256 (EMAIL_SHA256_HASH_ consisting of 64 characters). If an e_md5 and e_sha256 are both provided in the same request, the e_sha256 is ignored.
id ID corresponding to the query attribute
fs Comma separated field list or "all"

Sample Request URL:

  /rest/api/v1.3/lists/DemoNewsLetterList/members?qa=m&fs=riid_,email_address_,customer_id_&id=9845349498;
	

Sample Response: Success

NOTE: Other attributes in the response like mapTemplateName and mergeRule will have default values of null/false

{
   "recordData":    {
      "fieldNames":       [
         "RIID_",
         "EMAIL_ADDRESS_",
         "CUSTOMER_ID_"
      ],
      "records":       [
         [
            "4094330",
            "ab.na@gmail.com",
            null
         ],
         [
            "4094326",
            "ab.cd@gmail.com",
            null
         ]
      ],
      "mapTemplateName": null
   },
   "mergeRule":    {
      "textValue": null,
      "insertOnNoMatch": false,
      "updateOnMatch": null,
      "matchOperator": null,
      "matchColumnName3": null,
      "matchColumnName1": null,
      "matchColumnName2": null,
      "optinValue": null,
      "optoutValue": null,
      "rejectRecordIfChannelEmpty": null,
      "htmlValue": null,
      "defaultPermissionStatus": null
   },
   "links":    [
      {
         "rel": "self",
         "href": "/rest/api/v1.3/lists/DemoNewsLetterList/members?qa=m&fs=riid_,email_address_,customer_id_&id=9845349498",
         "method": "GET"
      },
      {
         "rel": "mergeListRecipients",
         "href": "/rest/api/v1.3/lists/DemoNewsLetterList/members",
         "method": "POST"
      }
   ]
}

	

Example Response:Failure

	{
   "type": "",
   "title": "Invalid field name",
   "errorCode": "INVALID_FIELD_NAME",
   "detail": "Column(s) [CUSTOMER_ID] not found in the list",
   "errorDetails": []
}

	
Back to Top