Hanzo
OpenapiChannels

Edits the caller org's access policy for one channel and answers the policy as…

Edits the caller org's access policy for one channel and answers the policy as GET would, so both verbs return ONE shape. It requires ORG ADMIN.

PUT /v1/channels/allowlist

Addresshttps://api.hanzo.ai/v1/channels/allowlist
MethodPUT
Operationput_channels_allowlist
AuthAuthorization: Bearer $HANZO_API_KEY

Edits the caller org's access policy for one channel and answers the policy as GET would, so both verbs return ONE shape. It requires ORG ADMIN. Every field but channel is optional and applied only when provided: an empty policy string leaves that policy alone, an absent or null list leaves that list alone, and an EMPTY list clears it. It writes only CONFIG-sourced allow entries — senders approved through pairing belong to the approval flow, so a policy edit can never revoke one. An unknown channel is a 404.

Request

8 fields, body application/json (required).

FieldInTypeRequiredDescription
accessGroupsbodyobjectAccessGroups REPLACES the org's named access groups, as group name -> channel -> entries.
accessGroups.*bodyobject
accessGroups.*.*bodystring[]
channelbodystringChannel is the transport to edit: discord, slack, teams or telegram.
dmbodystring[]DM REPLACES the config-managed DM allow entries. Absent or null leaves them alone; an empty list clears them.
dmPolicybodystringDMPolicy sets how direct messages are admitted: "pairing" (a person must be approved first), "allowlist" (only listed senders) or "open".
groupbodystring[]Group REPLACES the config-managed group allow entries.
groupPolicybodystringGroupPolicy sets how group and thread rooms are admitted: "open", "allowlist" or "disabled".

Response

StatusBodyMeaning
200allowlistViewok

200 body — 8 fields.

FieldInTypeAlwaysDescription
accessGroupsbodyobjectAccessGroups is the org's named sender sets, as group name -> channel -> member entries, held once for the whole org.
accessGroups.*bodyobject
accessGroups.*.*bodystring[]
dmbodystring[]DM is the CONFIG-managed DM allow entries — the list PUT /v1/channels/allowlist owns and replaces wholesale.
dmPolicybodystringDMPolicy decides every inbound DIRECT message, defaulting to "pairing" when the org has never set one.
groupbodystring[]Group is the CONFIG-managed group allow entries, consulted only while GroupPolicy is "allowlist".
groupPolicybodystringGroupPolicy decides every inbound GROUP or THREAD message — a thread is a group surface — defaulting to "open". "open" admits every sender in the room.
pairedbodystring[]Paired is the senders admitted by PAIRING — the entries POST /v1/channels/pairing/approve minted, DM scope only.

Failure carries the platform error shape — see Errors.

Examples

hanzo channels allowlist replace

Channels API · All Hanzo APIs · Interactive reference

How is this guide?

On this page