Retrieve Campaign Data Sources

get

/rest/api/v1.3/campaigns/{campaignName}/attributes/dataSources

Retrieves Data Sources associated with a Campaign

Request

Path Parameters
Back to Top

Response

Supported Media Types

Default Response

Body ()
Root Schema : Campaign Data Sources Response
Type: object
Title: Campaign Data Sources Response
Show Source
Nested Schema : attributeData
Type: object
Campaign attribute data
Show Source
Nested Schema : dataSources
Type: array
Array of Data Sources associated with the Campaign
Show Source
Nested Schema : Campaign DataSource
Type: object
Title: Campaign DataSource
Show Source
Nested Schema : fields
Type: array
An array of Fields of the particular dataSource.
Show Source
Nested Schema : Field
Type: object
Title: Field
Show Source
Back to Top

Examples

Use this interface to get the data sources associated with the specified campaign. Data sources can be of the following types:

  • Profile lists (one per campaign)
  • Profile extension tables
  • Supplemental data
  • Segment groups

Required request headers:

FIELDS DESCRIPTION
Authorization <AUTH_TOKEN>
Content-Type application/json

Response Notes:

Sample Response Body

{
  "attributeName": "dataSources",
  "attributeData": {
    "dataSources": [
      {
        "path": "folder/listname",
        "alias": "alias_name",
        "fields": [
          {
            "name": "COUNTRY_",
            "alias": "COUNTRY_",
            "lookUpKey": true,
            "defaultValue": null
          },
          {
            "name": "CREATED_DATE_",
            "alias": "CREATED_DATE_",
            "lookUpKey": true,
            "defaultValue": null
          },
          {
            "name": "CITY_",
            "alias": "CITY_",
            "lookUpKey": true,
            "defaultValue": null
          }
        ],
        "type": "PROFILE_LIST",
        "default": null
      },
      {
        "path": "folder/tablename",
        "alias": "alias_name",
        "fields": [
          {
            "name": "FATIGUE_PERSONA",
            "alias": "FATIGUE_PERSONA",
            "lookUpKey": false,
            "defaultValue": null
          },
          {
            "name": "MODIFIED_DATE_",
            "alias": "MODIFIED_DATE_",
            "lookUpKey": false,
            "defaultValue": null
          }
        ],
        "type": "PET",
        "default": null
      },
      {
        "path": "folder/tablename",
        "alias": "alias_name",
        "fields": [
          {
            "name": "CUSTOM2",
            "alias": "CUSTOM2",
            "lookUpKey": false,
            "defaultValue": null
          },
          {
            "name": "CUSTOM1",
            "alias": "CUSTOM1",
            "lookUpKey": false,
            "defaultValue": null
          }
        ],
        "type": "SUPPLEMENTAL_TABLE",
        "default": null
      },
      {
        "path": "folder/segmentgroup",
        "alias": "alias_name",
        "fields": null,
        "type": "SEGMENT_GROUP",
        "default": null
      },
      {
        "path": "folder/segmentgroup",
        "alias": "alias_name",
        "fields": null,
        "type": "SEGMENT_GROUP",
        "default": null
      },
      {
        "path": "var1",
        "alias": "var1",
        "fields": null,
        "type": "DYNAMIC_VARIABLE",
        "default": "afsd"
      },
      {
        "path": "var2",
        "alias": "var2",
        "fields": null,
        "type": "DYNAMIC_VARIABLE",
        "default": "asdf"
      },
      {
        "path": "var3",
        "alias": "var3",
        "fields": null,
        "type": "DYNAMIC_VARIABLE",
        "default": "asdf"
      }
    ]
  }
}
	

Troubleshooting Failures

The system returns error responses in the following situations.

Not an email campaign: Requests fail if the campaign specified is not an email campaign. The error resembles:

{
 "type": "",
 "title": "Not a valid campaign",
 "errorCode": "CAMPAIGN_IS_INVALID",
 "detail": "Only applicable for Email campaigns whereas [WS_SMS_DAPI_REST] is a Sms campaign",
 "errorDetails": []
}

Campaign not found: Requests fail if the campaign specified cannot be found. The error resembles:

{
 "type": "",
 "title": "Campaign not found",
 "errorCode": "CAMPAIGN_NOT_FOUND",
 "detail": "Campaign not found with name [testCampaignDataources]",
 "errorDetails": []
}

Campaign contains invalids characters: Requests fail if the campaign specified contains invalid characters. The error resembles:

{
 "type": "",
 "title": "Invalid request parameters",
 "errorCode": "INVALID_PARAMETER",
 "detail": "Invalid characters in the Campaign name: testCampaignDat$aources",
 "errorDetails": []
}

Campaign name too long: Requests fail if the campaign name exceeds 150 characters. The error resembles:

{
 "type": "",
 "title": "Invalid request parameters",
 "errorCode": "INVALID_PARAMETER",
 "detail": "Maximum characters allowed for Campaign name: testCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasourcestestCampaignDatasources is 150",
 "errorDetails": []
}

Invalid attribute type: Requests fail if an invalid attribute is given in the URL. The error resembles:

{
  "type": "",
  "title": "Invalid request parameters",
  "errorCode": "INVALID_PARAMETER",
  "detail": "Invalid attribute name :data",
  "errorDetails": []
} 
Back to Top