Skip to content
Inkbox

Inkbox

BlogContactDocs
GuidesAPI Reference

Ctrl K

GuidesAPI Reference

Jump to

Manage Contacts

CRUD and reverse-lookup endpoints for the organization's contact directory. All contacts are org-scoped; the caller's organization is derived from the auth context.


Create contact POST

POST /contacts

Create a new contact. At least one of given_name, family_name, company_name, or preferred_name must be non-empty (the vCard FN rule). If preferred_name is omitted it is synthesized from the other name fields.

Request body

FieldTypeRequiredDescription
preferred_namestring | nullNoDisplay name (max 255 chars). Synthesized if omitted.
name_prefixstring | nullNoe.g. "Dr." (max 32)
given_namestring | nullNoFirst name (max 128)
middle_namestring | nullNoMiddle name (max 128)
family_namestring | nullNoLast name (max 128)
name_suffixstring | nullNoe.g. "Jr." (max 32)
company_namestring | nullNoCompany (max 255)
job_titlestring | nullNoTitle (max 255)
birthdaystring | nullNoISO YYYY-MM-DD
notesstring | nullNoFree-text note on the contact
emailsobject[]NoUp to 50 items. See Contact object.
phonesobject[]NoUp to 50 items (E.164 values)
websitesobject[]NoUp to 25 items
datesobject[]NoUp to 25 non-birthday dates
addressesobject[]NoUp to 10 postal addresses
custom_fieldsobject[]NoUp to 50 free-form label/value pairs
access_identity_idsUUID[] | nullNoControls who can see the new contact. Omit (or null) → wildcard (every agent sees it, default). [] → nobody but admins/humans see it. Explicit list → only these identities see it.

Request example

JSONJSON

Response (201)

Returns the created contact with an inlined access array (see Contact object).

Error responses

StatusDescription
400vCard FN rule violated — no name fields provided
404One or more access_identity_ids do not resolve to an active identity in your org
422Invalid email, non-E.164 phone, duplicate email/phone, or more than one is_primary

Code examples


List contacts GET

GET /contacts

List contacts visible to the caller. Scoped agents only see contacts they have access to; admins and Clerk JWT users see every contact in the org.

Query parameters

ParameterTypeDefaultDescription
qstringCase-insensitive substring match over name, company, job title, and the notes field. Max 100 chars.
orderstringname"name" (preferred_name ascending) or "recent" (created_at descending)
limitinteger50Results per page (1–200)
offsetinteger0Offset for pagination

Response (200)

Returns an array of contact objects, each with an inlined access array.

Code examples


Lookup contact GET

GET /contacts/lookup

Reverse-lookup contacts by a single field. Useful for routing inbound email or phone calls to a known contact.

Query parameters

Exactly one of the following must be provided:

ParameterTypeDescription
emailstringExact match against a stored email (canonicalized to lowercase)
email_containsstringSubstring match on stored email values (case-insensitive)
email_domainstringSuffix match on @<domain>. Leading @ tolerated (max 253 chars)
phonestringExact match against a stored E.164 phone number
phone_containsstringSubstring match on stored E.164 phone values

Response (200)

Returns an array of contact objects (up to 200). An empty array means no match.

Error responses

StatusDescription
400Zero or more than one filter provided; or phone is not a valid E.164 number

Code examples


Get contact GET

GET /contacts/{contact_id}

Fetch a single contact by its UUID.

Path parameters

ParameterTypeDescription
contact_idUUIDUnique contact identifier

Code examples


Update contact PATCH

PATCH /contacts/{contact_id}

Update a contact using JSON-merge-patch semantics:

  • Omit a field to leave it unchanged
  • Send a value to set it
  • Send null on a nullable scalar to clear it
  • Send a list to replace the stored list wholesale (no per-item merge)

After applying the patch, the server re-runs the FN rule against the merged state — if the update would leave every name field empty, the request 400s.

Path parameters

ParameterTypeDescription
contact_idUUIDUnique contact identifier

Request body

Any subset of the Create contact body fields. access_identity_ids cannot be changed via PATCH — use the Access control endpoints instead.

Code examples


Delete contact DELETE

DELETE /contacts/{contact_id}

Delete a contact. Returns 204 No Content on success.

Path parameters

ParameterTypeDescription
contact_idUUIDUnique contact identifier

Code examples


Contact object

Top-level fields

FieldTypeDescription
idUUIDUnique contact identifier
organization_idstringOwning organization
preferred_namestring | nullDisplay name — always non-empty in responses
name_prefixstring | null
given_namestring | null
middle_namestring | null
family_namestring | null
name_suffixstring | null
company_namestring | null
job_titlestring | null
birthdaystring | nullISO YYYY-MM-DD
notesstring | nullFree-text note
emailsobject[]See Email item
phonesobject[]See Phone item
websitesobject[]See Website item
datesobject[]See Date item
addressesobject[]See Address item
custom_fieldsobject[]See Custom field item
statusstringactive or deleted
created_atstringISO 8601
updated_atstringISO 8601
accessobject[]Inlined access rules — either a single wildcard row (identity_id: null), an explicit per-identity list, or empty

Email item

FieldTypeDescription
valuestringEmail address (stored lowercased)
labelstring | nulle.g. "work", "home" (max 64)
is_primarybooleanAt most one email per contact is primary

Phone item

FieldTypeDescription
value_e164stringE.164 phone number (e.g. +15551234567)
labelstring | nulle.g. "mobile", "work" (max 64)
is_primarybooleanAt most one phone per contact is primary

Website item

FieldTypeDescription
urlstringHTTP/HTTPS URL (max 2048)
labelstring | nulle.g. "personal", "linkedin" (max 64)

Date item

FieldTypeDescription
datestringISO YYYY-MM-DD
labelstringRequired free-string label (e.g. "anniversary")

Address item

All fields are optional free text.

FieldTypeDescription
streetstring | nullStreet line(s)
citystring | null
regionstring | nullState, province, or region
postalstring | nullPostal or ZIP code
countrystring | nullCountry name or ISO code
labelstring | nulle.g. "home", "work"

Custom field item

FieldTypeDescription
labelstringField key (max 128)
valuestringField value (max 1024)

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

Manage Contacts