v1

latestOpenAPI 3.0.32026-07-26870417.2 KB
chats

Update Chat Access

This endpoint overrides the default chat access for a user. This can only be used to provide access to users for a chat and cannot be used to remove access.

patch/chats/access

Headers

x-phonestring
Example:{{orgPhone}}

Please provide the number of the phone you want to call with this API in the header. The number must be in country code + number format without any characters or spaces, e.g. 919876543210; Alternatively, provide the phone_id (phone-xxxxxxxxxxxx) in the header

Request body

accessobject required
  • An object mapping user emails to boolean access flags
  • Note: This replaces the current override chat access property of the chats

Example: { "alice@gmail.com": true, "bob@gmail.com": false }

chat_idsstring[] required
  • An array of chat_ids to update
replaceboolean
  • When true, the existing chat access overrides are fully replaced with the access map provided in this request
  • When false, the provided access values are merged into the existing overrides (only updating the specified users without removing others)

Response

204 OK

object required

204 No Content