查看某个 Identity 使用过的 Template 及其 Session 统计。
GET /api/v1/forward/identities/{identity_id}/agents
请求头
| Header | 是否必填 | 说明 |
|---|---|---|
| Authorization | 是 | Bearer <PAT 或 SAT> |
路径参数
| 参数 | 类型 | 是否必填 | 说明 |
|---|---|---|---|
| identity_id | string | 是 | Forward Identity ID。 |
示例响应
HTTP 200 OK
响应字段
| 字段 | 类型 | 说明 |
|---|---|---|
| data | array | Template 使用统计列表。 |
| data[].template_id | string | Forward Template ID。 |
| data[].template_name | string | Template 名称。 |
| data[].session_count | integer | 该 Identity 使用该 Template 创建的 Session 数量。 |
| data[].last_active_at | string | null |
错误
| HTTP | Type | Code | 触发条件 |
|---|---|---|---|
| 401 | authentication_error | authentication_required | PAT 或 SAT 无效、已过期或缺失。 |
| 404 | not_found_error | - | Identity 不存在或当前调用方不可见。 |