Records
Assert a CRM Record (Upsert)
Creates or updates a record using a unique attribute to find an existing match.
- Match found → the record is updated and
200is returned. - No match → a new record is created and
201is returned.
This is the recommended endpoint for bulk imports and sync jobs.
Required scope: crm:write
PUT
Assert a CRM record (upsert)
Creates or updates a record depending on whether a matching record already exists. This is the recommended endpoint for sync pipelines and bulk imports.Documentation Index
Fetch the complete documentation index at: https://developer.zeeg.me/llms.txt
Use this file to discover all available pages before exploring further.
- Match found → updates the existing record and returns
200 OK. - No match → creates a new record and returns
201 Created.
Path parameter
| Parameter | Type | Description |
|---|---|---|
objectSlug | string | The slug of the custom CRM object to assert into (e.g. products, deals). |
Query parameter
| Parameter | Type | Required | Description |
|---|---|---|---|
matchingAttribute | string | Yes | The attribute slug used to look up an existing record. The API searches for a record where this attribute’s value exactly equals the value you send in the request body. |
Request body
A flat JSON object of attribute slug → value pairs. The value ofmatchingAttribute must be included in the body — it is both the lookup key and the new value to persist.
null on create, and left unchanged on update.
How matching works
The API performs exact equality matching on thematchingAttribute value. Only one record is ever matched. If multiple records somehow share the same value (e.g. before you marked the attribute as unique), the first match is used.
sku = <value from body>.
Choosing the right matching attribute
Pick an attribute that uniquely identifies a record in your source system — an external ID, a product SKU, a deal number, an email address. Mark it asisUnique on the object schema to prevent collisions.
Uniqueness constraints
If another attribute on the record is markedisUnique, the assert will fail with 400 if you try to assign a value that already belongs to a different record. You can always re-assert the same unique value back onto the same record without error.
Error: matching value is empty
If the value ofmatchingAttribute in the request body is null or an empty string, the API returns 400 Bad Request. Always include a non-empty value for the matching attribute.
Example: bulk product sync
Your external catalog has 10,000 products. Run assert in a loop:Distinguishing create vs. update
Check the HTTP status code in the response:| Status | Meaning |
|---|---|
201 Created | No match was found; a new record was created. |
200 OK | A matching record was found and updated. |
When to use this endpoint
- Periodic sync jobs — push updated records from an external system on a schedule.
- Webhook-driven updates — handle incoming webhooks that may create or update a record depending on whether it exists.
- Bulk initial import — send all records from a legacy system without checking for duplicates first.
- Idempotent writes — retry failed requests safely; asserting the same data again results in an update (200) with no duplicate.
Authorizations
Path Parameters
Slug of the custom CRM object.
Query Parameters
Attribute slug to use when searching for an existing record. Uses exact equality matching.
Body
application/json
Flat object of attribute slug → value pairs.
Last modified on May 7, 2026