Duplicate campaign

Copy a sent or draft campaign into a new draft.

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

write

Does what Duplicate in the cogwheel menu of the Campaigns page does. The copy is a draft with the same design, list and sender. The draft reaches no one and you can delete it from the Draft tab, so it does not wait for your OK.

Parameters

Parameters: duplicate_campaign
NameTypeDescription
campaign_id integer required integer Campaign ID from list_campaigns.
name string string Name of the new draft. Only you see it.

Request

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

Example response

JSON

{
  "campaign_id": 7182934615,
  "name": "Autumn offer, last chance",
  "status": "draft",
  "copied_from": 7164820931
}

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.