Campaign API
The campaign API allows you to make changes to a campaign programmatically.
Last updated
The campaign API allows you to make changes to a campaign programmatically.
Last updated
The campaign API base URL is https://api.closershq.io/v1/campaign
and requires authentication using the API key. Learn more about authentication.
List all campaigns
https://api.closershq.io/v1/campaign
GET
Add prospect to campaign
https://api.closershq.io/v1/campaign/prospect
POST
Remove prospect from campaign
https://api.closershq.io/v1/campaign/prospect
DELETE
There are 2 ways to find the campaign ID of any given campaign.
Make an API call to get all campaigns. The campaign ID is available in the API response.
Copy it from the campaign analytics URL on your dashboard, as shown below:
The list all campaigns endpoint allows you to get the list of all campaigns on a particular account using the GET request.
GET
https://api.closershq.io/v1/campaign
Authorization*
String
Bearer {{apiKey}}
This operation adds a prospect to an active or completed campaign. If the prospect doesn't already exist, the prospect is automatically created and added to the campaign.
This does not include draft campaigns or campaigns with errors.
POST
https://api.closershq.io/v1/campaign/prospect
Authorization*
String
Bearer {{apiKey}}
campaignId*
String
The ID of the campaign to send to
prospect*
String
an object containing the prospect to add
The prospect object required in the request body should contain the details about the prospect to add to the campaign. Only the email field is required. Every other field is optional.
The otherAttribute
field is where you added other attributes about the prospect for personalizing email contents.
This operation removes a prospect from a campaign, effectively marking them as having completed the campaign.
DELETE
https://api.closershq.io/campaign/prospect
Authorization*
String
Bearer {{apiKey}}
campaignId*
String
The campaign ID to remove the prospect from
prospect
String
The prospect object to remove from the campaign
The prospect object required in the request body only requires an email field, as in below:
Need help? Reach out to us via the chat box from your logged-in account or contact us via support@closershq.io