Create or update a user
Create or update one of your users, keyed by (workspace, external_user_id). Sending the same external_user_id again updates the record; omitted fields are left untouched — so this is both create and update.
kind: "user"; the rest are anonymous kind: "visitor" records Peeve mints itself. This endpoint writes users only — it requires a real external_user_id. To read them back, use GET /v1/contacts with ?kind=user.Credential: workspace secret key (sk_…) — not a user token. This runs in your backend on a signup hook or a schedule; tying a production pipeline to one employee’s token would break the day they leave.
Identity fields are encrypted at rest. plan is a plaintext display name. attributes is the server-side equivalent of the browser’s setContext.
Authorizations
The workspace secret key (sk_…) as Authorization: Bearer sk_…. X-Peeve-Key is accepted too.
Body
Your stable id for this user. The identity key — it ties the record to its history, so it must survive key rotation.
Encrypted at rest, indexed by a keyed hash so lookup still works.
Encrypted at rest.
Encrypted at rest.
Encrypted at rest.
The user's plan in your product, as a display name. Plaintext; it does not affect your Peeve entitlements.
80When the account was created in your product. Distinguishes a new signup from a returning user browsing logged out.
A token your backend issues for this user, stored encrypted so a Custom API connector can call your API as them. Never travels through the browser.
Free-form business context, merged into the user's stored attributes. Plaintext and non-secret — identity belongs in the fields above.