Skip to main content
Sitecore Documentation
  • Learn
  • Downloads
  • Changelog
  • Roadmap
SendCloud Portal
Sitecore Send API documentation
  • Introduction to the Sitecore Send API
        • Get all subscribers
        • Get subscriber by email address
        • Get subscriber by ID
        • Get subscriber by ID without mailing list ID
        • Add a new subscriber
        • Add multiple subscribers
        • Update a subscriber
        • Unsubscribe a subscriber from an account
        • Unsubscribe a subscriber from a mailing list
        • Unsubscribe a subscriber from a mailing list and a campaign
        • Remove a subscriber
        • Remove multiple subscribers
        • Delete a subscriber
        • Delete multiple subscribers from a specific mailing list
        • Delete a subscriber from an account
  1. Subscribers
  1. Sitecore Send API documentation
  2. API reference

Unsubscribe a subscriber from a mailing list and a campaign

POST /subscribers/{MailingListID}/{CampaignID}/unsubscribe.{Format}

Unsubscribes a subscriber from a specific email list and campaign. This call considers the Unsubscribe settings in your Sitecore Send account where you can specify whether to remove a subscriber from all other email lists.

Request

ParameterInTypeRequiredDescription
AcceptheaderstringtrueDetermines the expected format and data type to retrieve the response data.Value: application/json
MailingListIDpathstringtrueThe ID of the email list from which you want to unsubscribe a subscriber.
CampaignIDpathstringtrueThe ID of the campaign sent to the specific email list.
FormatpathstringtrueThe supported file format for getting a response.Possible values: json and xml.
apikeyquerystringtrueThe API key of your account.
EmailbodystringtrueThe email address of the subscriber.
POST https://{hostname}/v3/subscribers/{MailingListID}/{CampaignID}/unsubscribe.{Format}?apikey=

Request body:
{
  "Email": "[email protected]"
}
curl --include \\
     --request POST \\
     --header "Content-Type: application/json" \\
     --header "Accept: application/json" \\
     --data-raw '{
       "Email": "[email protected]"
     }' \\
     'https://{hostname}/v3/subscribers/{MailingListID}/{CampaignID}/unsubscribe.{Format}?apikey='

Response

StatusDescriptionHeadersSchema
200 OKThe request is successful.Content-Type
/json
N/A
{
  "Code": 0,
  "Error": null,
  "Context": null
}
  • Code - the response code. This is 0 if successful.

  • Error - the response error message. This is null if successful.

  • Context - this is null if successful.

If you have suggestions for improving this article, let us know!

© Copyright , Sitecore A/S or a Sitecore affiliated company.
All rights reserved.

Privacy policySitecore Trust CenterTerms of use
SendCloud Portal