Custom Objects Management
Custom objects let you create and manage object records in your Brevo account
Create or update object records in bulk
This endpoint allows you to insert or update multiple records of a custom object in a single API call. The API sends a request to the URL https://api.brevo.com/v3/objects/{object_type}/batch/upsert
using the POST
method.
This operation is asynchronous. The endpoint returns a processId
that can be used to monitor the status of the request. You can refer to the API endpoint here.
Requirements
- Custom objects are only available for Enterprise or Pro plan accounts.
- This endpoint only supports custom objects, it will not create or update any records for Brevo system objects such as contact, company, deal, task, note, store, order, ticket etc.
- The target object type must already exist in your Brevo schema (see create custom objects help article). The endpoint does not create new object types, and will return an invalid
object_type
error otherwise. - The attributes in your payload must be previously defined in the schema-attributes and the ones that are not defined are ignored as shown here.
- To associate two object records:
- An association between the corresponding object types must exist (see here).
- Both object records must exist before associating them, otherwise the API will return an error.
Limits and behaviour
Limit | Value |
---|---|
Records per request | 1000 in the array |
Payload size | Total request body must not exceed 1 MB |
Attributes per record | 500 attributes max can be passed in each record of the request. Only 500 attributes can be defined for an object type in the database |
Associations per record | 10 associations max can be passed per associated object type in each record of the request. If you need to define more than 10 associations for a given associated object type, you can run multiple requests |
Associations
- Associations must reference existing object records, otherwise the API returns an error.
- For associating custom objects, either use
ext_id
orid
. - Custom objects can be associated with Brevo system objects. For example, with
object_type
as vehicle and associatedobject_type
as company:- For associating contacts,
contact_id
must be used asid
in identifiers. - For associating companies or deals, use the
ext_id
in identifiers, and fill it with the Brevo generated company or deal id e.g.company_id
asext_id
.
- For associating contacts,
For storing attributes of an object record (while creating or updating an object record)
- Use the
attribute_id
, which gets generated while creating an object attribute, as a key. - The
attribute_id
not defined in the object schema will be simply ignored, they will not be created or throw errors.
Attribute name | Datatype | Description |
---|---|---|
records | Array | Records to be created |
attributes | Object | The properties to set and update |
associations | Array | Linked object records |
associations.object_type | String | Type of the associated object |
associations.records | Array of objects | Records associated with the object type |
identifiers | Object | Used for identification of records |
identifiers.ext_id | String | ID of record in the external system that client want to store in the object system. |
identifiers.id | String | ID of object record generated by Brevo |
CURL request
curl --request POST \
--url https://api.brevo.com/v3/objects/object_type/batch/upsert \
--header 'accept: application/json' \
--header 'api-key: YOUR_API_KEY' \
--header 'content-type: application/json' \
--data '
{
"records": [
{
"attributes": {
"make": "Honda",
"model": "Civic",
"color": "Gray",
"year": 2021,
"engine_type": "Diesel"
},
"identifiers": {
"id": 400
},
"associations": [
{
"object_type": "garage",
"records": [
{
"identifiers": {
"id": 435435
}
}
]
},
{
"object_type": "insurance",
"records": [
{
"identifiers": {
"id": 1236
}
},
{
"identifiers": {
"ext_id": "f7e8d9c0ba"
}
}
]
}
]
}
]
}
'
Response
The response codes and their description is mentioned.
Response code | Description |
---|---|
202 | Batch request accepted for processing of upsert object records |
400 | Bad request. Error messages may include: invalid organizationId , invalid object_type , records cannot be empty or more than 1000) |
403 | Custom objects are not available on this account |
404 | Object not found for the provided organization or object type |
500 | Internal server error |
A successful response returns a processId
and a message.
{
"processId": 21,
"message": "Batch object records are being processed"
}
Get the list of object records and total records count for an object
This endpoint allows you to retrieve a paginated list of records of a specific object type, including associated data and a total count of records.
The API sends a request to the URL https://api.brevo.com/v3/objects/{object_type}/records
using the GET
method. The endpoint returns a list of records and total count of the object records. You can refer to the API endpoint here.
Requirements
- This endpoint currently only supports custom objects, it will not return any records for Brevo system objects like contact, company, deal, task, note, store, order, ticket etc.
- Custom objects are only available for Enterprise or Pro plan accounts.
- Confirm that the object type is already defined in your schema, otherwise this endpoint will not return records for undefined object types.
Attribute name | Datatype | Description |
---|---|---|
object_type | String | Object type for attribute |
limit | Integer | Number of records returned per page |
page_num | Integer | Page number for pagination. It is used to fetch the object records on a provided page number. Must be a valid positive integer |
sort | String | Order of the sort. Accepts two possible values: asc or desc |
association | String | Specifies whether association should be included. Accepts two possible values: true or false . |
CURL request
curl --request GET \
--url 'https://api.brevo.com/v3/objects/object_type/records?sort=desc' \
--header 'accept: application/json' \
--header 'api-key: YOUR_API_KEY'
Response
The response codes and their description is mentioned.
Response code | Description |
---|---|
200 | A list of object records for an object type. If association param is set true it will return 5 associated records per association for an object type. |
400 | Bad request (e.g., invalid object_type , invalid page_num provided) |
403 | Custom objects are not available on this account |
424 | Primary attribute not found |
500 | Internal server error |
The response returns a list of object records with attributes, identifiers and associations. It also returns a total count of records for that object type which is useful for pagination.
{
"count": 350,
"records": [
{
"createdAt": "2025-07-22T10:20:30Z",
"updatedAt": "2025-07-22T10:20:30Z",
"identifiers": {
"id": 16789,
"ext_id": "507f1f77bc"
},
"attributes": {
"make": "Toyoto",
"model": "Corolla",
"color": "Black",
"year": 2020,
"engine_type": "Hybrid"
},
"associations": [
{
"object_type": "garage",
"records": [
{
"identifiers": {
"id": 12345
}
},
{
"identifiers": {
"id": 45678
}
}
]
},
{
"object_type": "insurance",
"records": [
{
"identifiers": {
"id": 98765
}
},
{
"identifiers": {
"id": 87654
}
}
]
}
]
}
]
}
Updated 3 days ago