> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ariacompute.cn/llms.txt
> Use this file to discover all available pages before exploring further.

# 按 ID 检索咏唱引擎云会话

> 按标识符检索咏唱引擎云会话，返回其绑定智能体、状态、元数据，以及轮次与条目的计数。

按标识符检索一个会话。响应包含绑定的智能体、状态、元数据，以及轮次、条目与子智能体的聚合计数。

## 接口

```http theme={null}
GET /v1/agents/sessions/{session_id}
```

## 认证

`Authorization: Bearer <api_key>` 或 `Authorization: ApiKey <api_key>`。

## 路径参数

<ParamField path="session_id" type="string" required>
  会话标识符。
</ParamField>

## 响应

<ResponseField name="id" type="string">
  会话标识符。
</ResponseField>

<ResponseField name="object" type="string">
  恒为 `agent.session`。
</ResponseField>

<ResponseField name="agent_id" type="string">
  绑定的智能体标识符。
</ResponseField>

<ResponseField name="status" type="string">
  会话状态。
</ResponseField>

<ResponseField name="metadata" type="object">
  自由格式元数据。
</ResponseField>

<ResponseField name="counts" type="object">
  `turns`、`items` 与 `subagents` 的聚合计数。
</ResponseField>

<ResponseField name="created_at" type="integer">
  Unix 秒。
</ResponseField>

## 示例

```bash theme={null}
curl https://agent.example.com/v1/agents/sessions/sess_0198c... \
  -H "Authorization: Bearer $ARIA_AGENT_KEY"
```

```json theme={null}
{
  "id": "sess_0198c...",
  "object": "agent.session",
  "agent_id": "ag_0198a...",
  "status": "active",
  "metadata": {"user_id": "u_42"},
  "counts": {"turns": 3, "items": 12, "subagents": 0},
  "created_at": 1735000000
}
```
