Create/Update object records in bulk
Create/Update object records in bulk
Create/Update object records in bulk
How Upsert Works:
identifiers, or provide only ext_id (if it doesn’t already exist). A new record is created with a Brevo-generated id.id (Brevo internal ID) or an ext_id that already exists. The matching record is updated with the new attribute values.id is for updates only. Providing an id that does not belong to an existing record will fail during async processing (the HTTP response will still be 202, but the record will be rejected in the background). To create a new record with a stable external reference, use ext_id instead.Request Structure:
Each object record in the records array can include:
identifiers: Either id (internal Brevo ID) or ext_id (your external system ID) — required for updates. Note: use id (singular), not ids.attributes: Key-value pairs where each key is the attribute key (e.g., company_name), not the attribute label (e.g., “Company Name”).associations: Controls linking and unlinking of associated records (optional). Each entry specifies:
object_type: The type of the associated objectaction: link (default) to create the association, or unlink to remove itrecords: The associated records to link or unlink (each identified by ext_id or id)link and unlink actions can be submitted for the same object_type in a single record entryCommon mistake: Passing the attribute label (the display name you see in the UI) instead of the attribute key will cause the attribute to be silently ignored and the record may not be created as expected.
Asynchronous Processing:
processId (HTTP 202 Accepted)API and Schema Limitations:
Important Behaviors:
link and unlink actions can be submitted for the same object_type in a single record entrycategory and multiple_category attributes, pass the option key as the value (not the option label or option ID).id identifier (internal Brevo ID) can only be used for updating existing records. To create new records, either omit identifiers (Brevo auto-generates an ID) or provide an ext_id.Errors:
The API key should be passed in the request headers as api-key for authentication.
Object type for the records to upsert. Must be a previously created custom object type. Only lowercase alphanumeric characters and underscores are allowed (max 32 characters).
Unique Id for the batch process used to track the status of the batch. How to use this processId: Refer to the Get process status API to check the execution status of this batch using the returned processId.