Skip to main content
POST
Update people in batch
Update up to 100 existing people in the workspace, identified by their id. Each record takes the same fields as update a person, native fields and customFieldValues alike, and is updated on its own: a record that fails, for instance because its id matches no person you can access, does not prevent the others from being updated. See batch requests for the 100-record limit and how to read the response.
Fields with a list of values (groups, companies, addresses, emails, phones, urls) will replace the old values. This means that you must provide the entire list of values for that field, not just the values you want to add.
groups replaces the groups of the person, and removing a group deletes data. A group you can access that is missing from groups is removed from the person, together with the person’s custom field values in that group. Leave groups out to keep the person’s groups unchanged.This is the opposite of create people in batch, where groups only adds. A script that creates a person when it has no id and updates it otherwise gets opposite results from the same payload: the create adds the listed groups, the update removes every other group.
Each succeeded result lists, in removedGroups, the groups the update removed the person from, empty when it removed none. The records of one person, by its id or by the id of a person merged into it, are merged into one update, in the order you sent them: the last value given for a field wins, and customFieldValues are merged group by group, the last value given for a custom field winning. With "firstName": "Foo" then "firstName": "Bar", the person ends up named Bar. The merged update is validated as a whole: if it is invalid, every record of that person fails with that error. Each of those records gets its own result, with the person as finally updated. Records naming the same new company, by name, are all linked to one created company. Names match exactly, so Acme and acme are two companies. Each updated person comes back in full, as in the response of update a person. A record that was updated but not entirely, for instance because the person could not be added to one of its groups, succeeds with a warnings list explaining what was not applied.

Authorizations

Authorization
string
header
required

API key for authentication

Headers

Idempotency-Key
string

A unique key, such as a UUID, that makes retrying this request safe: a retry with the same key and body returns the original response without running the operation again. Keys are kept for 24 hours after the request completes.

Maximum string length: 255
Example:

"8e03978e-40d5-43e8-bc93-6894a57f9324"

Body

application/json
records
object[]
required
Maximum array length: 100

Response

The outcome of each record, with each updated person.

data
object
required
Example:
deprecations
string[]
Example: