Update Email Campaign Properties

Use this interface to update an existing EMD Email campaign object.

The response returns the campaign object, which includes the campaign ID number and other campaign properties (echoing the request format). The links array contains the campaign object’s related API operations, specific to the campaign name where applicable.

TIP: You can use this API to update or delete a campaign's data source. To update it, only include the data source in your request. To delete the data source, pass an empty data source.

Note: The Responsys Advanced API is generally available for all Responsys customers.

Service URL:

/rest/api/v1.5/campaigns/{campaignName}

Required Path Parameters:

  • campaignName - Name of the campaign to be updated.

Request Method:

PUT

Request Header:

Authorization=<AUTH_TOKEN>

Content-Type=application/json

Request Body - Required Properties:

We recommend that your client application create the request body as follows:

  1. Use the Get Email Campaign Properties API to obtain the campaign’s current properties.

    Responsys users may have modified the campaign after it was created by the API, and therefore the properties might not match those returned in the Create Email Campaign response body.

  2. Copy the email campaign properties from the response body of the Get Email Campaign Properties request, and then use the copy to create the request body for Update Email Campaign:

    1. Modify the properties as needed for your updates, as needed.

    2. Leave the other properties in the request body, unmodified.

  3. Important: Including data sources in your request will update the data sources in the campaign, whereas passing an empty data source in your request body will delete any existing data sources in the campaign except for Profile Lists and Segment Groups.

Sample Request Body

{
  "name": "testcampaign-b11",
  "folderName": "testfolder",
  "type": "EMAIL",
  "description": "<description>",
  "purpose": "PROMOTIONAL",
  "marketingStrategy": "<strategy>",
  "dataSource": [
    {
      "path": "folderName/objectName",
      "alias": "<dataSourceAliasName>",
      "fields": [
        {
          "name": "<columnName>",
          "alias": "<aliasName>",
          "lookUpKey": false,
          "defaultValue": null
        },
        {
          "name": "<columnName>",
          "alias": "<aliasName>",
          "lookUpKey": false,
          "defaultValue": null
        }
      ],
      "type": "PROFILE_LIST",
      "defaultValue": null
    }
  ],
  "marketingProgram": "<program>",
  "filterPaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "refiningDataSourcePath": "foldername/objectName1",
  "proofListPath": "foldername/objectName1",
  "seedListPath": "foldername/objectName1",
  "supplementaryProofDataSourcePaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "supplementarySeedDataSourcePaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "supplementaryLookupDataSource": [
    {
      "path": "foldername/objectName1",
      "alias": "<data source alias name>",
      "fields": [
        {
          "name": "<column name>",
          "alias": "<alias name>",
          "lookUpKey": true
        }
      ]
    }
  ],
  "suppressionListPaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "subject": "<subject>",
  "fromName": "<from name>",
  "fromEmail": "<from email>",
  "replyToEmail": "<reply to email>",
  "bccEmail": "<bcc email>",
  "htmlMessagePath": "documentPath",
  "textMessagePath": "documentPath",
  "enableExternalTracking": true,
  "externalTrackingParams": {
    "name1": "value1",
    "name2": "value2"
  },
  "enableLinkTracking": true,
  "linkTablePath": "foldername/objectName1",
  "attachmentPaths": [
    "documentPath1",
    "documentPath2"
  ],
  "useUTF8": true,
  "locale": "<value>",
  "trackHTMLOpens": true,
  "trackConversions": true,
  "sendTextIfHTMLUnknown": true,
  "segmentTrackingColumnName": "<name>",
  "unsubscribeOption": "OPTOUT_SINGLE_CLICK",
  "unsubscribeFormName": "name",
  "autoCloseOption": "NO_AUTO_CLOSE",
  "autoCloseValue": "<value>",
  "closedCampaignURL": "<URL>",
  "externalCampaignCode": "<code>",
  "salesForceCampaignId": "<salesforce id>"
}

Sample Response Body

{
  "id": 1000,
  "name": "testcampaign-b11",
  "folderName": "testfolder",
  "type": "EMAIL",
  "description": "<description>",
  "purpose": "PROMOTIONAL",
  "marketingStrategy": "<strategy>",
  "dataSource": [
    {
      "path": "folderName/objectName",
      "alias": "<dataSourceAliasName>",
      "fields": [
        {
          "name": "<columnName>",
          "alias": "<aliasName>",
          "lookUpKey": false,
          "defaultValue": null
        },
        {
          "name": "<columnName>",
          "alias": "<aliasName>",
          "lookUpKey": false,
          "defaultValue": null
        }
      ],
      "type": "PROFILE_LIST",
      "defaultValue": null
    }
  ],
  "marketingProgram": "<program>",
  "filterPaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "refiningDataSourcePath": "foldername/objectName1",
  "proofListPath": "foldername/objectName1",
  "seedListPath": "foldername/objectName1",
  "supplementaryProofDataSourcePaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "supplementarySeedDataSourcePaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "supplementaryLookupDataSource": [
    {
      "path": "foldername/objectName1",
      "alias": "<data source alias name>",
      "fields": [
        {
          "name": "<column name>",
          "alias": "<alias name>",
          "lookUpKey": true
        }
      ]
    }
  ],
  "suppressionListPaths": [
    "foldername/objectName1",
    "foldername/objectName2"
  ],
  "subject": "<subject>",
  "fromName": "<from name>",
  "fromEmail": "<from email>",
  "replyToEmail": "<reply to email>",
  "bccEmail": "<bcc email>",
  "htmlMessagePath": "documentPath",
  "textMessagePath": "documentPath",
  "enableExternalTracking": true,
  "externalTrackingParams": {
    "name1": "value1",
    "name2": "value2"
  },
  "enableLinkTracking": true,
  "linkTablePath": "foldername/objectName1",
  "attachmentPaths": [
    "documentPath1",
    "documentPath2"
  ],
  "useUTF8": true,
  "locale": "<value>",
  "trackHTMLOpens": true,
  "trackConversions": true,
  "sendTextIfHTMLUnknown": true,
  "segmentTrackingColumnName": "<name>",
  "unsubscribeOption": "OPTOUT_SINGLE_CLICK",
  "unsubscribeFormName": "name",
  "autoCloseOption": "NO_AUTO_CLOSE",
  "autoCloseValue": "<value>",
  "closedCampaignURL": "<URL>",
  "externalCampaignCode": "<code>",
  "salesForceCampaignId": "<salesforce id>",
  "links": [
    {
      "rel": "self",
      "href": "/rest/api/v1.5/campaigns/testcampaign-b11",
      "method": "PUT"
    },
    {
      "rel": "create",
      "href": "/rest/api/v1.5/campaigns",
      "method": "POST"
    },
    {
      "rel": "getProperties",
      "href": "/rest/api/v1.5/campaigns/testcampaign-b11",
      "method": "GET"
    }
  ]
}