From 5a40903f8d9cdd71c100a2eecd47c85c1dfba979 Mon Sep 17 00:00:00 2001 From: Ben Brandt Date: Thu, 25 Jun 2026 23:02:06 +0200 Subject: [PATCH] feat(unstable-v2): Group v2 auth methods under auth/* --- AGENTS.md | 16 --- agent-client-protocol-schema/src/v2/agent.rs | 87 +++++++++------- .../src/v2/conversion.rs | 44 +++++---- docs/protocol/v2/authentication.mdx | 28 +++--- docs/protocol/v2/draft/authentication.mdx | 28 +++--- docs/protocol/v2/draft/initialization.mdx | 2 +- docs/protocol/v2/draft/overview.mdx | 10 +- docs/protocol/v2/draft/schema.mdx | 98 ++++++++++--------- docs/protocol/v2/draft/transports.mdx | 2 +- docs/protocol/v2/initialization.mdx | 3 +- docs/protocol/v2/overview.mdx | 10 +- docs/protocol/v2/schema.mdx | 98 ++++++++++--------- docs/protocol/v2/transports.mdx | 2 +- docs/rfds/v2/overview.mdx | 4 + schema-generator/src/main.rs | 2 + schema/v2/meta.json | 4 +- schema/v2/meta.unstable.json | 4 +- schema/v2/schema.json | 56 +++++------ schema/v2/schema.unstable.json | 56 +++++------ 19 files changed, 284 insertions(+), 270 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index a57783e2..8f9a3f8f 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -60,22 +60,6 @@ This repository uses **Conventional Commits** for automated releases via release - **ci:** CI/CD configuration changes - **build:** Build system or external dependency changes -### Breaking Changes - -Add `!` after the type to indicate breaking changes (triggers major version bump): - -``` -feat!: change API to use async traits -``` - -Or include `BREAKING CHANGE:` in the footer: - -``` -feat: redesign conductor protocol - -BREAKING CHANGE: conductor now requires explicit capability registration -``` - ### Examples ``` diff --git a/agent-client-protocol-schema/src/v2/agent.rs b/agent-client-protocol-schema/src/v2/agent.rs index 8777f24d..2add21c4 100644 --- a/agent-client-protocol-schema/src/v2/agent.rs +++ b/agent-client-protocol-schema/src/v2/agent.rs @@ -239,15 +239,15 @@ impl Implementation { // Authentication -/// Request parameters for the authenticate method. +/// Request parameters for the `auth/login` method. /// /// Specifies which authentication method to use. #[skip_serializing_none] #[derive(Debug, Clone, Serialize, Deserialize, JsonSchema, PartialEq, Eq)] -#[schemars(extend("x-side" = "agent", "x-method" = AUTHENTICATE_METHOD_NAME))] +#[schemars(extend("x-side" = "agent", "x-method" = AUTH_LOGIN_METHOD_NAME))] #[serde(rename_all = "camelCase")] #[non_exhaustive] -pub struct AuthenticateRequest { +pub struct LoginAuthRequest { /// The ID of the authentication method to use. /// Must be one of the methods advertised in the initialize response. pub method_id: AuthMethodId, @@ -260,8 +260,8 @@ pub struct AuthenticateRequest { pub meta: Option, } -impl AuthenticateRequest { - /// Builds [`AuthenticateRequest`] with the required request fields set; optional fields start unset or empty. +impl LoginAuthRequest { + /// Builds [`LoginAuthRequest`] with the required request fields set; optional fields start unset or empty. #[must_use] pub fn new(method_id: impl Into) -> Self { Self { @@ -282,13 +282,13 @@ impl AuthenticateRequest { } } -/// Response to the `authenticate` method. +/// Response to the `auth/login` method. #[skip_serializing_none] #[derive(Default, Debug, Clone, Serialize, Deserialize, JsonSchema, PartialEq, Eq)] -#[schemars(extend("x-side" = "agent", "x-method" = AUTHENTICATE_METHOD_NAME))] +#[schemars(extend("x-side" = "agent", "x-method" = AUTH_LOGIN_METHOD_NAME))] #[serde(rename_all = "camelCase")] #[non_exhaustive] -pub struct AuthenticateResponse { +pub struct LoginAuthResponse { /// The _meta property is reserved by ACP to allow clients and agents to attach additional /// metadata to their interactions. Implementations MUST NOT make assumptions about values at /// these keys. @@ -298,8 +298,8 @@ pub struct AuthenticateResponse { pub meta: Option, } -impl AuthenticateResponse { - /// Builds [`AuthenticateResponse`] with the required response fields set; optional fields start unset or empty. +impl LoginAuthResponse { + /// Builds [`LoginAuthResponse`] with the required response fields set; optional fields start unset or empty. #[must_use] pub fn new() -> Self { Self::default() @@ -319,15 +319,15 @@ impl AuthenticateResponse { // Logout -/// Request parameters for the logout method. +/// Request parameters for the `auth/logout` method. /// /// Terminates the current authenticated session. #[skip_serializing_none] #[derive(Default, Debug, Clone, Serialize, Deserialize, JsonSchema, PartialEq, Eq)] -#[schemars(extend("x-side" = "agent", "x-method" = LOGOUT_METHOD_NAME))] +#[schemars(extend("x-side" = "agent", "x-method" = AUTH_LOGOUT_METHOD_NAME))] #[serde(rename_all = "camelCase")] #[non_exhaustive] -pub struct LogoutRequest { +pub struct LogoutAuthRequest { /// The _meta property is reserved by ACP to allow clients and agents to attach additional /// metadata to their interactions. Implementations MUST NOT make assumptions about values at /// these keys. @@ -337,8 +337,8 @@ pub struct LogoutRequest { pub meta: Option, } -impl LogoutRequest { - /// Builds [`LogoutRequest`] with the required request fields set; optional fields start unset or empty. +impl LogoutAuthRequest { + /// Builds [`LogoutAuthRequest`] with the required request fields set; optional fields start unset or empty. #[must_use] pub fn new() -> Self { Self::default() @@ -356,13 +356,13 @@ impl LogoutRequest { } } -/// Response to the `logout` method. +/// Response to the `auth/logout` method. #[skip_serializing_none] #[derive(Default, Debug, Clone, Serialize, Deserialize, JsonSchema, PartialEq, Eq)] -#[schemars(extend("x-side" = "agent", "x-method" = LOGOUT_METHOD_NAME))] +#[schemars(extend("x-side" = "agent", "x-method" = AUTH_LOGOUT_METHOD_NAME))] #[serde(rename_all = "camelCase")] #[non_exhaustive] -pub struct LogoutResponse { +pub struct LogoutAuthResponse { /// The _meta property is reserved by ACP to allow clients and agents to attach additional /// metadata to their interactions. Implementations MUST NOT make assumptions about values at /// these keys. @@ -372,8 +372,8 @@ pub struct LogoutResponse { pub meta: Option, } -impl LogoutResponse { - /// Builds [`LogoutResponse`] with the required response fields set; optional fields start unset or empty. +impl LogoutAuthResponse { + /// Builds [`LogoutAuthResponse`] with the required response fields set; optional fields start unset or empty. #[must_use] pub fn new() -> Self { Self::default() @@ -4715,7 +4715,7 @@ pub struct AgentMethodNames { /// Method for initializing the connection. pub initialize: &'static str, /// Method for authenticating with the agent. - pub authenticate: &'static str, + pub auth_login: &'static str, /// Method for listing configurable providers. #[cfg(feature = "unstable_llm_providers")] pub providers_list: &'static str, @@ -4750,7 +4750,7 @@ pub struct AgentMethodNames { /// Method for closing an active session. pub session_close: &'static str, /// Method for logging out of an authenticated session. - pub logout: &'static str, + pub auth_logout: &'static str, /// Method for starting an NES session. #[cfg(feature = "unstable_nes")] pub nes_start: &'static str, @@ -4786,7 +4786,7 @@ pub struct AgentMethodNames { /// Constant containing all agent method names. pub const AGENT_METHOD_NAMES: AgentMethodNames = AgentMethodNames { initialize: INITIALIZE_METHOD_NAME, - authenticate: AUTHENTICATE_METHOD_NAME, + auth_login: AUTH_LOGIN_METHOD_NAME, #[cfg(feature = "unstable_llm_providers")] providers_list: PROVIDERS_LIST_METHOD_NAME, #[cfg(feature = "unstable_llm_providers")] @@ -4806,7 +4806,7 @@ pub const AGENT_METHOD_NAMES: AgentMethodNames = AgentMethodNames { session_fork: SESSION_FORK_METHOD_NAME, session_resume: SESSION_RESUME_METHOD_NAME, session_close: SESSION_CLOSE_METHOD_NAME, - logout: LOGOUT_METHOD_NAME, + auth_logout: AUTH_LOGOUT_METHOD_NAME, #[cfg(feature = "unstable_nes")] nes_start: NES_START_METHOD_NAME, #[cfg(feature = "unstable_nes")] @@ -4831,8 +4831,8 @@ pub const AGENT_METHOD_NAMES: AgentMethodNames = AgentMethodNames { /// Method name for the initialize request. pub(crate) const INITIALIZE_METHOD_NAME: &str = "initialize"; -/// Method name for the authenticate request. -pub(crate) const AUTHENTICATE_METHOD_NAME: &str = "authenticate"; +/// Method name for the `auth/login` request. +pub(crate) const AUTH_LOGIN_METHOD_NAME: &str = "auth/login"; /// Method name for listing configurable providers. #[cfg(feature = "unstable_llm_providers")] pub(crate) const PROVIDERS_LIST_METHOD_NAME: &str = "providers/list"; @@ -4863,8 +4863,8 @@ pub(crate) const SESSION_FORK_METHOD_NAME: &str = "session/fork"; pub(crate) const SESSION_RESUME_METHOD_NAME: &str = "session/resume"; /// Method name for closing an active session. pub(crate) const SESSION_CLOSE_METHOD_NAME: &str = "session/close"; -/// Method name for logging out of an authenticated session. -pub(crate) const LOGOUT_METHOD_NAME: &str = "logout"; +/// Method name for the `auth/logout` request. +pub(crate) const AUTH_LOGOUT_METHOD_NAME: &str = "auth/logout"; /// All possible requests that a client can send to an agent. /// @@ -4897,7 +4897,7 @@ pub enum ClientRequest { /// `new_session` without receiving an `auth_required` error. /// /// See protocol docs: [Initialization](https://agentclientprotocol.com/protocol/initialization) - AuthenticateRequest(AuthenticateRequest), + LoginAuthRequest(LoginAuthRequest), /// **UNSTABLE** /// /// This capability is not part of the spec yet, and may be removed or changed at any point. @@ -4923,7 +4923,7 @@ pub enum ClientRequest { /// /// After a successful logout, all new sessions will require authentication. /// There is no guarantee about the behavior of already running sessions. - LogoutRequest(LogoutRequest), + LogoutAuthRequest(LogoutAuthRequest), /// Creates a new conversation session with the agent. /// /// Sessions represent independent conversation contexts with their own history and state. @@ -5045,14 +5045,14 @@ impl ClientRequest { pub fn method(&self) -> &str { match self { Self::InitializeRequest(_) => AGENT_METHOD_NAMES.initialize, - Self::AuthenticateRequest(_) => AGENT_METHOD_NAMES.authenticate, + Self::LoginAuthRequest(_) => AGENT_METHOD_NAMES.auth_login, #[cfg(feature = "unstable_llm_providers")] Self::ListProvidersRequest(_) => AGENT_METHOD_NAMES.providers_list, #[cfg(feature = "unstable_llm_providers")] Self::SetProviderRequest(_) => AGENT_METHOD_NAMES.providers_set, #[cfg(feature = "unstable_llm_providers")] Self::DisableProviderRequest(_) => AGENT_METHOD_NAMES.providers_disable, - Self::LogoutRequest(_) => AGENT_METHOD_NAMES.logout, + Self::LogoutAuthRequest(_) => AGENT_METHOD_NAMES.auth_logout, Self::NewSessionRequest(_) => AGENT_METHOD_NAMES.session_new, Self::LoadSessionRequest(_) => AGENT_METHOD_NAMES.session_load, Self::ListSessionsRequest(_) => AGENT_METHOD_NAMES.session_list, @@ -5089,8 +5089,8 @@ impl ClientRequest { pub enum AgentResponse { /// Successful result returned for a `initialize` request. InitializeResponse(Box), - /// Successful result returned for a `authenticate` request. - AuthenticateResponse(#[serde(default)] AuthenticateResponse), + /// Successful result returned for an `auth/login` request. + LoginAuthResponse(#[serde(default)] LoginAuthResponse), /// Successful result returned for a `providers/list` request. #[cfg(feature = "unstable_llm_providers")] ListProvidersResponse(ListProvidersResponse), @@ -5100,8 +5100,8 @@ pub enum AgentResponse { /// Successful result returned for a `providers/disable` request. #[cfg(feature = "unstable_llm_providers")] DisableProviderResponse(#[serde(default)] DisableProviderResponse), - /// Successful result returned for a `logout` request. - LogoutResponse(#[serde(default)] LogoutResponse), + /// Successful result returned for an `auth/logout` request. + LogoutAuthResponse(#[serde(default)] LogoutAuthResponse), /// Successful result returned for a `session/new` request. NewSessionResponse(NewSessionResponse), /// Successful result returned for a `session/load` request. @@ -5457,6 +5457,21 @@ mod test_serialization { ); } + #[test] + fn test_auth_method_names() { + assert_eq!(AGENT_METHOD_NAMES.auth_login, "auth/login"); + assert_eq!(AGENT_METHOD_NAMES.auth_logout, "auth/logout"); + + assert_eq!( + ClientRequest::LoginAuthRequest(LoginAuthRequest::new("agent-login")).method(), + "auth/login" + ); + assert_eq!( + ClientRequest::LogoutAuthRequest(LogoutAuthRequest::new()).method(), + "auth/logout" + ); + } + #[test] fn test_session_config_option_category_known_variants() { // Test serialization of known variants diff --git a/agent-client-protocol-schema/src/v2/conversion.rs b/agent-client-protocol-schema/src/v2/conversion.rs index a04c492b..c2eaffeb 100644 --- a/agent-client-protocol-schema/src/v2/conversion.rs +++ b/agent-client-protocol-schema/src/v2/conversion.rs @@ -2824,7 +2824,7 @@ impl IntoV2 for crate::v1::Implementation { } } -impl IntoV1 for super::AuthenticateRequest { +impl IntoV1 for super::LoginAuthRequest { type Output = crate::v1::AuthenticateRequest; fn into_v1(self) -> Result { @@ -2837,18 +2837,18 @@ impl IntoV1 for super::AuthenticateRequest { } impl IntoV2 for crate::v1::AuthenticateRequest { - type Output = super::AuthenticateRequest; + type Output = super::LoginAuthRequest; fn into_v2(self) -> Result { let Self { method_id, meta } = self; - Ok(super::AuthenticateRequest { + Ok(super::LoginAuthRequest { method_id: method_id.into_v2()?, meta: meta.into_v2()?, }) } } -impl IntoV1 for super::AuthenticateResponse { +impl IntoV1 for super::LoginAuthResponse { type Output = crate::v1::AuthenticateResponse; fn into_v1(self) -> Result { @@ -2860,17 +2860,17 @@ impl IntoV1 for super::AuthenticateResponse { } impl IntoV2 for crate::v1::AuthenticateResponse { - type Output = super::AuthenticateResponse; + type Output = super::LoginAuthResponse; fn into_v2(self) -> Result { let Self { meta } = self; - Ok(super::AuthenticateResponse { + Ok(super::LoginAuthResponse { meta: meta.into_v2()?, }) } } -impl IntoV1 for super::LogoutRequest { +impl IntoV1 for super::LogoutAuthRequest { type Output = crate::v1::LogoutRequest; fn into_v1(self) -> Result { @@ -2882,17 +2882,17 @@ impl IntoV1 for super::LogoutRequest { } impl IntoV2 for crate::v1::LogoutRequest { - type Output = super::LogoutRequest; + type Output = super::LogoutAuthRequest; fn into_v2(self) -> Result { let Self { meta } = self; - Ok(super::LogoutRequest { + Ok(super::LogoutAuthRequest { meta: meta.into_v2()?, }) } } -impl IntoV1 for super::LogoutResponse { +impl IntoV1 for super::LogoutAuthResponse { type Output = crate::v1::LogoutResponse; fn into_v1(self) -> Result { @@ -2904,11 +2904,11 @@ impl IntoV1 for super::LogoutResponse { } impl IntoV2 for crate::v1::LogoutResponse { - type Output = super::LogoutResponse; + type Output = super::LogoutAuthResponse; fn into_v2(self) -> Result { let Self { meta } = self; - Ok(super::LogoutResponse { + Ok(super::LogoutAuthResponse { meta: meta.into_v2()?, }) } @@ -5155,7 +5155,7 @@ impl IntoV1 for super::ClientRequest { Self::InitializeRequest(value) => { crate::v1::ClientRequest::InitializeRequest(value.into_v1()?) } - Self::AuthenticateRequest(value) => { + Self::LoginAuthRequest(value) => { crate::v1::ClientRequest::AuthenticateRequest(value.into_v1()?) } #[cfg(feature = "unstable_llm_providers")] @@ -5170,7 +5170,9 @@ impl IntoV1 for super::ClientRequest { Self::DisableProviderRequest(value) => { crate::v1::ClientRequest::DisableProviderRequest(value.into_v1()?) } - Self::LogoutRequest(value) => crate::v1::ClientRequest::LogoutRequest(value.into_v1()?), + Self::LogoutAuthRequest(value) => { + crate::v1::ClientRequest::LogoutRequest(value.into_v1()?) + } Self::NewSessionRequest(value) => { crate::v1::ClientRequest::NewSessionRequest(value.into_v1()?) } @@ -5229,7 +5231,7 @@ impl IntoV2 for crate::v1::ClientRequest { super::ClientRequest::InitializeRequest(Box::new(value.into_v2()?)) } Self::AuthenticateRequest(value) => { - super::ClientRequest::AuthenticateRequest(value.into_v2()?) + super::ClientRequest::LoginAuthRequest(value.into_v2()?) } #[cfg(feature = "unstable_llm_providers")] Self::ListProvidersRequest(value) => { @@ -5243,7 +5245,7 @@ impl IntoV2 for crate::v1::ClientRequest { Self::DisableProviderRequest(value) => { super::ClientRequest::DisableProviderRequest(value.into_v2()?) } - Self::LogoutRequest(value) => super::ClientRequest::LogoutRequest(value.into_v2()?), + Self::LogoutRequest(value) => super::ClientRequest::LogoutAuthRequest(value.into_v2()?), Self::NewSessionRequest(value) => { super::ClientRequest::NewSessionRequest(value.into_v2()?) } @@ -5302,7 +5304,7 @@ impl IntoV1 for super::AgentResponse { Self::InitializeResponse(value) => { crate::v1::AgentResponse::InitializeResponse(value.into_v1()?) } - Self::AuthenticateResponse(value) => { + Self::LoginAuthResponse(value) => { crate::v1::AgentResponse::AuthenticateResponse(value.into_v1()?) } #[cfg(feature = "unstable_llm_providers")] @@ -5317,7 +5319,7 @@ impl IntoV1 for super::AgentResponse { Self::DisableProviderResponse(value) => { crate::v1::AgentResponse::DisableProviderResponse(value.into_v1()?) } - Self::LogoutResponse(value) => { + Self::LogoutAuthResponse(value) => { crate::v1::AgentResponse::LogoutResponse(value.into_v1()?) } Self::NewSessionResponse(value) => { @@ -5380,7 +5382,7 @@ impl IntoV2 for crate::v1::AgentResponse { super::AgentResponse::InitializeResponse(Box::new(value.into_v2()?)) } Self::AuthenticateResponse(value) => { - super::AgentResponse::AuthenticateResponse(value.into_v2()?) + super::AgentResponse::LoginAuthResponse(value.into_v2()?) } #[cfg(feature = "unstable_llm_providers")] Self::ListProvidersResponse(value) => { @@ -5394,7 +5396,9 @@ impl IntoV2 for crate::v1::AgentResponse { Self::DisableProviderResponse(value) => { super::AgentResponse::DisableProviderResponse(value.into_v2()?) } - Self::LogoutResponse(value) => super::AgentResponse::LogoutResponse(value.into_v2()?), + Self::LogoutResponse(value) => { + super::AgentResponse::LogoutAuthResponse(value.into_v2()?) + } Self::NewSessionResponse(value) => { super::AgentResponse::NewSessionResponse(value.into_v2()?) } diff --git a/docs/protocol/v2/authentication.mdx b/docs/protocol/v2/authentication.mdx index f2803f19..71306e86 100644 --- a/docs/protocol/v2/authentication.mdx +++ b/docs/protocol/v2/authentication.mdx @@ -3,7 +3,7 @@ title: "Authentication" description: "Authenticating with agents and logging out" --- -ACP authentication is negotiated during [initialization](/protocol/v2/initialization). Agents advertise available authentication methods in `authMethods`, Clients choose one by calling `authenticate`, and Agents that support ending an authenticated state advertise the `logout` capability. +ACP authentication is negotiated during [initialization](/protocol/v2/initialization). Agents advertise available authentication methods in `authMethods`, Clients choose one by calling `auth/login`, and Agents that support ending an authenticated state advertise the `logout` auth capability.
@@ -16,15 +16,15 @@ sequenceDiagram Agent-->>Client: initialize response (authMethods, auth.logout) alt Agent requires authentication - Client->>Agent: authenticate (methodId) - Agent-->>Client: authenticate response + Client->>Agent: auth/login (methodId) + Agent-->>Client: auth/login response end Note over Client,Agent: Authenticated requests may proceed alt User logs out - Client->>Agent: logout - Agent-->>Client: logout response + Client->>Agent: auth/logout + Agent-->>Client: auth/logout response end Note over Client,Agent: New sessions require authentication again @@ -34,9 +34,9 @@ sequenceDiagram ## Advertising Authentication -Agents advertise authentication options in the `authMethods` field of the `initialize` response. Each method has an `id` that the Client passes back to the Agent in a later `authenticate` request. +Agents advertise authentication options in the `authMethods` field of the `initialize` response. Each method has an `id` that the Client passes back to the Agent in a later `auth/login` request. -Agents that support `logout` also advertise `capabilities.auth.logout`: +Agents that support `auth/logout` also advertise `capabilities.auth.logout`: ```json highlight={7-11,12-19} { @@ -61,7 +61,7 @@ Agents that support `logout` also advertise `capabilities.auth.logout`: } ``` -If `capabilities.auth.logout` is omitted or `null`, the Agent does not support `logout` and Clients **MUST NOT** call it. Supplying `{}` means the Agent supports the method. +If `capabilities.auth.logout` is omitted or `null`, the Agent does not support `auth/logout` and Clients **MUST NOT** call it. Supplying `{}` means the Agent supports the method. ### Authentication Method Types @@ -82,13 +82,13 @@ See the [schema](/protocol/v2/schema#authmethod) for the full stable `AuthMethod ## Authenticating -When an Agent requires authentication before allowing session creation, the Client calls `authenticate` with one of the advertised authentication method IDs: +When an Agent requires authentication before allowing session creation, the Client calls `auth/login` with one of the advertised authentication method IDs: ```json { "jsonrpc": "2.0", "id": 1, - "method": "authenticate", + "method": "auth/login", "params": { "methodId": "agent-login" } @@ -114,13 +114,13 @@ After successful authentication, the Client can create new sessions without rece ## Logging Out -The `logout` method allows Clients to end the current authenticated state. Clients should only call it after verifying the Agent advertised `capabilities.auth.logout` during initialization. +The `auth/logout` method allows Clients to end the current authenticated state. Clients should only call it after verifying the Agent advertised `capabilities.auth.logout` during initialization. ```json { "jsonrpc": "2.0", "id": 2, - "method": "logout", + "method": "auth/logout", "params": {} } ``` @@ -135,10 +135,10 @@ On success, the Agent returns an empty result: } ``` -After a successful `logout`, new sessions that require authentication will require the Client to call `authenticate` again. +After a successful `auth/logout`, new sessions that require authentication will require the Client to call `auth/login` again. ## Active Sessions -The protocol does not guarantee what happens to already-running sessions after `logout`. Agents may terminate them, keep them running, or return `auth_required` errors for future session activity. +The protocol does not guarantee what happens to already-running sessions after `auth/logout`. Agents may terminate them, keep them running, or return `auth_required` errors for future session activity. Clients **SHOULD** be prepared for active session operations to fail with authentication-related errors after logout and should prompt the user to authenticate again when appropriate. diff --git a/docs/protocol/v2/draft/authentication.mdx b/docs/protocol/v2/draft/authentication.mdx index 416b248a..e336bf09 100644 --- a/docs/protocol/v2/draft/authentication.mdx +++ b/docs/protocol/v2/draft/authentication.mdx @@ -3,7 +3,7 @@ title: "Authentication" description: "Authenticating with agents and logging out" --- -ACP authentication is negotiated during [initialization](/protocol/v2/draft/initialization). Agents advertise available authentication methods in `authMethods`, Clients choose one by calling `authenticate`, and Agents that support ending an authenticated state advertise the `logout` capability. +ACP authentication is negotiated during [initialization](/protocol/v2/draft/initialization). Agents advertise available authentication methods in `authMethods`, Clients choose one by calling `auth/login`, and Agents that support ending an authenticated state advertise the `logout` auth capability.
@@ -16,15 +16,15 @@ sequenceDiagram Agent-->>Client: initialize response (authMethods, auth.logout) alt Agent requires authentication - Client->>Agent: authenticate (methodId) - Agent-->>Client: authenticate response + Client->>Agent: auth/login (methodId) + Agent-->>Client: auth/login response end Note over Client,Agent: Authenticated requests may proceed alt User logs out - Client->>Agent: logout - Agent-->>Client: logout response + Client->>Agent: auth/logout + Agent-->>Client: auth/logout response end Note over Client,Agent: New sessions require authentication again @@ -34,9 +34,9 @@ sequenceDiagram ## Advertising Authentication -Agents advertise authentication options in the `authMethods` field of the `initialize` response. Each method has an `id` that the Client passes back to the Agent in a later `authenticate` request. +Agents advertise authentication options in the `authMethods` field of the `initialize` response. Each method has an `id` that the Client passes back to the Agent in a later `auth/login` request. -Agents that support `logout` also advertise `capabilities.auth.logout`: +Agents that support `auth/logout` also advertise `capabilities.auth.logout`: ```json highlight={7-11,12-19} { @@ -61,7 +61,7 @@ Agents that support `logout` also advertise `capabilities.auth.logout`: } ``` -If `capabilities.auth.logout` is omitted or `null`, the Agent does not support `logout` and Clients **MUST NOT** call it. Supplying `{}` means the Agent supports the method. +If `capabilities.auth.logout` is omitted or `null`, the Agent does not support `auth/logout` and Clients **MUST NOT** call it. Supplying `{}` means the Agent supports the method. ### Authentication method types @@ -109,13 +109,13 @@ See the [draft schema](/protocol/v2/draft/schema#authmethod) for the full `AuthM ## Authenticating -When an Agent requires authentication before allowing session creation, the Client calls `authenticate` with one of the advertised authentication method IDs: +When an Agent requires authentication before allowing session creation, the Client calls `auth/login` with one of the advertised authentication method IDs: ```json { "jsonrpc": "2.0", "id": 1, - "method": "authenticate", + "method": "auth/login", "params": { "methodId": "agent-login" } @@ -141,13 +141,13 @@ After successful authentication, the Client can create new sessions without rece ## Logging Out -The `logout` method allows Clients to end the current authenticated state. Clients should only call it after verifying the Agent advertised `capabilities.auth.logout` during initialization. +The `auth/logout` method allows Clients to end the current authenticated state. Clients should only call it after verifying the Agent advertised `capabilities.auth.logout` during initialization. ```json { "jsonrpc": "2.0", "id": 2, - "method": "logout", + "method": "auth/logout", "params": {} } ``` @@ -162,10 +162,10 @@ On success, the Agent returns an empty result: } ``` -After a successful `logout`, new sessions that require authentication will require the Client to call `authenticate` again. +After a successful `auth/logout`, new sessions that require authentication will require the Client to call `auth/login` again. ## Active Sessions -The protocol does not guarantee what happens to already-running sessions after `logout`. Agents may terminate them, keep them running, or return `auth_required` errors for future session activity. +The protocol does not guarantee what happens to already-running sessions after `auth/logout`. Agents may terminate them, keep them running, or return `auth_required` errors for future session activity. Clients **SHOULD** be prepared for active session operations to fail with authentication-related errors after logout and should prompt the user to authenticate again when appropriate. diff --git a/docs/protocol/v2/draft/initialization.mdx b/docs/protocol/v2/draft/initialization.mdx index 3a9a2c62..95cd8b3d 100644 --- a/docs/protocol/v2/draft/initialization.mdx +++ b/docs/protocol/v2/draft/initialization.mdx @@ -219,7 +219,7 @@ Optionally, they **MAY** support richer types of [content](/protocol/v2/draft/co #### Authentication Capabilities - The [`logout`](/protocol/v2/draft/authentication#logging-out) method is + The [`auth/logout`](/protocol/v2/draft/authentication#logging-out) method is available. diff --git a/docs/protocol/v2/draft/overview.mdx b/docs/protocol/v2/draft/overview.mdx index 6ea15dea..92674dec 100644 --- a/docs/protocol/v2/draft/overview.mdx +++ b/docs/protocol/v2/draft/overview.mdx @@ -24,7 +24,7 @@ A typical flow follows this pattern: - Client → Agent: `initialize` to establish connection -- Client → Agent: `authenticate` if required by the Agent +- Client → Agent: `auth/login` if required by the Agent @@ -60,8 +60,8 @@ Agents are programs that use generative AI to autonomously modify code. They typ Schema]} + name="auth/login" + post={[Schema]} > Authenticate with the Agent (if required). @@ -93,8 +93,8 @@ Agents are programs that use generative AI to autonomously modify code. They typ Schema]} + name="auth/logout" + post={[Schema]} > [End the current authenticated state](/protocol/v2/draft/authentication#logging-out) (requires diff --git a/docs/protocol/v2/draft/schema.mdx b/docs/protocol/v2/draft/schema.mdx index ea08cffa..fc8e7349 100644 --- a/docs/protocol/v2/draft/schema.mdx +++ b/docs/protocol/v2/draft/schema.mdx @@ -16,7 +16,8 @@ Defines the interface that all ACP-compliant agents must implement. Agents are programs that use generative AI to autonomously modify code. They handle requests from clients and execute tasks using language models and tools. -### authenticate + +### auth/login Authenticates the client using the specified authentication method. @@ -28,9 +29,9 @@ After successful authentication, the client can proceed to create sessions with See protocol docs: [Initialization](https://agentclientprotocol.com/protocol/v2/draft/initialization) -#### AuthenticateRequest +#### LoginAuthRequest -Request parameters for the authenticate method. +Request parameters for the `auth/login` method. Specifies which authentication method to use. @@ -51,9 +52,53 @@ See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/d Must be one of the methods advertised in the initialize response. -#### AuthenticateResponse +#### LoginAuthResponse -Response to the `authenticate` method. +Response to the `auth/login` method. + +**Type:** Object + +**Properties:** + + + The _meta property is reserved by ACP to allow clients and agents to attach additional +metadata to their interactions. Implementations MUST NOT make assumptions about values at +these keys. + +See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/draft/extensibility) + + + + +### auth/logout + +Logs out of the current authenticated state. + +After a successful logout, all new sessions will require authentication. +There is no guarantee about the behavior of already running sessions. + +#### LogoutAuthRequest + +Request parameters for the `auth/logout` method. + +Terminates the current authenticated session. + +**Type:** Object + +**Properties:** + + + The _meta property is reserved by ACP to allow clients and agents to attach additional +metadata to their interactions. Implementations MUST NOT make assumptions about values at +these keys. + +See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/draft/extensibility) + + + +#### LogoutAuthResponse + +Response to the `auth/logout` method. **Type:** Object @@ -332,49 +377,6 @@ The client should disconnect, if it doesn't support this version. -### logout - -Logs out of the current authenticated state. - -After a successful logout, all new sessions will require authentication. -There is no guarantee about the behavior of already running sessions. - -#### LogoutRequest - -Request parameters for the logout method. - -Terminates the current authenticated session. - -**Type:** Object - -**Properties:** - - - The _meta property is reserved by ACP to allow clients and agents to attach additional -metadata to their interactions. Implementations MUST NOT make assumptions about values at -these keys. - -See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/draft/extensibility) - - - -#### LogoutResponse - -Response to the `logout` method. - -**Type:** Object - -**Properties:** - - - The _meta property is reserved by ACP to allow clients and agents to attach additional -metadata to their interactions. Implementations MUST NOT make assumptions about values at -these keys. - -See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/draft/extensibility) - - - ### mcp/message diff --git a/docs/protocol/v2/draft/transports.mdx b/docs/protocol/v2/draft/transports.mdx index 77f02ccb..20a9174f 100644 --- a/docs/protocol/v2/draft/transports.mdx +++ b/docs/protocol/v2/draft/transports.mdx @@ -75,7 +75,7 @@ When receiving a batch call: fail. Clients and agents **SHOULD NOT** batch lifecycle-sensitive messages such as -`initialize`, `authenticate`, `session/new`, `session/load`, and +`initialize`, `auth/login`, `session/new`, `session/load`, and `session/prompt`. These messages are easier to reason about as individual transport messages and can change which later messages are valid. diff --git a/docs/protocol/v2/initialization.mdx b/docs/protocol/v2/initialization.mdx index 68e46bb2..954b19d8 100644 --- a/docs/protocol/v2/initialization.mdx +++ b/docs/protocol/v2/initialization.mdx @@ -214,7 +214,8 @@ Optionally, they **MAY** support richer types of [content](/protocol/v2/content) #### Authentication Capabilities - The [`logout`](/protocol/v2/authentication#logging-out) method is available. + The [`auth/logout`](/protocol/v2/authentication#logging-out) method is + available. diff --git a/docs/protocol/v2/overview.mdx b/docs/protocol/v2/overview.mdx index 1979cb55..07d7766c 100644 --- a/docs/protocol/v2/overview.mdx +++ b/docs/protocol/v2/overview.mdx @@ -24,7 +24,7 @@ A typical flow follows this pattern: - Client → Agent: `initialize` to establish connection -- Client → Agent: `authenticate` if required by the Agent +- Client → Agent: `auth/login` if required by the Agent @@ -59,8 +59,8 @@ Agents are programs that use generative AI to autonomously modify code. They typ Schema]} + name="auth/login" + post={[Schema]} > Authenticate with the Agent (if required). @@ -92,8 +92,8 @@ Agents are programs that use generative AI to autonomously modify code. They typ Schema]} + name="auth/logout" + post={[Schema]} > [End the current authenticated state](/protocol/v2/authentication#logging-out) (requires `capabilities.auth.logout` capability). diff --git a/docs/protocol/v2/schema.mdx b/docs/protocol/v2/schema.mdx index 208b2add..1c399d72 100644 --- a/docs/protocol/v2/schema.mdx +++ b/docs/protocol/v2/schema.mdx @@ -16,7 +16,8 @@ Defines the interface that all ACP-compliant agents must implement. Agents are programs that use generative AI to autonomously modify code. They handle requests from clients and execute tasks using language models and tools. -### authenticate + +### auth/login Authenticates the client using the specified authentication method. @@ -28,9 +29,9 @@ After successful authentication, the client can proceed to create sessions with See protocol docs: [Initialization](https://agentclientprotocol.com/protocol/v2/initialization) -#### AuthenticateRequest +#### LoginAuthRequest -Request parameters for the authenticate method. +Request parameters for the `auth/login` method. Specifies which authentication method to use. @@ -51,9 +52,53 @@ See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/e Must be one of the methods advertised in the initialize response. -#### AuthenticateResponse +#### LoginAuthResponse -Response to the `authenticate` method. +Response to the `auth/login` method. + +**Type:** Object + +**Properties:** + + + The _meta property is reserved by ACP to allow clients and agents to attach additional +metadata to their interactions. Implementations MUST NOT make assumptions about values at +these keys. + +See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/extensibility) + + + + +### auth/logout + +Logs out of the current authenticated state. + +After a successful logout, all new sessions will require authentication. +There is no guarantee about the behavior of already running sessions. + +#### LogoutAuthRequest + +Request parameters for the `auth/logout` method. + +Terminates the current authenticated session. + +**Type:** Object + +**Properties:** + + + The _meta property is reserved by ACP to allow clients and agents to attach additional +metadata to their interactions. Implementations MUST NOT make assumptions about values at +these keys. + +See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/extensibility) + + + +#### LogoutAuthResponse + +Response to the `auth/logout` method. **Type:** Object @@ -158,49 +203,6 @@ The client should disconnect, if it doesn't support this version. -### logout - -Logs out of the current authenticated state. - -After a successful logout, all new sessions will require authentication. -There is no guarantee about the behavior of already running sessions. - -#### LogoutRequest - -Request parameters for the logout method. - -Terminates the current authenticated session. - -**Type:** Object - -**Properties:** - - - The _meta property is reserved by ACP to allow clients and agents to attach additional -metadata to their interactions. Implementations MUST NOT make assumptions about values at -these keys. - -See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/extensibility) - - - -#### LogoutResponse - -Response to the `logout` method. - -**Type:** Object - -**Properties:** - - - The _meta property is reserved by ACP to allow clients and agents to attach additional -metadata to their interactions. Implementations MUST NOT make assumptions about values at -these keys. - -See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/v2/extensibility) - - - ### session/cancel diff --git a/docs/protocol/v2/transports.mdx b/docs/protocol/v2/transports.mdx index 77f02ccb..20a9174f 100644 --- a/docs/protocol/v2/transports.mdx +++ b/docs/protocol/v2/transports.mdx @@ -75,7 +75,7 @@ When receiving a batch call: fail. Clients and agents **SHOULD NOT** batch lifecycle-sensitive messages such as -`initialize`, `authenticate`, `session/new`, `session/load`, and +`initialize`, `auth/login`, `session/new`, `session/load`, and `session/prompt`. These messages are easier to reason about as individual transport messages and can change which later messages are valid. diff --git a/docs/rfds/v2/overview.mdx b/docs/rfds/v2/overview.mdx index 52dad337..c9e22006 100644 --- a/docs/rfds/v2/overview.mdx +++ b/docs/rfds/v2/overview.mdx @@ -51,6 +51,8 @@ Other RFDs will progress separately and are not dependent on breaking changes (s - Follow JSON-RPC 2.0 batch request and notification behavior. - Clean up capability naming and organization: - Use a single `capabilities` field in both `initialize` params and results, replacing the v1-style `clientCapabilities` and `agentCapabilities` fields. + - Require implementation metadata in both `initialize` params and results with a single role-agnostic `info` field, replacing the v1-style `clientInfo` and `agentInfo` fields so agent-to-agent and other symmetric ACP connections do not need role-specific field names. + - Group authentication methods under `auth/*`: v2 uses `auth/login` and `auth/logout` instead of v1's top-level `authenticate` and `logout` method names. The generated request and response type names follow the grouped method naming as `LoginAuthRequest` / `LoginAuthResponse` and `LogoutAuthRequest` / `LogoutAuthResponse`. - Use concise capability group names such as `session` and `auth`, replacing names like `sessionCapabilities`. - Make `session` optional so non-session agents, such as NES-only agents, can omit it. - Move session-scoped capability groups under `session`, including `prompt`, `mcp`, and `loadSession` as `session.prompt`, `session.mcp`, and `session.load`. @@ -106,6 +108,8 @@ With the needed breaking changes, as much as possible I am targeting having a co ## Revision history +- 2026-06-25: Recorded the v2 initialize information cleanup: required role-agnostic `info` in both params and results, replacing `clientInfo` and `agentInfo`. +- 2026-06-25: Recorded the v2 authentication method cleanup: grouped `auth/login` and `auth/logout` method names replace v1's top-level `authenticate` and `logout`, with matching generated type names for login and logout auth requests and responses. - 2026-06-09: Added tool-call content chunks for streaming individual `ToolCallContent` items. - 2026-06-09: Added the v2 Message Updates and Chunks RFD to define whole-message upserts alongside streamed message chunks. - 2026-06-08: Added the v2 Tool Call Updates RFD to make `tool_call_update` the single upsert-style tool-call session update. diff --git a/schema-generator/src/main.rs b/schema-generator/src/main.rs index f8f930d4..c5c20ed0 100644 --- a/schema-generator/src/main.rs +++ b/schema-generator/src/main.rs @@ -1577,6 +1577,7 @@ starting with '$/' it is free to ignore the notification." match method_name { "initialize" => self.agent.get("InitializeRequest").unwrap(), "authenticate" => self.agent.get("AuthenticateRequest").unwrap(), + "auth/login" => self.agent.get("LoginAuthRequest").unwrap(), "providers/list" => self.agent.get("ListProvidersRequest").unwrap(), "providers/set" => self.agent.get("SetProviderRequest").unwrap(), "providers/disable" => self.agent.get("DisableProviderRequest").unwrap(), @@ -1594,6 +1595,7 @@ starting with '$/' it is free to ignore the notification." "session/cancel" => self.agent.get("CancelNotification").unwrap(), "session/close" => self.agent.get("CloseSessionRequest").unwrap(), "logout" => self.agent.get("LogoutRequest").unwrap(), + "auth/logout" => self.agent.get("LogoutAuthRequest").unwrap(), "nes/start" => self.agent.get("StartNesRequest").unwrap(), "nes/suggest" => self.agent.get("SuggestNesRequest").unwrap(), "nes/close" => self.agent.get("CloseNesRequest").unwrap(), diff --git a/schema/v2/meta.json b/schema/v2/meta.json index f4ebd82c..e1ecdb25 100644 --- a/schema/v2/meta.json +++ b/schema/v2/meta.json @@ -2,7 +2,7 @@ "version": 2, "agentMethods": { "initialize": "initialize", - "authenticate": "authenticate", + "auth_login": "auth/login", "session_new": "session/new", "session_load": "session/load", "session_set_config_option": "session/set_config_option", @@ -12,7 +12,7 @@ "session_delete": "session/delete", "session_resume": "session/resume", "session_close": "session/close", - "logout": "logout" + "auth_logout": "auth/logout" }, "clientMethods": { "session_request_permission": "session/request_permission", diff --git a/schema/v2/meta.unstable.json b/schema/v2/meta.unstable.json index 06435b00..211abc08 100644 --- a/schema/v2/meta.unstable.json +++ b/schema/v2/meta.unstable.json @@ -2,7 +2,7 @@ "version": 2, "agentMethods": { "initialize": "initialize", - "authenticate": "authenticate", + "auth_login": "auth/login", "providers_list": "providers/list", "providers_set": "providers/set", "providers_disable": "providers/disable", @@ -17,7 +17,7 @@ "session_fork": "session/fork", "session_resume": "session/resume", "session_close": "session/close", - "logout": "logout", + "auth_logout": "auth/logout", "nes_start": "nes/start", "nes_suggest": "nes/suggest", "nes_accept": "nes/accept", diff --git a/schema/v2/schema.json b/schema/v2/schema.json index 43e3defe..bb78ec52 100644 --- a/schema/v2/schema.json +++ b/schema/v2/schema.json @@ -154,20 +154,20 @@ ] }, { - "title": "AuthenticateResponse", - "description": "Successful result returned for a `authenticate` request.", + "title": "LoginAuthResponse", + "description": "Successful result returned for an `auth/login` request.", "allOf": [ { - "$ref": "#/$defs/AuthenticateResponse" + "$ref": "#/$defs/LoginAuthResponse" } ] }, { - "title": "LogoutResponse", - "description": "Successful result returned for a `logout` request.", + "title": "LogoutAuthResponse", + "description": "Successful result returned for an `auth/logout` request.", "allOf": [ { - "$ref": "#/$defs/LogoutResponse" + "$ref": "#/$defs/LogoutAuthResponse" } ] }, @@ -1376,20 +1376,20 @@ ] }, { - "title": "AuthenticateResponse", - "description": "Successful result returned for a `authenticate` request.", + "title": "LoginAuthResponse", + "description": "Successful result returned for an `auth/login` request.", "allOf": [ { - "$ref": "#/$defs/AuthenticateResponse" + "$ref": "#/$defs/LoginAuthResponse" } ] }, { - "title": "LogoutResponse", - "description": "Successful result returned for a `logout` request.", + "title": "LogoutAuthResponse", + "description": "Successful result returned for an `auth/logout` request.", "allOf": [ { - "$ref": "#/$defs/LogoutResponse" + "$ref": "#/$defs/LogoutAuthResponse" } ] }, @@ -2065,8 +2065,8 @@ }, "required": ["name", "version"] }, - "AuthenticateResponse": { - "description": "Response to the `authenticate` method.", + "LoginAuthResponse": { + "description": "Response to the `auth/login` method.", "type": "object", "properties": { "_meta": { @@ -2076,10 +2076,10 @@ } }, "x-side": "agent", - "x-method": "authenticate" + "x-method": "auth/login" }, - "LogoutResponse": { - "description": "Response to the `logout` method.", + "LogoutAuthResponse": { + "description": "Response to the `auth/logout` method.", "type": "object", "properties": { "_meta": { @@ -2089,7 +2089,7 @@ } }, "x-side": "agent", - "x-method": "logout" + "x-method": "auth/logout" }, "NewSessionResponse": { "description": "Response from creating a new session.\n\nSee protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)", @@ -3852,20 +3852,20 @@ ] }, { - "title": "AuthenticateRequest", + "title": "LoginAuthRequest", "description": "Authenticates the client using the specified authentication method.\n\nCalled when the agent requires authentication before allowing session creation.\nThe client provides the authentication method ID that was advertised during initialization.\n\nAfter successful authentication, the client can proceed to create sessions with\n`new_session` without receiving an `auth_required` error.\n\nSee protocol docs: [Initialization](https://agentclientprotocol.com/protocol/initialization)", "allOf": [ { - "$ref": "#/$defs/AuthenticateRequest" + "$ref": "#/$defs/LoginAuthRequest" } ] }, { - "title": "LogoutRequest", + "title": "LogoutAuthRequest", "description": "Logs out of the current authenticated state.\n\nAfter a successful logout, all new sessions will require authentication.\nThere is no guarantee about the behavior of already running sessions.", "allOf": [ { - "$ref": "#/$defs/LogoutRequest" + "$ref": "#/$defs/LogoutAuthRequest" } ] }, @@ -4011,8 +4011,8 @@ } } }, - "AuthenticateRequest": { - "description": "Request parameters for the authenticate method.\n\nSpecifies which authentication method to use.", + "LoginAuthRequest": { + "description": "Request parameters for the `auth/login` method.\n\nSpecifies which authentication method to use.", "type": "object", "properties": { "methodId": { @@ -4031,10 +4031,10 @@ }, "required": ["methodId"], "x-side": "agent", - "x-method": "authenticate" + "x-method": "auth/login" }, - "LogoutRequest": { - "description": "Request parameters for the logout method.\n\nTerminates the current authenticated session.", + "LogoutAuthRequest": { + "description": "Request parameters for the `auth/logout` method.\n\nTerminates the current authenticated session.", "type": "object", "properties": { "_meta": { @@ -4044,7 +4044,7 @@ } }, "x-side": "agent", - "x-method": "logout" + "x-method": "auth/logout" }, "NewSessionRequest": { "description": "Request parameters for creating a new session.\n\nSee protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)", diff --git a/schema/v2/schema.unstable.json b/schema/v2/schema.unstable.json index bb22bee5..2febca92 100644 --- a/schema/v2/schema.unstable.json +++ b/schema/v2/schema.unstable.json @@ -162,11 +162,11 @@ ] }, { - "title": "AuthenticateResponse", - "description": "Successful result returned for a `authenticate` request.", + "title": "LoginAuthResponse", + "description": "Successful result returned for an `auth/login` request.", "allOf": [ { - "$ref": "#/$defs/AuthenticateResponse" + "$ref": "#/$defs/LoginAuthResponse" } ] }, @@ -198,11 +198,11 @@ ] }, { - "title": "LogoutResponse", - "description": "Successful result returned for a `logout` request.", + "title": "LogoutAuthResponse", + "description": "Successful result returned for an `auth/logout` request.", "allOf": [ { - "$ref": "#/$defs/LogoutResponse" + "$ref": "#/$defs/LogoutAuthResponse" } ] }, @@ -2305,11 +2305,11 @@ ] }, { - "title": "AuthenticateResponse", - "description": "Successful result returned for a `authenticate` request.", + "title": "LoginAuthResponse", + "description": "Successful result returned for an `auth/login` request.", "allOf": [ { - "$ref": "#/$defs/AuthenticateResponse" + "$ref": "#/$defs/LoginAuthResponse" } ] }, @@ -2341,11 +2341,11 @@ ] }, { - "title": "LogoutResponse", - "description": "Successful result returned for a `logout` request.", + "title": "LogoutAuthResponse", + "description": "Successful result returned for an `auth/logout` request.", "allOf": [ { - "$ref": "#/$defs/LogoutResponse" + "$ref": "#/$defs/LogoutAuthResponse" } ] }, @@ -3717,8 +3717,8 @@ }, "required": ["name", "version"] }, - "AuthenticateResponse": { - "description": "Response to the `authenticate` method.", + "LoginAuthResponse": { + "description": "Response to the `auth/login` method.", "type": "object", "properties": { "_meta": { @@ -3728,7 +3728,7 @@ } }, "x-side": "agent", - "x-method": "authenticate" + "x-method": "auth/login" }, "ListProvidersResponse": { "description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nResponse to `providers/list`.", @@ -3878,8 +3878,8 @@ "x-side": "agent", "x-method": "providers/disable" }, - "LogoutResponse": { - "description": "Response to the `logout` method.", + "LogoutAuthResponse": { + "description": "Response to the `auth/logout` method.", "type": "object", "properties": { "_meta": { @@ -3889,7 +3889,7 @@ } }, "x-side": "agent", - "x-method": "logout" + "x-method": "auth/logout" }, "NewSessionResponse": { "description": "Response from creating a new session.\n\nSee protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)", @@ -6390,11 +6390,11 @@ ] }, { - "title": "AuthenticateRequest", + "title": "LoginAuthRequest", "description": "Authenticates the client using the specified authentication method.\n\nCalled when the agent requires authentication before allowing session creation.\nThe client provides the authentication method ID that was advertised during initialization.\n\nAfter successful authentication, the client can proceed to create sessions with\n`new_session` without receiving an `auth_required` error.\n\nSee protocol docs: [Initialization](https://agentclientprotocol.com/protocol/initialization)", "allOf": [ { - "$ref": "#/$defs/AuthenticateRequest" + "$ref": "#/$defs/LoginAuthRequest" } ] }, @@ -6426,11 +6426,11 @@ ] }, { - "title": "LogoutRequest", + "title": "LogoutAuthRequest", "description": "Logs out of the current authenticated state.\n\nAfter a successful logout, all new sessions will require authentication.\nThere is no guarantee about the behavior of already running sessions.", "allOf": [ { - "$ref": "#/$defs/LogoutRequest" + "$ref": "#/$defs/LogoutAuthRequest" } ] }, @@ -6836,8 +6836,8 @@ } } }, - "AuthenticateRequest": { - "description": "Request parameters for the authenticate method.\n\nSpecifies which authentication method to use.", + "LoginAuthRequest": { + "description": "Request parameters for the `auth/login` method.\n\nSpecifies which authentication method to use.", "type": "object", "properties": { "methodId": { @@ -6856,7 +6856,7 @@ }, "required": ["methodId"], "x-side": "agent", - "x-method": "authenticate" + "x-method": "auth/login" }, "ListProvidersRequest": { "description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nRequest parameters for `providers/list`.", @@ -6926,8 +6926,8 @@ "x-side": "agent", "x-method": "providers/disable" }, - "LogoutRequest": { - "description": "Request parameters for the logout method.\n\nTerminates the current authenticated session.", + "LogoutAuthRequest": { + "description": "Request parameters for the `auth/logout` method.\n\nTerminates the current authenticated session.", "type": "object", "properties": { "_meta": { @@ -6937,7 +6937,7 @@ } }, "x-side": "agent", - "x-method": "logout" + "x-method": "auth/logout" }, "NewSessionRequest": { "description": "Request parameters for creating a new session.\n\nSee protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)",