Skip to content
Inkbox

Inkbox

BlogContactDocs
GuidesAPI Reference

Ctrl K

GuidesAPI Reference

Jump to

Contact Access Control

Control which agent identities can see a given contact. Contacts use a wildcard-default model: a newly created contact has one access row with identity_id: null, which grants visibility to every active agent in the organization. Narrow that set by revoking identities (the wildcard is materialized into per-identity rows the first time you revoke); widen it by resetting to the wildcard.

Granting a per-identity rule on a wildcard contact returns 409 redundant_grant. The wildcard already grants everyone; revoke it first if you want a narrower set.

Humans (Clerk JWT) and admin API keys always see every contact regardless of access rules. Only agent-scoped API keys are narrowed by the rules below.


Grant identity access POST

POST /contacts/{contact_id}/access

Grant an identity access to a contact, or reset the contact to the wildcard.

Auth: admin API key or Clerk JWT only. Agent-scoped API keys cannot widen access.

Path parameters

ParameterTypeDescription
contact_idUUIDContact ID

Request body

FieldTypeRequiredDescription
identity_idUUID | nullYesIdentity to grant, or null to reset to the wildcard (drops every explicit row and inserts a single wildcard row — this widens visibility)

Request example

JSONJSON

Response (201)

JSONJSON

Error responses

StatusDescription
404Contact or identity not found in your organization
409Identity already has a per-identity grant; or redundant_grant — the wildcard already grants this identity

Code examples


List access rules GET

GET /contacts/{contact_id}/access

List the access rows for a contact. The response is either a single wildcard row (identity_id: null, the default state) or a list of explicit per-identity rows — never a mixed state. Consumer UIs typically render the wildcard case as "All agents".

Path parameters

ParameterTypeDescription
contact_idUUIDContact ID

Response (200)

JSONJSON

Code examples


Revoke identity access DELETE

DELETE /contacts/{contact_id}/access/{identity_id}

Revoke an identity's access. If the contact is currently wildcard-access, the server atomically fans out the wildcard into per-identity rows for every active agent in the org and then drops the target identity's row — so the revoke narrows without also revoking everyone else.

A claimed agent API key may only revoke itself. Admins and JWT users may revoke any identity.

Path parameters

ParameterTypeDescription
contact_idUUIDContact ID
identity_idUUIDIdentity to revoke

Response

Returns 204 No Content on success.

Error responses

StatusDescription
403Claimed agent attempted to revoke another identity
404Contact or access row not found (including the duplicate-revoke race case)

Code examples


Access rule object

FieldTypeDescription
idUUIDUnique access rule identifier
contact_idUUIDThe contact this rule grants access to
identity_idUUID | nullThe agent identity granted access, or null for the wildcard sentinel ("every active agent sees this contact")
created_atstringCreation timestamp (ISO 8601)

Inkbox

Copyright © 2026 Inkbox

This site is protected by reCAPTCHA.

Google Privacy Policy and Terms of Service apply.

Website

Inkbox

Copyright © 2026 Inkbox

This site is protected by reCAPTCHA.

Google Privacy Policy and Terms of Service apply.

Website

Contact Access Control