Call it
curl https://api.peume.com/v1/call/update-a-campaign \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"campaignId": "your campaignId",
"platform": "facebook",
"allowSharedBudgetUpdate": false
}
}'const res = await fetch("https://api.peume.com/v1/call/update-a-campaign", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"campaignId": "your campaignId",
"platform": "facebook",
"allowSharedBudgetUpdate": false
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/update-a-campaign",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"campaignId": "your campaignId",
"platform": "facebook",
"allowSharedBudgetUpdate": False
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: update-a-campaign.
Parameters
campaignIdRequiredstringPlatform campaign ID
stagebooleanSend true to stage this change instead of applying it. Nothing is written to the ad network; the response is `202` with the staged change and its diff. Apply it with POST /v1/ads/changes/{changeId}/confirm. Meta, Google, TikTok, X, Snapchat and Reddit; cannot be combined with `validateOnly` or `dryRun`.
platformRequiredstringRequired: platform campaign IDs are not globally unique.
facebook · instagram · tiktok · linkedin · pinterest · google · twitter · openai · reddit · microsoft · amazon · tradedesk …
accountIdstring**Meta only.** SocialAccount id owning the ad account. Needed only for an EMPTY campaign (zero ads); ignored otherwise.
bidStrategystring**Meta, Google and AppLovin.** - Meta: the campaign default that ad sets inherit unless they override it. - Google: the campaign's own bidding strategy. LOWEST_COST_WITHOUT_CAP = Maximize Conversions, COST_CAP + bidAmount = Target CPA, LOWEST_COST_WITH_MIN_ROAS + roasAverageFloor = Target ROAS, LOWEST_COST_WITH_BID_CAP + bidAmount = Maximize Clicks with a CPC ceiling, and without bidAmount Maximize Clicks with no ceiling. - Google: portfolioBidStrategyId attaches a portfolio strategy instead. - AppLovin: sets the campaign goal value; the goal type itself cannot change. COST_CAP + bidAmount fo
bidAmountnumber**Google and AppLovin.** Whole currency units (USD: 12 = $12.00). Google: CPA target for COST_CAP (required), optional max CPC ceiling for LOWEST_COST_WITH_BID_CAP (omit it for Maximize Clicks with no ceiling). AppLovin: the CPI, CPE or CPP goal value, with COST_CAP.
roasAverageFloornumber**Google and AppLovin.** Decimal ROAS multiplier (2.0 = 2.0x), required for LOWEST_COST_WITH_MIN_ROAS. AppLovin: the ROAS goal value.
portfolioBidStrategyIdstring**Google only.** Attach an existing portfolio bid strategy (numeric id from GET /v1/ads/bid-strategies) instead of setting bidStrategy. Exclusive with bidStrategy.
allowSharedBudgetUpdatebooleanGoogle only. Explicitly allow changing a shared campaign budget (flagged as shared by Google, or used by more than one campaign), affecting every campaign that uses it. Does not bypass an unknown sharing state. Also required to move a campaign onto a shared budget with sharedBudgetId.
Example: false
targetImpressionSharestringGoogle Search only. Target impression share bidding. Exclusive with bidStrategy, portfolioBidStrategyId and manualCpc; bidAmount is refused alongside it (the ceiling is maxCpc).
manualCpcobjectmanualCpc
networkSettingsobjectnetworkSettings
trackingUrlTemplatestring**Google only.** campaign.tracking_url_template; an empty string clears it.
finalUrlSuffixstring**Google only.** campaign.final_url_suffix; an empty string clears it.
sharedBudgetIdstring**Google only.** Move the campaign onto this shared budget (id from GET /v1/ads/shared-budgets), or null to move it back onto a budget of its own sized by `budget`.
budgetobjectMeta CBO, Google daily, or OpenAI Ads or Reddit Ads daily or lifetime campaign budget, in whole currency units.
namestringRename the campaign. Every network except Microsoft and OpenAI (501 there).
platformSpecificDataobject**Meta only.** Platform implied by the `platform` body param, same convention as POST /v1/ads/create.
