Update an Existing Campaign fail

18 views
Skip to first unread message

ziqi mo

unread,
Jul 3, 2025, 5:02:28 AMJul 3
to Outbrain-AmplifyApi
Update an Existing Campaign
---------------------------  
curl --location --request PUT 'https://api.outbrain.com/amplify/v0.1/campaigns/000684efce655c47cf9f64665c04ae5c05?extraFields=extraFields' \
--header 'OB-TOKEN-V1: MTc1MTUxMjY2ODA5NzphMTA4MTg2N2M3YTI5OTQzYjhhMmFkNGE1OGU2YjFkNTA2MTY2ZDcxZmUxZWUxNjFhMTk3NmNiY2RkYmFmNmRhOnsiY2FsbGVyQXBwbGljYXRpb24iOiJBbWVsaWEiLCJpcEFkZHJlc3MiOiIvMTAuMjQzLjg5LjE1MTo0MzIxNiIsImJ5cGFzc0FwaUF1dGgiOiJmYWxzZSIsInVzZXJOYW1lIjoiYmVhci5zbm93QGhvdG1haWwuY29tIiwidXNlcklkIjoiMTA3OTY3MTIiLCJkYXRhU291cmNlVHlwZSI6Ik1ZX09CX0NPTSJ9OmFmYmE1ZmFlZGM3ZjQ0YzIzMjc1ZWI4NWJhNDZiMzk1NjRiZmJjNTc4ZDZjOWQwMDY3YjY2NmU4NzUxZmVkNDVjMzExNDM3ZjA5NGUwYWEzNzIxOTcxYWM3MjQxNjZhMTYzNGQwZGJjZDQyZDhlNDM4NTBhOThiODU3M2I3' \
--header 'Content-Type: application/json' \
--data '{
"name": "flexfeedspeck-20250627-villas-uk-zyh-m-25en14-3565710419",
"enabled": true,
"cpc": 0.6190,
"targeting": {
"platform": ["MOBILE", "TABLET"],
"language": "en",
"excludeAdBlockUsers": false,
"nativePlacements": {
"enabled": false
},
"includeCellularNetwork": true,
"nativePlacementsEnabled": false,
"locationsVersion": "V2"
},
"campaignOptimization": {
"optimizationType": "TARGET_CPA_FULLY_AUTOMATED",
"maxCpcBidPercentage": 1.000,
"maxCpcAdjustmentOverManualInFullyAutomated": 1.400,
"targetCpaConversionId": "00f4d73130e39835170df937896e5f6f2a",
"targetCpa": 0.650,
"targetCpaPhase": "Learning",
"baseCpc": 0.2592,
"conversions": ["007b7f6b7015faf03a955b41b22dd5aef5", "0042af1ba45ac252017672d0d482cb4858"]
}
}'

---------------------------
response
{
"message": "Our servers encountered an error while processing your request"
}

bryn.whitcomb

unread,
Jul 3, 2025, 11:54:58 AMJul 3
to Outbrain-AmplifyApi
Hey there, 

Thanks for reaching out! 

There is an issue with the extraFields parameter on the endpoint you are calling. If you want to use this parameter,  you'll need to actually define the extra fields (e.g. "extraFields=CustomAudience,Locations,CampaignPixels", etc.). For a full list of available extra fields see "Campaign Extra Fields" in the Reference Objects section of our documentation: https://amplifyv01.docs.apiary.io/#reference/reference-objects.

From what I can see, you're just trying to enable the campaign. If this is the only setting you are modifying then you can simply remove the extraFields parameter altogether and just call the base endpoint. You can also just send { "enabled": true } in the body of the request, no other data is necessary. 

Let me know if you run into any additional issues!

Best, 
Bryn
Reply all
Reply to author
Forward
0 new messages