Skip to content

NewSessionResponse

Base classes

Name Children Inherits
Response
aclientp.schema.base
Base request model.

⋔ Inheritance diagram

graph TD
  95970847085888["agent_responses.NewSessionResponse"]
  95970861210848["base.Response"]
  95970862258240["base.AnnotatedObject"]
  95970862254416["base.Schema"]
  95970851503232["main.BaseModel"]
  125067848591872["builtins.object"]
  95970861210848 --> 95970847085888
  95970862258240 --> 95970861210848
  95970862254416 --> 95970862258240
  95970851503232 --> 95970862254416
  125067848591872 --> 95970851503232

🛈 DocStrings

Bases: Response

Response from creating a new session.

See protocol docs: Creating a Session

Source code in src/aclientp/schema/agent_responses.py
class NewSessionResponse(Response):
    """Response from creating a new session.

    See protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)
    """

    modes: SessionModeState | None = None
    """Initial mode state if supported by the Agent

    See protocol docs: [Session Modes](https://agentclientprotocol.com/protocol/session-modes)
    """

    config_options: Sequence[SessionConfigOption] | None = None
    """**Configuration options for this session."""

    session_id: str
    """Unique identifier for the created session.

    Used in all subsequent requests for this conversation.
    """

config_options class-attribute instance-attribute

config_options: Sequence[SessionConfigOption] | None = None

**Configuration options for this session.

modes class-attribute instance-attribute

modes: SessionModeState | None = None

Initial mode state if supported by the Agent

See protocol docs: Session Modes

session_id instance-attribute

session_id: str

Unique identifier for the created session.

Used in all subsequent requests for this conversation.

:fa-brands-github: Show source on GitHub