Skip to content

Commit 47fdfb5

Browse files
committed
feat: Stabilize session/list and session_info_update
1 parent 80690f0 commit 47fdfb5

13 files changed

Lines changed: 353 additions & 98 deletions

File tree

Cargo.toml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ unstable = [
1818
"unstable_auth_methods",
1919
"unstable_cancel_request",
2020
"unstable_session_fork",
21-
"unstable_session_info_update",
22-
"unstable_session_list",
2321
"unstable_session_model",
2422
"unstable_session_resume",
2523
"unstable_session_close",
@@ -30,8 +28,6 @@ unstable = [
3028
unstable_auth_methods = []
3129
unstable_cancel_request = []
3230
unstable_session_fork = []
33-
unstable_session_info_update = []
34-
unstable_session_list = []
3531
unstable_session_model = []
3632
unstable_session_resume = []
3733
unstable_session_close = []

docs/docs.json

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@
6565
"protocol/overview",
6666
"protocol/initialization",
6767
"protocol/session-setup",
68+
"protocol/session-list",
6869
"protocol/prompt-turn",
6970
"protocol/content",
7071
"protocol/tool-calls",
@@ -82,7 +83,6 @@
8283
"hidden": true,
8384
"pages": [
8485
"protocol/draft/cancellation",
85-
"protocol/draft/session-list",
8686
"protocol/draft/schema"
8787
]
8888
}
@@ -128,17 +128,15 @@
128128
},
129129
{
130130
"group": "Preview",
131-
"pages": [
132-
"rfds/acp-agent-registry",
133-
"rfds/session-list",
134-
"rfds/session-info-update"
135-
]
131+
"pages": ["rfds/acp-agent-registry"]
136132
},
137133
{
138134
"group": "Completed",
139135
"pages": [
140136
"rfds/introduce-rfd-process",
141-
"rfds/session-config-options"
137+
"rfds/session-config-options",
138+
"rfds/session-list",
139+
"rfds/session-info-update"
142140
]
143141
}
144142
]

docs/protocol/draft/schema.mdx

Lines changed: 3 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -355,25 +355,17 @@ See protocol docs: [Session Modes](https://agentclientprotocol.com/protocol/sess
355355
<a id="session-list"></a>
356356
### <span class="font-mono">session/list</span>
357357

358-
**UNSTABLE**
359-
360-
This capability is not part of the spec yet, and may be removed or changed at any point.
361-
362358
Lists existing sessions known to the agent.
363359

364-
This method is only available if the agent advertises the `listSessions` capability.
360+
This method is only available if the agent advertises the `sessionCapabilities.list` capability.
365361

366362
The agent should return metadata about sessions with optional filtering and pagination support.
367363

368364
#### <span class="font-mono">ListSessionsRequest</span>
369365

370-
**UNSTABLE**
371-
372-
This capability is not part of the spec yet, and may be removed or changed at any point.
373-
374366
Request parameters for listing existing sessions.
375367

376-
Only available if the Agent supports the `listSessions` capability.
368+
Only available if the Agent supports the `sessionCapabilities.list` capability.
377369

378370
**Type:** Object
379371

@@ -396,10 +388,6 @@ See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/exte
396388

397389
#### <span class="font-mono">ListSessionsResponse</span>
398390

399-
**UNSTABLE**
400-
401-
This capability is not part of the spec yet, and may be removed or changed at any point.
402-
403391
Response from listing sessions.
404392

405393
**Type:** Object
@@ -3372,12 +3360,7 @@ Whether the agent supports `session/fork`.
33723360

33733361
</ResponseField>
33743362
<ResponseField name="list" type={<><span><a href="#sessionlistcapabilities">SessionListCapabilities</a></span><span> | null</span></>} >
3375-
**UNSTABLE**
3376-
3377-
This capability is not part of the spec yet, and may be removed or changed at any point.
3378-
3379-
Whether the agent supports `session/list`.
3380-
3363+
Whether the agent supports `session/list`.
33813364
</ResponseField>
33823365
<ResponseField name="resume" type={<><span><a href="#sessionresumecapabilities">SessionResumeCapabilities</a></span><span> | null</span></>} >
33833366
**UNSTABLE**
@@ -3659,10 +3642,6 @@ See protocol docs: [Session ID](https://agentclientprotocol.com/protocol/session
36593642

36603643
## <span class="font-mono">SessionInfo</span>
36613644

3662-
**UNSTABLE**
3663-
3664-
This capability is not part of the spec yet, and may be removed or changed at any point.
3665-
36663645
Information about a session returned by session/list
36673646

36683647
**Type:** Object
@@ -3722,8 +3701,6 @@ Capabilities for the `session/list` method.
37223701

37233702
By supplying `\{\}` it means that the agent supports listing of sessions.
37243703

3725-
Further capabilities can be added in the future for other means of filtering or searching the list.
3726-
37273704
**Type:** Object
37283705

37293706
**Properties:**

docs/protocol/schema.mdx

Lines changed: 161 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,64 @@ See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/exte
196196
The ID of the session to cancel operations for.
197197
</ResponseField>
198198

199+
<a id="session-list"></a>
200+
### <span class="font-mono">session/list</span>
201+
202+
Lists existing sessions known to the agent.
203+
204+
This method is only available if the agent advertises the `sessionCapabilities.list` capability.
205+
206+
The agent should return metadata about sessions with optional filtering and pagination support.
207+
208+
#### <span class="font-mono">ListSessionsRequest</span>
209+
210+
Request parameters for listing existing sessions.
211+
212+
Only available if the Agent supports the `sessionCapabilities.list` capability.
213+
214+
**Type:** Object
215+
216+
**Properties:**
217+
218+
<ResponseField name="_meta" type={"object | null"} >
219+
The _meta property is reserved by ACP to allow clients and agents to attach additional
220+
metadata to their interactions. Implementations MUST NOT make assumptions about values at
221+
these keys.
222+
223+
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
224+
225+
</ResponseField>
226+
<ResponseField name="cursor" type={"string | null"} >
227+
Opaque cursor token from a previous response's nextCursor field for cursor-based pagination
228+
</ResponseField>
229+
<ResponseField name="cwd" type={"string | null"} >
230+
Filter sessions by working directory. Must be an absolute path.
231+
</ResponseField>
232+
233+
#### <span class="font-mono">ListSessionsResponse</span>
234+
235+
Response from listing sessions.
236+
237+
**Type:** Object
238+
239+
**Properties:**
240+
241+
<ResponseField name="_meta" type={"object | null"} >
242+
The _meta property is reserved by ACP to allow clients and agents to attach additional
243+
metadata to their interactions. Implementations MUST NOT make assumptions about values at
244+
these keys.
245+
246+
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
247+
248+
</ResponseField>
249+
<ResponseField name="nextCursor" type={"string | null"} >
250+
Opaque cursor token. If present, pass this in the next request's cursor parameter
251+
to fetch the next page. If absent, there are no more results.
252+
</ResponseField>
253+
<ResponseField name="sessions" type={<a href="#sessioninfo">SessionInfo[]</a>} required>
254+
Array of session information objects
255+
</ResponseField>
256+
199257
<a id="session-load"></a>
200258
### <span class="font-mono">session/load</span>
201259

@@ -2533,6 +2591,9 @@ these keys.
25332591
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
25342592

25352593
</ResponseField>
2594+
<ResponseField name="list" type={<><span><a href="#sessionlistcapabilities">SessionListCapabilities</a></span><span> | null</span></>} >
2595+
Whether the agent supports `session/list`.
2596+
</ResponseField>
25362597

25372598
## <span class="font-mono">SessionConfigGroupId</span>
25382599

@@ -2707,6 +2768,80 @@ See protocol docs: [Session ID](https://agentclientprotocol.com/protocol/session
27072768

27082769
**Type:** `string`
27092770

2771+
## <span class="font-mono">SessionInfo</span>
2772+
2773+
Information about a session returned by session/list
2774+
2775+
**Type:** Object
2776+
2777+
**Properties:**
2778+
2779+
<ResponseField name="_meta" type={"object | null"} >
2780+
The _meta property is reserved by ACP to allow clients and agents to attach additional
2781+
metadata to their interactions. Implementations MUST NOT make assumptions about values at
2782+
these keys.
2783+
2784+
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
2785+
2786+
</ResponseField>
2787+
<ResponseField name="cwd" type={"string"} required>
2788+
The working directory for this session. Must be an absolute path.
2789+
</ResponseField>
2790+
<ResponseField name="sessionId" type={<a href="#sessionid">SessionId</a>} required>
2791+
Unique identifier for the session
2792+
</ResponseField>
2793+
<ResponseField name="title" type={"string | null"} >
2794+
Human-readable title for the session
2795+
</ResponseField>
2796+
<ResponseField name="updatedAt" type={"string | null"} >
2797+
ISO 8601 timestamp of last activity
2798+
</ResponseField>
2799+
2800+
## <span class="font-mono">SessionInfoUpdate</span>
2801+
2802+
Update to session metadata. All fields are optional to support partial updates.
2803+
2804+
Agents send this notification to update session information like title or custom metadata.
2805+
This allows clients to display dynamic session names and track session state changes.
2806+
2807+
**Type:** Object
2808+
2809+
**Properties:**
2810+
2811+
<ResponseField name="_meta" type={"object | null"} >
2812+
The _meta property is reserved by ACP to allow clients and agents to attach additional
2813+
metadata to their interactions. Implementations MUST NOT make assumptions about values at
2814+
these keys.
2815+
2816+
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
2817+
2818+
</ResponseField>
2819+
<ResponseField name="title" type={"string | null"} >
2820+
Human-readable title for the session. Set to null to clear.
2821+
</ResponseField>
2822+
<ResponseField name="updatedAt" type={"string | null"} >
2823+
ISO 8601 timestamp of last activity. Set to null to clear.
2824+
</ResponseField>
2825+
2826+
## <span class="font-mono">SessionListCapabilities</span>
2827+
2828+
Capabilities for the `session/list` method.
2829+
2830+
By supplying `\{\}` it means that the agent supports listing of sessions.
2831+
2832+
**Type:** Object
2833+
2834+
**Properties:**
2835+
2836+
<ResponseField name="_meta" type={"object | null"} >
2837+
The _meta property is reserved by ACP to allow clients and agents to attach additional
2838+
metadata to their interactions. Implementations MUST NOT make assumptions about values at
2839+
these keys.
2840+
2841+
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
2842+
2843+
</ResponseField>
2844+
27102845
## <span class="font-mono">SessionMode</span>
27112846

27122847
A mode the agent can operate in.
@@ -3029,6 +3164,32 @@ See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/exte
30293164
</Expandable>
30303165
</ResponseField>
30313166

3167+
<ResponseField name="session_info_update" type="object">
3168+
Session metadata has been updated (title, timestamps, custom metadata)
3169+
3170+
<Expandable title="Properties">
3171+
3172+
<ResponseField name="_meta" type={"object | null"} >
3173+
The _meta property is reserved by ACP to allow clients and agents to attach additional
3174+
metadata to their interactions. Implementations MUST NOT make assumptions about values at
3175+
these keys.
3176+
3177+
See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
3178+
3179+
</ResponseField>
3180+
<ResponseField name="sessionUpdate" type={"string"} required>
3181+
The discriminator value. Must be `"session_info_update"`.
3182+
</ResponseField>
3183+
<ResponseField name="title" type={"string | null"} >
3184+
Human-readable title for the session. Set to null to clear.
3185+
</ResponseField>
3186+
<ResponseField name="updatedAt" type={"string | null"} >
3187+
ISO 8601 timestamp of last activity. Set to null to clear.
3188+
</ResponseField>
3189+
3190+
</Expandable>
3191+
</ResponseField>
3192+
30323193
## <span class="font-mono">StopReason</span>
30333194

30343195
Reasons why an agent stops processing a prompt turn.
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
---
22
title: "Session List"
3-
description: "Discovering and enumerating existing sessions"
3+
description: "Discovering existing sessions"
44
---
55

6-
The `session/list` method allows Clients to discover and enumerate sessions known to an Agent. Clients can use this to display session history and switch between sessions.
6+
The `session/list` method allows Clients to discover sessions known to an Agent. Clients can use this to display session history and switch between sessions.
77

88
Agents can also push session metadata updates to Clients in real-time via the `session_info_update` notification, keeping session titles and metadata in sync without polling.
99

10-
Before listing sessions, Clients **MUST** first complete the [initialization](../initialization) phase to verify the Agent supports this capability.
10+
Before listing sessions, Clients **MUST** first complete the [initialization](./initialization) phase to verify the Agent supports this capability.
1111

1212
<br />
1313

@@ -133,7 +133,7 @@ The Agent **MUST** respond with a list of sessions and optional pagination metad
133133
ISO 8601 timestamp of the last activity in the session.
134134
</ResponseField>
135135
<ResponseField name="_meta" type="object">
136-
Agent-specific metadata. See [Extensibility](../extensibility).
136+
Agent-specific metadata. See [Extensibility](./extensibility).
137137
</ResponseField>
138138
</Expandable>
139139
</ResponseField>
@@ -156,7 +156,7 @@ When no sessions match the criteria, the Agent **MUST** return an empty `session
156156

157157
## Updating Session Metadata
158158

159-
Agents can update session metadata in real-time by sending a `session_info_update` notification via `session/update`. This follows the same pattern as other session notifications like [`available_commands_update`](../slash-commands) and [`current_mode_update`](../session-modes).
159+
Agents can update session metadata in real-time by sending a `session_info_update` notification via `session/update`. This follows the same pattern as other session notifications like [`available_commands_update`](./slash-commands) and [`current_mode_update`](./session-modes).
160160

161161
```json
162162
{
@@ -187,15 +187,15 @@ All fields are optional. Only include fields that have changed — omitted field
187187
</ResponseField>
188188

189189
<ResponseField name="_meta" type="object">
190-
Agent-specific metadata. See [Extensibility](../extensibility).
190+
Agent-specific metadata. See [Extensibility](./extensibility).
191191
</ResponseField>
192192

193-
The `sessionId` and `cwd` fields are **not** included in the update — `sessionId` is already in the notification's `params`, and `cwd` is immutable (set during [`session/new`](../session-setup#creating-a-session)). Agents typically send this notification after the first meaningful exchange to auto-generate a title.
193+
The `sessionId` and `cwd` fields are **not** included in the update — `sessionId` is already in the notification's `params`, and `cwd` is immutable (set during [`session/new`](./session-setup#creating-a-session)). Agents typically send this notification after the first meaningful exchange to auto-generate a title.
194194

195195
## Interaction with Other Session Methods
196196

197197
`session/list` is a discovery mechanism only — it does **not** restore or modify sessions:
198198

199199
1. Client calls `session/list` to discover available sessions
200200
2. User selects a session from the list
201-
3. Client calls [`session/load`](../session-setup#loading-sessions) with the chosen `sessionId` to resume the conversation
201+
3. Client calls [`session/load`](./session-setup#loading-sessions) with the chosen `sessionId` to resume the conversation

docs/rfds/session-list.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ Agents that implement this feature gain:
208208
### Compatibility Considerations
209209

210210
- **Backward compatible**: Existing agents continue working without implementing this
211-
- **Capability-based**: Clients check for `listSessions` capability before using
211+
- **Capability-based**: Clients check for `sessionCapabilities.list` capability before using
212212
- **No breaking changes**: No modifications to existing endpoints
213213

214214
### Security Considerations

0 commit comments

Comments
 (0)