Upsert record
Create or update a record based on unique values.
Overview
The upsert method creates or updates a record depending on whether it already exists or not. If a matching record exists, it will be updated. Otherwise, a new record will be created. The request body accepts the following properties which specify how to create or update the record:match and one of create, create_or_update, or create_or_update_if_empty.
All other properties are optional.
The upsert method is the most reliable way of sending data into Unify, so if
you’re not sure what method to use, this is the one we recommend.
Examples
Upsert a company
Upsert a company
Upsert a person
Upsert a person
company is the name of a reference attribute on the
person object which references a company object record. This request will
create a new company if it doesn’t already exist, update it if it does, and
then link this person to that company.Upsert a custom record
Upsert a custom record
product_user:create_or_update, these
values will be filled in if the record is created or overridden if an
existing record is found.Usage
Authorizations
Path Parameters
The API name of an object, e.g. company, person, opportunity, or a
custom object's API name.
Query Parameters
Validation mode for request data.
strict: Reject requests if any attribute is invalid or unrecognized.ignore_invalid: Ignore unknown attributes and omit invalid values for optional attributes. Reject requests with an invalid body structure or invalid required attributes.
strict, ignore_invalid Body
Request body for upserting a record.
At least one of create, create_or_update, or create_or_update_if_empty
must be provided. Together, these properties must include all required
attributes.
Attribute values used to find an existing record. Include at least one unique attribute. Additional attributes narrow the match.
Attribute values used when no record matches. These take precedence over other creation values.
Attribute values used when a record matches. These take precedence over other update values.
Attribute values applied to a matching record only where the existing
value is null. Values in update and create_or_update take
precedence.
Attribute values used for both creation and updates. Values in create
or update take precedence.
Attribute values used for creation, or for updates where the existing
value is null. Values in all other properties take precedence.