Change, deactivate or reactivate a member
PATCHhttps://app.booksbyinstant.com/api/integrator/v1/customers/{id}/members/{memberId}
A change of role or entity access takes effect on the member's next request; a chat turn already running ends. active: false deactivates the member and revokes their tokens for good; active: true reactivates them with their role and access, and new tokens must be issued.
updateMember · This page as markdown
Example request
cURL
curl -X PATCH 'https://app.booksbyinstant.com/api/integrator/v1/customers/01900000-0000-7000-8000-000000000000/members/01900000-0000-7000-8000-000000000000' \
-H "Authorization: Bearer $INTEGRATOR_CREDENTIAL" \
-H "Content-Type: application/json" \
-d '{
"name": "string",
"language": "en",
"timezone": "Europe/Copenhagen",
"role": "admin",
"entityAccess": {
"mode": "all"
},
"active": true
}'JavaScript
// Node 18 or later, in an ES module (.mjs), which allows the top-level await.
const res = await fetch("https://app.booksbyinstant.com/api/integrator/v1/customers/01900000-0000-7000-8000-000000000000/members/01900000-0000-7000-8000-000000000000", {
method: "PATCH",
headers: {
Authorization: `Bearer ${process.env.INTEGRATOR_CREDENTIAL}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"name": "string",
"language": "en",
"timezone": "Europe/Copenhagen",
"role": "admin",
"entityAccess": {
"mode": "all"
},
"active": true
}),
});
const data = await res.json();Python
import os
import requests
res = requests.patch(
"https://app.booksbyinstant.com/api/integrator/v1/customers/01900000-0000-7000-8000-000000000000/members/01900000-0000-7000-8000-000000000000",
headers={
"Authorization": f"Bearer {os.environ['INTEGRATOR_CREDENTIAL']}",
},
json={
"name": "string",
"language": "en",
"timezone": "Europe/Copenhagen",
"role": "admin",
"entityAccess": {
"mode": "all",
},
"active": True,
},
)
data = res.json()Authorization
Bearer token live_<100 hex>
Authorization: Bearer <secret>. A 401 answers WWW-Authenticate: Bearer realm="instant-integrator-api".
Path parameters
-
idstring · uuid requiredThe customer's id.
-
memberIdstring · uuid requiredThe member's id.
Request body
At most 32768 bytes.
Body application/json, required
object
Send active alone (false deactivates the member, true reactivates them), or at least one of the other fields; the same values again change nothing. An admin has access to all entities, so role admin with a selection is refused, and a selection names entities of this customer only. A deactivated member's role and entity access change only after active: true; their name, language and time zone can still change. The owner stays an admin and is never deactivated, and the company keeps at least one admin.
send at least 1 field · no other fields
-
namestringThe member's name: 1 to 120 characters after leading and trailing whitespace is removed. With two or more words, the last is the last name.
at least 1 character
-
languagestringOne of Instant's languages.
One of 15 values
endesvnbdafresplpt-BRithrtrhearro -
timezonestringAn IANA time zone.
1 to 100 characters
-
rolestringOne of
adminuserauditor -
entityAccessone of 2 shapesall: every entity of the customer, and it clears a selection. selected: the entities entityIds names.
Either object
no other fields
-
modestring requiredalways
all
-
Or object
no other fields
-
modestring requiredalways
selected -
entityIdsarray of string · uuid requiredUp to 500 of the customer's entity ids, each at most once: the same id in upper and lower case counts as twice. An empty selection reaches no entity until one is added, so a restricted member can be created before the customer has an entity.
at most 500 items · no repeated items
-
-
activeboolean
Example, built from the schema
{
"name": "string",
"language": "en",
"timezone": "Europe/Copenhagen",
"role": "admin",
"entityAccess": {
"mode": "all"
},
"active": true
}Responses
200
The member.
Body application/json
object
-
memberobject requiredA person in a customer, with a role and entity access.
-
idstring · uuid requiredThe member's id.
-
referencestring requiredThe integrator's own reference for the member, unique across all its customers.
-
namestring requiredThe member's name.
-
rolestring requiredadmin manages the company and sees every entity, user works within their entities, auditor reads.
One of
adminuserauditor -
ownerboolean requiredTrue for the one member who owns the customer.
-
languagestring or null requiredThe member's language: one of the language values the requests take, or null when none is set.
-
timezonestring or null requiredThe member's IANA time zone, or null when none is set.
-
activeboolean requiredFalse while the member is deactivated.
-
joinedAtstring · date-time requiredWhen the member joined the customer. ISO 8601 in UTC with milliseconds, such as 2026-11-06T10:00:00.000Z.
-
deactivatedAtstring · date-time or null requiredWhen the member was deactivated, or null while active. ISO 8601 in UTC with milliseconds, such as 2026-11-06T10:00:00.000Z.
-
entityAccessone of 2 shapes requiredWhich of the customer's entities the member works in: all of them, or a selection. An admin always has all. A deactivated member shows the selection that reactivating them restores.
Either object
-
modestring requiredalways
all
-
Or object
-
modestring requiredalways
selected -
entityIdsarray of string · uuid requiredThe entity ids of the selection, sorted.
-
-
tokensobject required-
activeinteger requiredHow many of the member's tokens are active and unexpired, at most 20.
at least
0
-
-
Example, built from the schema
{
"member": {
"id": "01900000-0000-7000-8000-000000000000",
"reference": "string",
"name": "string",
"role": "admin",
"owner": true,
"language": "string",
"timezone": "string",
"active": true,
"joinedAt": "2026-01-15T09:30:00.000Z",
"deactivatedAt": "2026-01-15T09:30:00.000Z",
"entityAccess": {
"mode": "all"
},
"tokens": {
"active": 0
}
}
}400
The body is not one JSON object, or a field is invalid; error says which. Also when active comes with another field, nothing is to change, role is admin with a selected entity access, or an entity id is not the customer's.
Body application/json
object Error
Every answer that is not a success.
-
errorstring requiredInstant's sentence for people. A 4xx keeps the refusal's own sentence; a 5xx always says "Instant is temporarily unavailable. Please try again shortly."
-
codestring requiredStable, and what a caller branches on: VALIDATION_ERROR (400), UNAUTHENTICATED (401), FORBIDDEN (403), NOT_FOUND (404), CONFLICT (409), LIMIT_EXCEEDED (413), UNSUPPORTED_MEDIA_TYPE (415), UNREADABLE_FILE (422), RATE_LIMITED (429) and UNAVAILABLE (5xx). More codes may be added; treat one you do not know by its status.
-
retryAfterintegerSeconds to wait before retrying, also sent as the
Retry-Afterheader. Present only when there is a wait, as on a 429.at least
1 -
existingIdstring · uuidOn a 409 that names the object already there, such as a customer with that reference: its id.
Example, built from the schema
{
"error": "string",
"code": "VALIDATION_ERROR",
"retryAfter": 1,
"existingId": "01900000-0000-7000-8000-000000000000"
}401
The credential is missing, malformed, unknown, revoked or rotated, or its integrator is disabled. All of these answer the same way.
Headers
-
WWW-AuthenticatestringBearer realm="instant-integrator-api"
Body application/json
The Error object, as in 400.
404
id or memberId name nothing this caller can see.
Body application/json
The Error object, as in 400.
409
The member is deactivated and must be reactivated first; the owner would stop being an admin or be deactivated; the company would have no admin left; or it changed meanwhile.
Body application/json
The Error object, as in 400.
5XX
Instant is temporarily unavailable. Retry later, with backoff.
Body application/json
The Error object, as in 400.