Campaigns

Update a draft campaign

PATCH/campaigns/{id}

Changes the fields you give of a campaign that was never sent (the same fields and checks as creating one). send_to or exclude alone replaces that list and keeps the other. A scheduled campaign must be cancelled first, and a sent one cannot change: both are refused with 409.

Permission: campaigns:write · on the API key screen: Campaigns → Full access · All permissions

Path parameters

  • idstringrequired

    The id of the campaign.

Body parameters

  • namestring

    At most 255 characters.

  • fromstring

    At least 3 characters. At most 320 characters.

  • subjectstring

    At least 1 characters. At most 500 characters.

  • preview_textstring

    At most 255 characters.

  • htmlstring

    At least 1 characters. At most 1,048,576 characters.

  • send_tostring[]

    Replaces the lists and segments to send to.

    At most 15 items.

  • excludestring[]

    Replaces the lists and segments left out.

    At most 15 items.

  • topic_idstring

    At most 2,000 characters.

  • tagsstring[]

    Replaces the campaign's tags ([] removes them all). Tags can be changed on any campaign; every other field only on a draft.

    At most 10 items.

Response

  • objectstringrequired

    One of: campaign

    At most 2,000 characters.

  • idstringrequired

    At most 2,000 characters.

  • namestring | nullrequired

    At most 100,000 characters.

  • subjectstringrequired

    At most 500 characters.

  • preview_textstring | nullrequired

    At most 100,000 characters.

  • statusstringrequired

    At most 20 characters.

  • scheduled_atstring | nullrequired

    At most 40 characters.

  • sent_atstring | nullrequired

    At most 40 characters.

  • stopped_atstring | nullrequired

    At most 40 characters.

  • recipientsnumberrequired
  • sentnumberrequired
  • failednumberrequired
  • tagsstring[]required

    At most 10 items.

  • created_atstring | nullrequired

    At most 40 characters.