跳转到主要内容
GET
获取终端用户信息

授权

Authorization
string
header
必填

每个请求都通过 API Key 认证:Authorization: Bearer {API_KEY}。应用接口使用应用 API Key,知识库接口使用知识库 API Key(快速开始)。

API Key 应保存在服务端,切勿嵌入客户端代码。缺失或无效的 Key 会返回 HTTP 401unauthorized)。

路径参数

end_user_id
string<uuid>
必填

要查询的终端用户 ID。

响应

成功获取终端用户。

id
string<uuid>

终端用户 ID。

tenant_id
string<uuid>

租户 ID。

app_id
string<uuid> | null

应用 ID。

type
string

终端用户类型。Service API 用户固定为 service-api

external_user_id
string | null

API 请求中提供的 user 标识符(例如 发送对话消息 中的 user 字段)。

name
string | null

终端用户名称。

is_anonymous
boolean

用户是否为匿名用户。当原始 API 请求中未提供 user 标识符时,值为 true

session_id
string

会话标识符。默认为 external_user_id 的值。

created_at
string<date-time>

创建时间戳。

updated_at
string<date-time>

最后更新时间戳。