Bulk Import Profiles
Bulk Import Profiles
POST
https://api.ocamba.com/v1/hood/profiles/bulk-update
Applies the same custom-properties patch to all matching subscribed profiles without sending profile IDs. Matching IDs are resolved from the filters query string, then queued for the same processing path as profile import.
Note
Requires the
profiles.import permission. This endpoint updates existing profiles only; it does not create profiles.
filters is a URL query string using the same syntax as GET /profiles (maximum 2000 characters). Client-supplied company_id, status, and deleted are stripped and rewritten: company is taken from the authenticated context, status=1 (subscribed), and deleted=0. At least one explicit filter must remain after stripping those keys, otherwise the API returns 400. Unknown filter keys (for example country_codes instead of country_code) are rejected.
custom_properties uses the same rules as POST /profiles/import: 1–100 keys, each key non-empty and at most 255 characters. type must be omitted or string. A non-empty value writes the property; JSON null deletes that key; empty string is rejected. Keys omitted from the patch are left unchanged.
A 202 Accepted response means the bulk update was queued. It does not mean that matching profiles have been updated. Zero matching profiles still returns 202. There is no public job-status API.
Overlapping requests enqueue. One unfinished bulk-update job runs per company, oldest first (FIFO).
Tip
To update every subscribed profile in one container, use POST /containers/{id}/profiles/bulk-update instead of sending
filters=container_id={id}.Rate limits:
- Burst: 10/s
- Steady: 150/m
Request schema
bodyResponse schemas
›
202
application/json
›
400
application/json
›
500
application/json
curl -X POST \
"https://api.ocamba.com/v1/hood/profiles/bulk-update" \
-H "Authorization: Bearer {TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"filters": "container_id=123&lists=in:1,2&user_data.segment_tier=eq:premium",
"custom_properties": {
"is_push_delivery_active": {
"value": "true"
},
"segment_tier": {
"type": "string",
"value": "premium"
},
"old_flag": {
"type": "string",
"value": null
}
}
}'const url = 'https://api.ocamba.com/v1/hood/profiles/bulk-update';
const options = {
method: 'POST',
headers: {
Authorization: "Bearer {TOKEN}",
'Content-Type': "application/json"
},
body: JSON.stringify(
{
"filters": "container_id=123&lists=in:1,2&user_data.segment_tier=eq:premium",
"custom_properties": {
"is_push_delivery_active": {
"value": "true"
},
"segment_tier": {
"type": "string",
"value": "premium"
},
"old_flag": {
"type": "string",
"value": null
}
}
}
)
};
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/v1/hood/profiles/bulk-update");
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: Bearer {TOKEN}",
"Content-Type: application/json"
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode(
[
"filters" => "container_id=123&lists=in:1,2&user_data.segment_tier=eq:premium",
"custom_properties" => [
"is_push_delivery_active" => [
"value" => "true"
],
"segment_tier" => [
"type" => "string",
"value" => "premium"
],
"old_flag" => [
"type" => "string",
"value" => null
]
]
]
));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);Responses
202 Accepted
{
"message": "Profile bulk update has been queued for processing.",
"publish_time": "2026-04-28 12:00:00",
"request_id": "0193c1a2-7b4e-7d21-8f3a-2c9e4b6d8a10",
"status": "accepted"
}
400 Bad Request
{
"code": 400,
"title": "Bad request.",
"message": "The request is not valid.",
"trace_id": "99a84211-f73d-4ff8-acdf-eb3e06bb9d62"
}
500 Internal Server Error
{
"code": 500,
"title": "Internal server error.",
"trace_id": "99a84211-f73d-4ff8-acdf-eb3e06bb9d62"
}
Responses