Manage ads
Pause or resume Microsoft Ads campaigns, ad groups and ads, change a campaign's daily budget, and delete them.
Microsoft keeps an on/off switch at each level, and Zernio writes to the level you call.
Pause or resume
PUT /v1/ads/{adId}/status sets the ad's own switch. Its ad group, campaign and sibling ads keep theirs.
const { data: paused } = await zernio.adcampaigns.updateAdStatus({
path: { adId: '6ae0968fa23091cc35b72121' },
body: { status: 'paused' }
});Response (200):
{ "updated": 1, "skipped": 0, "status": "paused", "configuredStatus": "PAUSED" }PUT /v1/ads/campaigns/{campaignId}/status and PUT /v1/ads/ad-sets/{adSetId}/status set the campaign's or the ad group's switch the same way.
Other changes
| Change | Call | Microsoft behaviour |
|---|---|---|
| Budget | budget: { amount, type: "daily" } on PUT /v1/ads/{adId} or PUT /v1/ads/campaigns/{campaignId} | Changes the campaign's daily budget |
| Delete | DELETE /v1/ads/{adId} or DELETE /v1/ads/campaigns/{campaignId} | Deletes on Microsoft Advertising |
How it behaves
- An ad reads
pausedwhile its campaign or ad group is paused, even when its own switch is on:configuredStatusshows the ad's own switch. - Deleting an ad Zernio created deletes its whole campaign, because Zernio built that campaign for the ad. Deleting a synced ad deletes only the ad.
- Rename, bid, targeting and creative changes are not available.
- A campaign, ad group or ad deleted in Microsoft Advertising settles as
cancelledon the next sync.
If it fails
| Error | Cause | Fix |
|---|---|---|
422 with param: "budget.type" | A lifetime budget | Send type: "daily". |
501 with code feature_not_available | A rename, bid, targeting or creative change, or deleting an ad group | Make the change in Microsoft Advertising, or create a new ad. |
Related
- Pause or resume a single ad: the switch and its read-back.
- Update ad and Update a campaign: the budget change.
- Get campaign tree: every level with its status.
Was this page helpful?