Skip to content

Commit a1501a6

Browse files
nathansoboclaude
andcommitted
Move supports_commands from PromptCapabilities to AgentCapabilities
- Moved supports_commands field from PromptCapabilities to AgentCapabilities - Commands are an agent-level capability, not specific to prompt processing - Regenerated all derived artifacts (JSON schema, TypeScript types, docs) 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 93b1c91 commit a1501a6

4 files changed

Lines changed: 26 additions & 26 deletions

File tree

docs/protocol/schema.mdx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ See protocol docs: [Initialization](https://agentclientprotocol.com/protocol/ini
9292
<ResponseField name="agentCapabilities" type={<a href="#agentcapabilities">AgentCapabilities</a>} >
9393
Capabilities supported by the agent.
9494

95-
- Default: `{"loadSession":false,"promptCapabilities":{"audio":false,"embeddedContext":false,"image":false,"supportsCommands":false}}`
95+
- Default: `{"loadSession":false,"promptCapabilities":{"audio":false,"embeddedContext":false,"image":false},"supportsCommands":false}`
9696

9797
</ResponseField>
9898
<ResponseField name="authMethods" type={<><span><a href="#authmethod">AuthMethod</a></span><span>[]</span></>} >
@@ -616,7 +616,13 @@ See protocol docs: [Agent Capabilities](https://agentclientprotocol.com/protocol
616616
<ResponseField name="promptCapabilities" type={<a href="#promptcapabilities">PromptCapabilities</a>} >
617617
Prompt capabilities supported by the agent.
618618

619-
- Default: `{"audio":false,"embeddedContext":false,"image":false,"supportsCommands":false}`
619+
- Default: `{"audio":false,"embeddedContext":false,"image":false}`
620+
621+
</ResponseField>
622+
<ResponseField name="supportsCommands" type={"boolean"} >
623+
Agent supports commands via `list_commands` and `run_command`.
624+
625+
- Default: `false`
620626

621627
</ResponseField>
622628

@@ -1246,12 +1252,6 @@ in prompt requests for pieces of context that are referenced in the message.
12461252

12471253
- Default: `false`
12481254

1249-
</ResponseField>
1250-
<ResponseField name="supportsCommands" type={"boolean"} >
1251-
Agent supports commands via `list_commands` and `run_command`.
1252-
1253-
- Default: `false`
1254-
12551255
</ResponseField>
12561256

12571257
## <span class="font-mono">ProtocolVersion</span>

rust/agent.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,10 @@ pub struct AgentCapabilities {
354354
/// Prompt capabilities supported by the agent.
355355
#[serde(default)]
356356
pub prompt_capabilities: PromptCapabilities,
357+
358+
/// Agent supports commands via `list_commands` and `run_command`.
359+
#[serde(default)]
360+
pub supports_commands: bool,
357361
}
358362

359363
/// Prompt capabilities supported by the agent in `session/prompt` requests.
@@ -383,9 +387,6 @@ pub struct PromptCapabilities {
383387
/// in prompt requests for pieces of context that are referenced in the message.
384388
#[serde(default)]
385389
pub embedded_context: bool,
386-
/// Agent supports commands via `list_commands` and `run_command`.
387-
#[serde(default)]
388-
pub supports_commands: bool,
389390
}
390391

391392
// Slash commands

schema/schema.json

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,14 @@
1313
"default": {
1414
"audio": false,
1515
"embeddedContext": false,
16-
"image": false,
17-
"supportsCommands": false
16+
"image": false
1817
},
1918
"description": "Prompt capabilities supported by the agent."
19+
},
20+
"supportsCommands": {
21+
"default": false,
22+
"description": "Agent supports commands via `list_commands` and `run_command`.",
23+
"type": "boolean"
2024
}
2125
},
2226
"type": "object"
@@ -635,9 +639,9 @@
635639
"promptCapabilities": {
636640
"audio": false,
637641
"embeddedContext": false,
638-
"image": false,
639-
"supportsCommands": false
640-
}
642+
"image": false
643+
},
644+
"supportsCommands": false
641645
},
642646
"description": "Capabilities supported by the agent."
643647
},
@@ -912,11 +916,6 @@
912916
"default": false,
913917
"description": "Agent supports [`ContentBlock::Image`].",
914918
"type": "boolean"
915-
},
916-
"supportsCommands": {
917-
"default": false,
918-
"description": "Agent supports commands via `list_commands` and `run_command`.",
919-
"type": "boolean"
920919
}
921920
},
922921
"type": "object"

typescript/schema.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -822,6 +822,10 @@ export interface AgentCapabilities {
822822
*/
823823
loadSession?: boolean;
824824
promptCapabilities?: PromptCapabilities;
825+
/**
826+
* Agent supports commands via `list_commands` and `run_command`.
827+
*/
828+
supportsCommands?: boolean;
825829
}
826830
/**
827831
* Prompt capabilities supported by the agent.
@@ -842,10 +846,6 @@ export interface PromptCapabilities {
842846
* Agent supports [`ContentBlock::Image`].
843847
*/
844848
image?: boolean;
845-
/**
846-
* Agent supports commands via `list_commands` and `run_command`.
847-
*/
848-
supportsCommands?: boolean;
849849
}
850850
/**
851851
* Describes an available authentication method.
@@ -1400,7 +1400,6 @@ export const promptCapabilitiesSchema = z.object({
14001400
audio: z.boolean().optional(),
14011401
embeddedContext: z.boolean().optional(),
14021402
image: z.boolean().optional(),
1403-
supportsCommands: z.boolean().optional(),
14041403
});
14051404

14061405
/** @internal */
@@ -1544,6 +1543,7 @@ export const clientCapabilitiesSchema = z.object({
15441543
export const agentCapabilitiesSchema = z.object({
15451544
loadSession: z.boolean().optional(),
15461545
promptCapabilities: promptCapabilitiesSchema.optional(),
1546+
supportsCommands: z.boolean().optional(),
15471547
});
15481548

15491549
/** @internal */

0 commit comments

Comments
 (0)