v1

latestSwagger 2.0Private2026-08-04128286690.5 KB
Email Campaigns

PUT (Update) An Email Campaign Activity

Use this method to update an email campaign activity by including the complete email campaign activity with your changes in the request body. The request body requires the from_name, from_email, reply_to_email, and subject properties.

You can only update email campaign activities that have the primary_email role and that are in DRAFT or Done status. When you use a PUT method to update a resource, the V3 API overwrites any properties that are missing in the request body. However, the V3 API does not overwrite subresources that you omit in the request body or missing properties in subresources. This method considers physical_address_in_footer, document_properties, html_content, and permalink_url subresources of the email campaign activity.

put/emails/activities/{campaign_activity_id}

Path parameters

campaign_activity_idstring required

The unique ID for the email campaign activity you are updating.

Request body

campaign_activity_idstring

Identifies a campaign activity in the V3 API.

campaign_idstring

Identifies a campaign in the V3 API.

rolestring

The purpose of the individual campaign activity in the larger email campaign effort. Valid values are: <ul>

<li>primary_email — The main email marketing campaign that you send to contacts. The <code>primary_email</code> contains the complete email content.</li> <li>permalink — A permanent link to a web accessible version of the <code>primary_email</code> content without any personalized email information. For example, permalinks do not contain any of the contact details that you add to the <code>primary_email</code> email content. </li> <li>resend — An email campaign that you resend to contacts that did not open the email campaign.</li> </ul> Constant Contact creates a <code>primary_email</code> and a <code>permalink</code> role campaign activity when you create an email campaign.
contact_list_idsstring[]

The contacts that Constant Contact sends the email campaign activity to as an array of contact <code>list_id</code> values. You cannot use contact lists and segments at the same time in an email campaign activity.

segment_idsinteger[]

The contacts that Constant Contact sends the email campaign activity to as an array containing a single <code>segment_id</code> value. Only <code>format_type</code> 3, 4, and 5 email campaign activities support segments. You cannot use contact lists and segments at the same time in an email campaign activity.

current_statusstring

The current status of the email campaign activity. Valid values are: <ul>

<li>DRAFT — An email campaign activity that you have created but have not sent to contacts.</li> <li>SCHEDULED — An email campaign activity that you have scheduled for Constant Contact to send to contacts.</li> <li>EXECUTING — An email campaign activity Constant Contact is currently sending to contacts. Email campaign activities are only in this status briefly.</li> <li>DONE — An email campaign activity that you successfully sent to contacts.</li> <li>ERROR — An email campaign activity that encountered an error.</li> <li>REMOVED — An email campaign that a user deleted. Users can view and restore deleted emails through the UI.</li> </ul>
format_typeinteger

Identifies the type of email format. Valid values are: <ul>

<li>1 - A legacy custom code email created using the V2 API, the V3 API, or the legacy UI HTML editor.</li> <li>2 - An email created using the second generation email editor UI.</li> <li>3 - An email created using the third generation email editor UI. This email editor features an improved drag and drop UI and mobile responsiveness.</li> <li>4 - An email created using the fourth generation email editor UI.</li> <li>5 - A custom code email created using the V3 API or the new UI HTML editor.</li> </ul>
from_emailstring required

The email "From Email" field for the email campaign activity. You must use a confirmed Constant Contact account email address. Make a GET call to <code>/account/emails</code> to return a collection of account emails and their confirmation status.

from_namestring required

The email "From Name" field for the email campaign activity.

reply_to_emailstring required

The email "Reply To Email" field for the email campaign activity. You must use a confirmed Constant Contact account email address. Make a GET call to <code>/account/emails</code> to return a collection of account emails and their confirmation status.

subjectstring required

The email "Subject" field for the email campaign activity.

html_contentstring

The HTML or XHTML content for the email campaign activity. Only <code>format_type</code> 1 and 5 (legacy custom code emails or modern custom code emails) can contain <code>html_content</code>.

permalink_urlstring

The permanent link to a web accessible version of the email campaign content without any personalized email information. The permalink URL becomes accessible after you send an email campaign to contacts.

preheaderstring

The email preheader for the email campaign activity. Only <code>format_type</code> 3, 4, and 5 email campaign activities use the preheader property.

document_idstring

Identifies the email document used in an email editor (format_type 4) email campaign.

Example request

{
  "campaign_activity_id": "4c08372c-957a-48b5-bc45-72c7f00796cd",
  "campaign_id": "8987dc1a-48ef-433a-b836-7ca4f9aa3481",
  "role": "primary_email",
  "contact_list_ids": [
    "da10f460-3072-11e9-b282-fa163e6b01c1"
  ],
  "segment_ids": [
    1
  ],
  "current_status": "DRAFT",
  "format_type": 5,
  "from_email": "jdodge@constantcontact.com",
  "from_name": "Jake Dodge",
  "reply_to_email": "jdodge@constantcontact.com",
  "subject": "Holiday Special Newsletter",
  "html_content": "<html><body>[[trackingImage]] <a href=\"http://www.constantcontact.com\">Visit ConstantContact.com!</a> </body></html>",
  "permalink_url": "https://conta.cc/2GaQ8AY",
  "preheader": "You don't want to miss this.",
  "physical_address_in_footer": {
    "address_line1": "123 Maple Street",
    "address_line2": "Unit 1",
    "address_optional": "Near Boston Fire Station",
    "city": "Boston",
    "country_code": "US",
    "country_name": "United States",
    "organization_name": "Jake Dodge's Pancakes",
    "postal_code": "02451",
    "state_code": "MA",
    "state_non_us_name": "Victoria"
  },
  "document_id": "21babb03-8385-4739-b9cc-n6cce44633a7",
  "document_properties": {
    "style_content": ".white{color: #ffffff;}",
    "letter_format": "XHTML",
    "greeting_salutation": "Dear",
    "greeting_name_type": "F",
    "greeting_secondary": "Greetings!",
    "subscribe_link_enabled": "false",
    "subscribe_link_name": "Subscribe to my email list!",
    "text_content": "<Text><Greeting/></Text>",
    "permission_reminder_enabled": "false",
    "permission_reminder": "Hi, just a reminder that you're receiving this email because you have expressed an interest in our company.",
    "view_as_webpage_enabled": "false",
    "view_as_webpage_text": "Having trouble viewing this email?",
    "view_as_webpage_link_name": "Click here to view this email as a web page",
    "forward_email_link_name": "Forward email"
  }
}

Response

Email campaign activity successfully updated.

campaign_activity_idstring

Identifies a campaign activity in the V3 API.

campaign_idstring

Identifies a campaign in the V3 API.

rolestring

The purpose of the individual campaign activity in the larger email campaign effort. Valid values are: <ul>

<li>primary_email — The main email marketing campaign that you send to contacts. The <code>primary_email</code> contains the complete email content.</li> <li>permalink — A permanent link to a web accessible version of the <code>primary_email</code> content without any personalized email information. For example, permalinks do not contain any of the contact details that you add to the <code>primary_email</code> email content. </li> <li>resend — An email campaign that you resend to contacts that did not open the email campaign.</li> </ul> Constant Contact creates a <code>primary_email</code> and a <code>permalink</code> role campaign activity when you create an email campaign.
contact_list_idsstring[]

The contacts that Constant Contact sends the email campaign activity to as an array of contact <code>list_id</code> values. You cannot use contact lists and segments at the same time in an email campaign activity.

segment_idsinteger[]

The contacts that Constant Contact sends the email campaign activity to as an array containing a single <code>segment_id</code> value. Only <code>format_type</code> 3, 4, and 5 email campaign activities support segments. You cannot use contact lists and segments at the same time in an email campaign activity.

current_statusstring

The current status of the email campaign activity. Valid values are: <ul>

<li>DRAFT — An email campaign activity that you have created but have not sent to contacts.</li> <li>SCHEDULED — An email campaign activity that you have scheduled for Constant Contact to send to contacts.</li> <li>EXECUTING — An email campaign activity Constant Contact is currently sending to contacts. Email campaign activities are only in this status briefly.</li> <li>DONE — An email campaign activity that you successfully sent to contacts.</li> <li>ERROR — An email campaign activity that encountered an error.</li> <li>REMOVED — An email campaign that a user deleted. Users can view and restore deleted emails through the UI.</li> </ul>
format_typeinteger

Identifies the type of email format. Valid values are: <ul>

<li>1 - A legacy custom code email created using the V2 API, the V3 API, or the legacy UI HTML editor.</li> <li>2 - An email created using the second generation email editor UI.</li> <li>3 - An email created using the third generation email editor UI. This email editor features an improved drag and drop UI and mobile responsiveness.</li> <li>4 - An email created using the fourth generation email editor UI.</li> <li>5 - A custom code email created using the V3 API or the new UI HTML editor.</li> </ul>
from_emailstring required

The email "From Email" field for the email campaign activity. You must use a confirmed Constant Contact account email address. Make a GET call to <code>/account/emails</code> to return a collection of account emails and their confirmation status.

from_namestring required

The email "From Name" field for the email campaign activity.

reply_to_emailstring required

The email "Reply To Email" field for the email campaign activity. You must use a confirmed Constant Contact account email address. Make a GET call to <code>/account/emails</code> to return a collection of account emails and their confirmation status.

subjectstring required

The email "Subject" field for the email campaign activity.

html_contentstring

The HTML or XHTML content for the email campaign activity. Only <code>format_type</code> 1 and 5 (legacy custom code emails or modern custom code emails) can contain <code>html_content</code>.

permalink_urlstring

The permanent link to a web accessible version of the email campaign content without any personalized email information. The permalink URL becomes accessible after you send an email campaign to contacts.

preheaderstring

The email preheader for the email campaign activity. Only <code>format_type</code> 3, 4, and 5 email campaign activities use the preheader property.

document_idstring

Identifies the email document used in an email editor (format_type 4) email campaign.

Example response

{
  "campaign_activity_id": "4c08372c-957a-48b5-bc45-72c7f00796cd",
  "campaign_id": "8987dc1a-48ef-433a-b836-7ca4f9aa3481",
  "role": "primary_email",
  "contact_list_ids": [
    "da10f460-3072-11e9-b282-fa163e6b01c1"
  ],
  "segment_ids": [
    1
  ],
  "current_status": "DRAFT",
  "format_type": 5,
  "from_email": "jdodge@constantcontact.com",
  "from_name": "Jake Dodge",
  "reply_to_email": "jdodge@constantcontact.com",
  "subject": "Holiday Special Newsletter",
  "html_content": "<html><body>[[trackingImage]] <a href=\"http://www.constantcontact.com\">Visit ConstantContact.com!</a> </body></html>",
  "permalink_url": "https://conta.cc/2GaQ8AY",
  "preheader": "You don't want to miss this.",
  "physical_address_in_footer": {
    "address_line1": "123 Maple Street",
    "address_line2": "Unit 1",
    "address_optional": "Near Boston Fire Station",
    "city": "Boston",
    "country_code": "US",
    "country_name": "United States",
    "organization_name": "Jake Dodge's Pancakes",
    "postal_code": "02451",
    "state_code": "MA",
    "state_non_us_name": "Victoria"
  },
  "document_id": "21babb03-8385-4739-b9cc-n6cce44633a7",
  "document_properties": {
    "style_content": ".white{color: #ffffff;}",
    "letter_format": "XHTML",
    "greeting_salutation": "Dear",
    "greeting_name_type": "F",
    "greeting_secondary": "Greetings!",
    "subscribe_link_enabled": "false",
    "subscribe_link_name": "Subscribe to my email list!",
    "text_content": "<Text><Greeting/></Text>",
    "permission_reminder_enabled": "false",
    "permission_reminder": "Hi, just a reminder that you're receiving this email because you have expressed an interest in our company.",
    "view_as_webpage_enabled": "false",
    "view_as_webpage_text": "Having trouble viewing this email?",
    "view_as_webpage_link_name": "Click here to view this email as a web page",
    "forward_email_link_name": "Forward email"
  }
}