Update Campaign
Update Campaign
PATCH
https://api.ocamba.com/api/v1/adex/campaigns/{id}
Updates the specific Campaign by setting the values of the parameters passed. Any parameters not provided will be left unchanged
Note
At least one of the updatable fields should be sent via HTTP body in order to change the current state of the campaign.
Rate limits:
- Burst: 10/s
- Steady: 150/m
Path parameters
parametersRequest schema
bodyResponse schemas
•
204
No Content
›
400
application/json
›
500
application/json
curl -X PATCH \
"https://api.ocamba.com/api/v1/adex/campaigns/{id}" \
-H "Authorization: Bearer {TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"score": 50,
"status": "paused"
}'const url = 'https://api.ocamba.com/api/v1/adex/campaigns/{id}';
const options = {
method: 'PATCH',
headers: {
Authorization: "Bearer {TOKEN}",
'Content-Type': "application/json"
},
body: JSON.stringify(
{
"score": 50,
"status": "paused"
}
)
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}$ch = curl_init("https://api.ocamba.com/api/v1/adex/campaigns/{id}");
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: Bearer {TOKEN}",
"Content-Type: application/json"
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode(
[
"score" => 50,
"status" => "paused"
]
));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);Responses
204 No Content
400 Bad Request
500 Internal Server Error
Responses