Returns the messages people have sent to the caller org's connected chat bots,…
Returns the messages people have sent to the caller org's connected chat bots, oldest first, in the portable envelope shape every transport normalises…
GET /v1/channels/inbox
| Address | https://api.hanzo.ai/v1/channels/inbox |
| Method | GET |
| Operation | get_channels_inbox |
| Auth | Authorization: Bearer $HANZO_API_KEY |
Returns the messages people have sent to the caller org's connected chat
bots, oldest first, in the portable envelope shape every transport normalises
into. It is a CURSOR feed, not a search: pass the returned cursor back as
since to get only what has arrived since. Only this org's messages are
stored under this org, so the feed can never carry another tenant's chat.
Request
2 fields.
| Field | In | Type | Required | Description |
|---|---|---|---|---|
since | query | string | — | Since is the exclusive cursor: only messages with a higher row id come back. |
limit | query | string | — | Limit caps how many messages come back. |
Response
| Status | Body | Meaning |
|---|---|---|
200 | inboxPage | ok |
200 body — 12 fields.
| Field | In | Type | Always | Description |
|---|---|---|---|---|
cursor | body | integer | — | Cursor is the row id to pass back as since for the next page. |
messages | body | inboxView[] | — | Messages are the inbound messages, oldest first. |
messages[].account | body | string | — | Account is the lowercased external id of the org's connected account on that transport: the Discord guild id, the Slack team id, the Teams AAD tenant id, or… |
messages[].channel | body | string | — | Channel is the transport this message arrived on — discord, slack, teams or telegram — and the :channel segment to reply through. |
messages[].createdAt | body | integer | — | CreatedAt is Unix SECONDS, stamped by the ingest goroutine when the message was accepted — not the transport's own send time. |
messages[].id | body | integer | — | ID is the store's row id, assigned on insert — SERVER-SET, and the cursor: pass a page's last id back as since. |
messages[].replyTo | body | string | — | ReplyTo is the transport's reply target for this message: Slack's thread_ts, or the Telegram message id it arrived as. |
messages[].roomId | body | string | — | RoomID is the conversation on the ORIGINATING transport, and the value to send back as room.id: a Discord channel snowflake, a Slack conversation id (D… IM,… |
messages[].roomKind | body | string | — | RoomKind is how ingest classified the room: "dm", "group" or "thread". |
messages[].sender | body | string | — | Sender is the TRANSPORT-NATIVE user id of whoever wrote the message — a Discord member.user.id, a Slack U… user id, a Teams aadObjectId (falling back to… |
messages[].senderUser | body | string | — | SenderUser is the HANZO account subject that chat identity is linked to, resolved at ingest through the org's user link. |
messages[].text | body | string | — | Text is the body as the transport delivered it, with the bot mention already stripped by the ingress adapter (on Discord it is the /hanzo prompt argument,… |
Failure carries the platform error shape — see Errors.
Examples
hanzo channels inboximport { Configuration, ChannelsApi } from 'hanzoai';
const api = new ChannelsApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getChannelsInbox();from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import ChannelsApi
client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = ChannelsApi(client).get_channels_inbox()cfg := cloud.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := cloud.NewAPIClient(cfg)
resp, _, err := client.ChannelsAPI.GetChannelsInbox(context.Background()).Execute()
if err != nil {
return err
}use hanzo_cloud::apis::{configuration::Configuration, channels_api};
let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();
let result = channels_api::get_channels_inbox(&cfg, Default::default()).await?;import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.ChannelsApi;
ApiClient client = new ApiClient();
client.setRequestInterceptor(b -> b.header("Authorization", "Bearer " + System.getenv("HANZO_API_KEY")));
var result = new ChannelsApi(client).getChannelsInbox();curl https://api.hanzo.ai/v1/channels/inbox \
-H "Authorization: Bearer $HANZO_API_KEY"The door reaches channels through the channels tool, which names its 7 operations with its own verbs — this one among them, under a name only the door declares. describe explains any of them:
curl -X POST https://api.hanzo.ai/v1/mcp \
-H "Content-Type: application/json" \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "describe",
"arguments": {
"op": "list_channels"
}
}
}'How is this guide?