"Campaign" vs "Email": discrepancies btw marketing and API language


I’m having some trouble finding a list of emails in a given campaign. The issue, I believe, comes from the fact that on the dev side, “campaigns” actually refers to what is known as “emails” on the marketing side. So when I hit the /campaigns endpoint, I actually see every recently sent email.

I’d like to find a list of recent emails in a given campaign for example our campaign titled “Daily Newsletter.” Do campaigns even have an ID? (To be clear – this issue really does make my head spin because of all the differences in language – I’m referring to a marketing campaign, not an API campaign).

Any suggestions to get around this, short of iterating through every object the /campaign call returns to see whether it appears to be an email in the campaign I’m looking for? Is there an API endpoint that will retrieve my desired data? Has anyone else dealt with this issue?

Campaign data - API

Hi @rnbronstein

Sorry for all of the confusion on this, you’re 100% correct that what you’d normally see labeled as a campaign in the HubSpot app is different that what you’d see listed as a campaign in the developer docs.

If you’re looking at a campaign in the Email Events API, then a campaign refers to a specific send of an email, and data for the campaign would include the deliverability events (sent, opened, clicked, etc.) for that send. These campaigns would be completely separate from what you would see under Productivity > Campaigns in the app.

The campaigns in app under Productivity > Campaigns are used to group sets of content together. We don’t currently have an API for these campaigns, but it’s something we’ll likely build in the future.


Do let me know when you’ve built it – right now my team will have to pull information manually, which is far from ideal!