Duplicate campaign

Make a draft copy of a campaign, like Duplicate in the Campaigns tab.

POST https://cotlet.dev/api/v1/emailoctopus/campaigns/{campaign_id}/duplicate

write

Does what Duplicate in the campaign drop-down does: it starts a new campaign from an existing one, sent or draft, and returns the new campaign_id. The copy is a draft and reaches no one until schedule_campaign or send_campaign runs, so this tool needs no confirmation. Change the name, subject or sender with update_campaign, and the recipients with set_campaign_recipients.

Parameters

Parameters: duplicate_campaign
NameTypeDescription
campaign_id string required string Campaign ID from list_campaigns.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/emailoctopus/campaigns/campaign_8c41d2/duplicate \
  -H "Authorization: Bearer $COTLET_API_KEY"
Python
result = client.call("emailoctopus", "duplicate_campaign", {"campaign_id":"campaign_8c41d2"})
Node.js
const result = await cotlet.call('emailoctopus', 'duplicate_campaign', {"campaign_id":"campaign_8c41d2"});
CLI
cotlet call emailoctopus duplicate_campaign --data '{"campaign_id":"campaign_8c41d2"}'

Example response

JSON

{
  "campaign_id": "d5e8a3b1-62c9-4e70-8a14-9f0b7c2d6e83",
  "name": "Autumn offer, last chance",
  "status": "draft",
  "copied_from": "c7a41b92-0d3e-4f58-b6a1-2e9d8c5f7014"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.