Skip to main content

Update campaign settings

Use this request to update campaign-wide settings such as assigned email accounts, sending limits, timezone, and more. The endpoint allows for partial updates.

Only campaigns with a status of DRAFT or EDITED can be updated. To change the campaign status to EDITED use the /make_editable endpoint.

Request

Endpoint

PATCH https://api.woodpecker.co/rest/v2/campaigns/{campaign_id}

Headers

x-api-key: {YOUR_API_KEY}
Content-type: application/json

For details on how to authenticate your requests, please see the authentication guide.

Body

The request body uses the campaign configuration payload. You can update each setting individually without impacting others, as the API supports partial updates.

{
"name":"Updated name",
"email_account_ids": [100001, 100002, 100003],
"settings": {
"timezone":"Pacific/Pago_Pago",
"prospect_timezone": true,
"daily_enroll": 150,
"gdpr_unsubscribe": true,
"list_unsubscribe": true,
"open_disabled_list": ["google.com", "OTHER_PROVIDER"],
"auto_pause_prospect_from_domain": true,
"catch_all_verification_mode": "MAXIMUM"
}
}

Body schema

FieldTypeDescription
namestringName of the campaign
email_account_idsarray[integer]List of email account SMTP IDs used in this campaign. Use /mailboxes endpoint to review them. Chosen mailboxes must be connected to Woodpecker without issues
settingsobjectCampaign-level settings object
└─timezonestringThe default timezone of a campaign. It will be used when setting.prospect_timezone is disabled or when it is enabled but the prospect's timezone is not specified. List of accepted timezones
└─prospect_timezonebooleanWhether to adjust sending times to prospect's timezone instead of the campaign timezone
└─daily_enrollintegerMaximum number of opening emails that can be sent per day. The limit is shared between all mailboxes. The default maximum value is 500
└─gdpr_unsubscribebooleanWhether the unsubscribe link should provide prospects with an option for GDPR-compliant data removal. This option will work only if the {{UNSUBSCRIBE}} snippet is included in your email or account signature
└─list_unsubscribebooleanWhether to include List-Unsubscribe header. This option will work only if the {{UNSUBSCRIBE}} snippet is included in your email or account signature
└─open_disabled_listarray[string]List of email service providers (recipient's ESP) for which open tracking is disabled. Available options: google.com, outlook.com, OTHER_PROVIDER
└─auto_pause_prospect_from_domainbooleanWhether to automatically pause sending to prospects after a response from the same domain (free providers excluded)
└─catch_all_verification_modestringCatch-all email verification mode - how to approach contacting prospects using catch-all emails.
  • NONE - contact all catch-all emails, including undeliverable
  • BALANCED - contact deliverable and risky catch-all emails
  • MAXIMUM - contact only deliverable catch-all emails
  • ONLY_VERIFY - do not contact catch-all emails

Request sample

Edit campaign's daily limit

curl --request PATCH \
--url "https://api.woodpecker.co/rest/v2/campaigns/{campaign_id}" \
--header "x-api-key: {YOUR_API_KEY}" \
--header "Content-Type: application/json" \
--data '{
"settings": {
"daily_enroll": 150
}
}'

Response

Response examples

The campaign has been updated. A full campaign payload will be returned.