GET /api/v1/forward/channels
返回当前账号下的 Channel 记录。
请求头
| Header | 是否必填 | 说明 |
|---|---|---|
| Authorization | 是 | Bearer <PAT> |
查询参数
| 参数 | 类型 | 是否必填 | 默认值 | 说明 |
|---|---|---|---|---|
| channel_type | string | 否 | - | 按 wechat、qq、wecom、feishu 或 dingtalk 过滤。 |
| enabled | boolean | 否 | - | 按人工启停状态过滤。 |
| binding_status | string | 否 | - | 按 unbound、bound 或 expired 过滤。 |
| identity_id | string | 否 | - | 按 Forward Identity ID 过滤。 |
| template_id | string | 否 | - | 按 Forward Template ID 过滤。 |
| limit | integer | 否 | 20 | 分页大小,最大 100。 |
| after_id | string | 否 | - | 向后翻页游标。 |
| before_id | string | 否 | - | 向前翻页游标。 |
示例请求
示例响应
HTTP 200 OK响应字段
| 字段 | 类型 | 说明 |
|---|---|---|
| data | array | 当前页的 Channel 对象。 |
| first_id | string | null | 当前页第一条 Channel ID。 |
| last_id | string | null | 当前页最后一条 Channel ID。 |
| has_more | boolean | 是否还有更多记录。 |
错误
| HTTP | Type | Code | 触发条件 |
|---|---|---|---|
| 400 | invalid_request_error | invalid_pagination | 分页参数不合法。 |
| 400 | invalid_request_error | channel_type_unsupported | 渠道类型过滤条件不支持。 |
| 401 | authentication_error | authentication_required | PAT 无效或已过期。 |
注意事项
after_id和before_id不能同时传入。- 只返回当前调用方账号边界内的 Channel。