Skip to main content
PATCH
An identity is a known visitor: someone who gave an email through identify(), a form or a conversion. This endpoint edits the fields Orwel keeps about them. It is a partial update: fields you leave out of the body are not touched. Typical uses:
  • Sync from your CRM. Write the deal stage, owner or plan back into traits, so the lead in Orwel shows the same context your sales team sees.
  • Fix a name. Forms often send name in lowercase or only a first name.
  • Flag accounts to watch. Set is_favorite from a script for every identity that belongs to a target account.
Requires a secret key (orwel_sk_) with the leads:write scope. The identity must belong to the key’s workspace.

Path parameters

string
required
Identity id (UUID). Get it from List Identities, or from identity_id on a lead.

Body

Send JSON with any of these fields. Sending null clears a field.
string | null
Display name of the person, for example "María López".
object | null
Custom attributes as a flat or nested JSON object, for example { "plan": "growth", "crm_stage": "proposal" }.traits is replaced, not merged. The object you send becomes the whole traits value. To add one key, read the identity first, merge your change, and send the full object. A value that is not an object (a string or an array) clears traits.
boolean | null
Marks the identity as a favorite in the dashboard.
string | null
ISO 8601 timestamp of the last activity, for example "2026-10-20T15:04:05Z". Orwel updates it with every visit; set it only when you import activity that happened outside the site.
email, visitor_id, location fields and first_seen cannot be changed through this endpoint. They come from the visitor’s own activity.

Updating traits without losing existing ones

JavaScript
Reading requires the visitors:read scope on the same key.

Response

200 with the full identity after the update, in data.

Errors

The full format is described in Errors.