---
title: ข้อมูลอ้างอิง API: Channels
description: Platform API v1 ส่วน Channels: path, พารามิเตอร์, ฟิลด์ของคำขอและคำตอบ, scope, idempotency และข้อผิดพลาดของทุก operation จาก contract
url: https://agentlab.cresclab.com/docs/th/api/channels
language: th
updated: 2026-12-05
---

# ข้อมูลอ้างอิง API: Channels

Platform API v1 ส่วน Channels: path, พารามิเตอร์, ฟิลด์ของคำขอและคำตอบ, scope, idempotency และข้อผิดพลาดของทุก operation จาก contract

> [!NOTE]
> สร้างจาก API contract (Agent Lab Platform API 1.0.0-alpha.1) คำอธิบายเป็นภาษาอังกฤษตามต้นฉบับใน contract

The workspace's channel connections, read and managed as the acting member. Connecting Slack
is a browser step the API answers a connect link for; no provider credential is ever
answered.

## The workspace's channels

`GET /v1/workspaces/{workspaceId}/channels`

Every channel connection (Slack, LINE, Teams), newest first, as the console's channel list
shows it. The platform lists at most the 50 newest connections of a workspace;
`truncated` is true when there are more, on every page.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:read` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `cursor` | query | `string` | ไม่ | The `nextCursor` of the previous page. Opaque. |
| `limit` | query | `integer` | ไม่ | Items per page. ค่าเริ่มต้น: `50`. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `200` | `application/json`: [ChannelPage](https://agentlab.cresclab.com/docs/th/api/schemas.md#ChannelPage) | A page of channels. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## A LINE channel's monthly push quota

`GET /v1/workspaces/{workspaceId}/channels/line/quota`

How many messages the LINE official account behind a connected LINE channel of this
workspace may push this month, and how many it has, as LINE reports them. `known: false`
when LINE could not be asked; the other fields are then 0 and mean nothing. Needs a member
who may manage the workspace's channels. A channel that is not a connected LINE channel of
this workspace is a 400.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:read` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `connectionId` | query | `string` | ใช่ | The LINE channel, by its id in the channel list. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `200` | `application/json`: [LineQuota](https://agentlab.cresclab.com/docs/th/api/schemas.md#LineQuota) | The quota. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## Connect a LINE official account

`POST /v1/workspaces/{workspaceId}/channels/line`

Connects a LINE official account to the workspace with its Messaging API channel secret and
channel access token, as the console's LINE settings do. LINE is asked to verify the token
first; the credentials are then sealed in the platform's vault and are never answered,
logged or shown again, here or anywhere else. Connecting an account this workspace already
connected replaces its credentials; an account another workspace holds is
`CHANNEL_CLAIMED`. Credentials LINE does not accept are `INVALID_REQUEST`. Needs a member
who may manage the workspace's channels.

Send `Idempotency-Key` to retry safely.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:write` | `member` | `installationToken` | รองรับ |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `Idempotency-Key` | header | `string` | ไม่ | Makes a creating call safe to retry. The same key and body within 24 hours answer the first answer again; the same key with a different body is 409. |

### เนื้อหาคำขอ

`application/json`: [LineConnect](https://agentlab.cresclab.com/docs/th/api/schemas.md#LineConnect)

| ฟิลด์ | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- |
| `channelSecret` | `string` | ใช่ | — |
| `accessToken` | `string` | ใช่ | — |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `201` | `application/json`: [Channel](https://agentlab.cresclab.com/docs/th/api/schemas.md#Channel) | The LINE channel. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `409` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Nothing changed: `CHANNEL_CLAIMED`, the account is connected to another workspace; disconnect it there first (`none`); or the `Idempotency-Key` conflict `IdempotencyConflict` describes. |
| `413` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The body is larger than the operation accepts (`PAYLOAD_TOO_LARGE`, `recovery: none`). |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## Set the LINE push budget

`PUT /v1/workspaces/{workspaceId}/channels/line/push-budget`

How many messages the workspace's LINE summaries may push each calendar month, across its
LINE channels, as the console's summary settings set it. `0` pushes none; the change is
recorded in the workspace's audit log as the acting member's. Needs a member who may manage
the workspace's channels.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:write` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |

### เนื้อหาคำขอ

`application/json`: [LinePushBudget](https://agentlab.cresclab.com/docs/th/api/schemas.md#LinePushBudget)

| ฟิลด์ | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- |
| `ceiling` | `integer` | ใช่ | Pushes the workspace's LINE summaries may send each calendar month; 0 sends none. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `200` | `application/json`: [LinePushBudget](https://agentlab.cresclab.com/docs/th/api/schemas.md#LinePushBudget) | The budget now in force. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `413` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The body is larger than the operation accepts (`PAYLOAD_TOO_LARGE`, `recovery: none`). |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## A link that connects a Slack workspace

`POST /v1/workspaces/{workspaceId}/channels/slack/connect-links`

Connecting a Slack workspace is a browser step, so the API answers a connect link:
a one-time URL, good for ten minutes, that the acting member opens in their own browser.
They approve the install at Slack, and the browser returns to `redirectUri` with `connect`
added to its query: `connected`, `workspaceClaimed` (that Slack workspace is connected to
another Agent Lab workspace; choose another in Slack's switcher) or `failed`. Read
`GET …/channels` for the result. Nothing Slack grants is ever answered.

The install completes only in a browser signed in to Agent Lab as the acting member, so a
link passed to anybody else connects nothing. `redirectUri` must be, byte for byte, one of
the application's registered redirect URIs (`REDIRECT_NOT_REGISTERED`, `configure`). Needs
a member who may manage the workspace's channels. Each call answers a new link.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:write` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |

### เนื้อหาคำขอ

`application/json`: [ConnectLinkCreate](https://agentlab.cresclab.com/docs/th/api/schemas.md#ConnectLinkCreate)

| ฟิลด์ | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- |
| `redirectUri` | `string` | ใช่ | Where the browser returns, one of the application's registered redirect URIs. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `201` | `application/json`: [ConnectLink](https://agentlab.cresclab.com/docs/th/api/schemas.md#ConnectLink) | The connect link. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong (`INVALID_REQUEST`, `none`), or `redirectUri` is not one of the application's registered redirect URIs (`REDIRECT_NOT_REGISTERED`, `configure`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `413` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The body is larger than the operation accepts (`PAYLOAD_TOO_LARGE`, `recovery: none`). |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## Disconnect a channel

`DELETE /v1/workspaces/{workspaceId}/channels/{connectionId}`

Revokes the channel connection, as the console's channel list does: it stops receiving and
answering, its `status` becomes `revoked`, and connecting it again is a new install. What
it collected is kept. Recorded in the workspace's audit log as the acting member's. Needs a
member who may manage the workspace's channels. A channel of another workspace is not
found.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:write` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `connectionId` | path | `string` | ใช่ | The channel, by its id in the channel list. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `204` | — | Disconnected. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## A channel's engagement policies

`GET /v1/workspaces/{workspaceId}/channels/{connectionId}/engagement`

The rooms of the channel with a policy of their own: whether the assistant answers only when
addressed or may join in unprompted, and the standing orders it follows there. A room with
no policy is answered only when addressed. Any member may read them. The platform lists at
most 200 rooms of a channel; `truncated` is true when there are more, on every page. A
channel of another workspace is not found.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:read` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `connectionId` | path | `string` | ใช่ | The channel, by its id in the channel list. |
| `cursor` | query | `string` | ไม่ | The `nextCursor` of the previous page. Opaque. |
| `limit` | query | `integer` | ไม่ | Items per page. ค่าเริ่มต้น: `50`. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `200` | `application/json`: [EngagementPolicyPage](https://agentlab.cresclab.com/docs/th/api/schemas.md#EngagementPolicyPage) | A page of policies. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## Set one room's engagement policy

`PUT /v1/workspaces/{workspaceId}/channels/{connectionId}/engagement`

Replaces the policy of the room `channelRef` names (the provider's own room id) on this
channel: `mode` `addressed_only` or `ambient`, and `standingOrders`, empty for none.
Turning ambient on changes what the assistant does for everybody in the room, so it needs a
member who may manage the workspace's channels; recorded in the workspace's audit log as
theirs. A channel of another workspace is not found.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:write` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `connectionId` | path | `string` | ใช่ | The channel, by its id in the channel list. |

### เนื้อหาคำขอ

`application/json`: [EngagementPolicy](https://agentlab.cresclab.com/docs/th/api/schemas.md#EngagementPolicy)

| ฟิลด์ | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- |
| `channelRef` | `string` | ใช่ | The provider's own id of the room. |
| `mode` | `string` | ใช่ | `addressed_only` or `ambient`. Clients tolerate values added later. |
| `standingOrders` | `string` | ไม่ | What the assistant follows in this room; empty for none. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `200` | `application/json`: [EngagementPolicy](https://agentlab.cresclab.com/docs/th/api/schemas.md#EngagementPolicy) | The room's policy. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `413` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The body is larger than the operation accepts (`PAYLOAD_TOO_LARGE`, `recovery: none`). |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## Who has bound their identity on this provider

`GET /v1/workspaces/{workspaceId}/channels/{connectionId}/identities`

The bindings between a provider's user (a Slack user) and an Agent Lab member, of the
channel's provider in this workspace. A member sees their own; a member who may manage the
workspace's members sees everyone's (`scope`: `own` or `workspace`). Members bind
themselves in the console. The platform lists at most 200 bindings; `truncated` is true
when there are more, on every page. A channel of another workspace is not found.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:read` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `connectionId` | path | `string` | ใช่ | The channel, by its id in the channel list. |
| `cursor` | query | `string` | ไม่ | The `nextCursor` of the previous page. Opaque. |
| `limit` | query | `integer` | ไม่ | Items per page. ค่าเริ่มต้น: `50`. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `200` | `application/json`: [ChannelIdentityPage](https://agentlab.cresclab.com/docs/th/api/schemas.md#ChannelIdentityPage) | A page of bindings. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |

## End an identity binding

`DELETE /v1/workspaces/{workspaceId}/channels/{connectionId}/identities/{identityId}`

Ends a binding: the acting member's own, or anybody's for a member who may manage the
workspace's members. Recorded in the workspace's audit log as the acting member's. A
binding already ended, of another provider or of another workspace is not found.

| Scope | ทำในนามของ | การยืนยันตัวตน | Idempotency-Key |
| --- | --- | --- | --- |
| `channels:write` | `member` | `installationToken` | — |

### พารามิเตอร์

| ชื่อ | ตำแหน่ง | ชนิด | จำเป็น | คำอธิบาย |
| --- | --- | --- | --- | --- |
| `workspaceId` | path | `string` | ใช่ | The workspace, by id. It must be the installation's. |
| `Agentlab-On-Behalf-Of` | header | `string` | ใช่ | The account id of the member the installation acts for: a current member of the workspace whose sign-in to the application there is still live, neither revoked nor expired. When the member's sign-in expires, the application acts for them again once they sign in again. |
| `connectionId` | path | `string` | ใช่ | The channel, by its id in the channel list. |
| `identityId` | path | `string` | ใช่ | The identity binding, by id. |

### คำตอบ

| สถานะ | เนื้อหา | คำอธิบาย |
| --- | --- | --- |
| `204` | — | Ended. |
| `400` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | The request itself is wrong, such as a `cursor` this list did not answer (`recovery: none`). |
| `401` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No token, or a token the platform does not honor. |
| `403` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Refused: `SCOPE_NOT_GRANTED` (`configure`); `WORKSPACE_NOT_INSTALLED`, the path names a workspace other than the installation's (`configure`); `MEMBER_REQUIRED`, no single `Agentlab-On-Behalf-Of` (`none`); `MEMBER_NOT_AUTHORIZED`, the named account is not a current member who signed in to the application here, or the member may not read or do this (`authorize`); `SERVER_TO_SERVER_ONLY`, sent from a browser (`none`); `PRODUCT_ACCESS_DENIED`, the workspace's plan does not include it (`configure`). |
| `404` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | No such operation or resource. |
| `429` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Rate limited (`recovery: retry`). |
| `503` | `application/json`: [Error](https://agentlab.cresclab.com/docs/th/api/schemas.md#Error) | Try again later (`recovery: retry`). |
