// Code generated by internal/schemagen. DO NOT EDIT.

package schema

// Request parameters for the authenticate method.
// Specifies which authentication method to use
// AuthenticateRequest represents a [schema] type.
type AuthenticateRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The ID of the authentication method to use
	MethodId string `json:"methodId"`
}

// Response to the `authenticate` method
// AuthenticateResponse represents a [schema] type.
type AuthenticateResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
}

// Request to create a new terminal and execute a command
// CreateTerminalRequest represents a [schema] type.
type CreateTerminalRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Array of command arguments
	Args []string `json:"args,omitempty"`
	// The command to execute
	Command string `json:"command"`
	// Working directory for the command (absolute path)
	Cwd *string `json:"cwd,omitempty"`
	// Environment variables for the command
	Env []*EnvVariable `json:"env,omitempty"`
	// Maximum number of output bytes to retain
	OutputByteLimit *int `json:"outputByteLimit,omitempty"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
}

// Response containing the ID of the created terminal
// CreateTerminalResponse represents a [schema] type.
type CreateTerminalResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The unique identifier for the created terminal
	TerminalId string `json:"terminalId"`
}

// JSON-RPC error object.
// Represents an error that occurred during method execution, following the
// JSON-RPC 2.0 error object specification with optional additional data.
// See protocol docs: [JSON-RPC Error Object](https://www.jsonrpc.org/specification#error_object)
// Error represents a [schema] type.
type Error struct {
	// A number indicating the error type that occurred
	Code *ErrorCode `json:"code"`
	// Optional primitive or structured value that contains additional information about the error
	Data any `json:"data,omitempty"`
	// A string providing a short description of the error
	Message string `json:"message"`
}

// Request parameters for the initialize method.
// Sent by the client to establish connection and negotiate capabilities.
// See protocol docs: [Initialization](https://agentclientprotocol.com/protocol/initialization)
// InitializeRequest represents a [schema] type.
type InitializeRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Capabilities supported by the client
	ClientCapabilities *ClientCapabilities `json:"clientCapabilities,omitempty"`
	// Information about the Client name and version sent to the Agent
	ClientInfo *Implementation `json:"clientInfo,omitempty"`
	// The latest protocol version supported by the client
	ProtocolVersion *ProtocolVersion `json:"protocolVersion"`
}

// Response to the `initialize` method.
// Contains the negotiated protocol version and agent capabilities.
// See protocol docs: [Initialization](https://agentclientprotocol.com/protocol/initialization)
// InitializeResponse represents a [schema] type.
type InitializeResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Capabilities supported by the agent
	AgentCapabilities *AgentCapabilities `json:"agentCapabilities,omitempty"`
	// Information about the Agent name and version sent to the Client
	AgentInfo *Implementation `json:"agentInfo,omitempty"`
	// Authentication methods supported by the agent
	AuthMethods []*AuthMethod `json:"authMethods,omitempty"`
	// The protocol version the client specified if supported by the agent,
	ProtocolVersion *ProtocolVersion `json:"protocolVersion"`
}

// Request to kill a terminal without releasing it
// KillTerminalRequest represents a [schema] type.
type KillTerminalRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
	// The ID of the terminal to kill
	TerminalId string `json:"terminalId"`
}

// Response to `terminal/kill` method
// KillTerminalResponse represents a [schema] type.
type KillTerminalResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
}

// Request parameters for listing existing sessions.
// Only available if the Agent supports the `sessionCapabilities.list` capability
// ListSessionsRequest represents a [schema] type.
type ListSessionsRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Opaque cursor token from a previous response's nextCursor field for cursor-based pagination
	Cursor *string `json:"cursor,omitempty"`
	// Filter sessions by working directory. Must be an absolute path
	Cwd *string `json:"cwd,omitempty"`
}

// Response from listing sessions
// ListSessionsResponse represents a [schema] type.
type ListSessionsResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Opaque cursor token. If present, pass this in the next request's cursor parameter
	NextCursor *string `json:"nextCursor,omitempty"`
	// Array of session information objects
	Sessions []*SessionInfo `json:"sessions"`
}

// Request parameters for loading an existing session.
// Only available if the Agent supports the `loadSession` capability.
// See protocol docs: [Loading Sessions](https://agentclientprotocol.com/protocol/session-setup#loading-sessions)
// LoadSessionRequest represents a [schema] type.
type LoadSessionRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The working directory for this session
	Cwd string `json:"cwd"`
	// List of MCP servers to connect to for this session
	McpServers []*McpServer `json:"mcpServers"`
	// The ID of the session to load
	SessionId *SessionId `json:"sessionId"`
}

// Response from loading an existing session
// LoadSessionResponse represents a [schema] type.
type LoadSessionResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Initial session configuration options if supported by the Agent
	ConfigOptions []*SessionConfigOption `json:"configOptions,omitempty"`
	// Initial mode state if supported by the Agent
	Modes *SessionModeState `json:"modes,omitempty"`
}

// Request parameters for creating a new session.
// See protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)
// NewSessionRequest represents a [schema] type.
type NewSessionRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The working directory for this session. Must be an absolute path
	Cwd string `json:"cwd"`
	// List of MCP (Model Context Protocol) servers the agent should connect to
	McpServers []*McpServer `json:"mcpServers"`
}

// Response from creating a new session.
// See protocol docs: [Creating a Session](https://agentclientprotocol.com/protocol/session-setup#creating-a-session)
// NewSessionResponse represents a [schema] type.
type NewSessionResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Initial session configuration options if supported by the Agent
	ConfigOptions []*SessionConfigOption `json:"configOptions,omitempty"`
	// Initial mode state if supported by the Agent
	Modes *SessionModeState `json:"modes,omitempty"`
	// Unique identifier for the created session
	SessionId *SessionId `json:"sessionId"`
}

// An option presented to the user when requesting permission
// PermissionOption represents a [schema] type.
type PermissionOption struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Hint about the nature of this permission option
	Kind *PermissionOptionKind `json:"kind"`
	// Human-readable label to display to the user
	Name string `json:"name"`
	// Unique identifier for this permission option
	OptionId *PermissionOptionId `json:"optionId"`
}

// Request parameters for sending a user prompt to the agent.
// Contains the user's message and any additional context.
// See protocol docs: [User Message](https://agentclientprotocol.com/protocol/prompt-turn#1-user-message)
// PromptRequest represents a [schema] type.
type PromptRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The blocks of content that compose the user's message
	Prompt []*ContentBlock `json:"prompt"`
	// The ID of the session to send this user message to
	SessionId *SessionId `json:"sessionId"`
}

// Response from processing a user prompt.
// See protocol docs: [Check for Completion](https://agentclientprotocol.com/protocol/prompt-turn#4-check-for-completion)
// PromptResponse represents a [schema] type.
type PromptResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Indicates why the agent stopped processing the turn
	StopReason *StopReason `json:"stopReason"`
}

// Request to read content from a text file.
// Only available if the client supports the `fs.readTextFile` capability
// ReadTextFileRequest represents a [schema] type.
type ReadTextFileRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Maximum number of lines to read
	Limit *int `json:"limit,omitempty"`
	// Line number to start reading from (1-based)
	Line *int `json:"line,omitempty"`
	// Absolute path to the file to read
	Path string `json:"path"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
}

// Response containing the contents of a text file
// ReadTextFileResponse represents a [schema] type.
type ReadTextFileResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta    Meta   `json:"_meta,omitempty"`
	Content string `json:"content"`
}

// Request to release a terminal and free its resources
// ReleaseTerminalRequest represents a [schema] type.
type ReleaseTerminalRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
	// The ID of the terminal to release
	TerminalId string `json:"terminalId"`
}

// Response to terminal/release method
// ReleaseTerminalResponse represents a [schema] type.
type ReleaseTerminalResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
}

// Request for user permission to execute a tool call.
// Sent when the agent needs authorization before performing a sensitive operation.
// See protocol docs: [Requesting Permission](https://agentclientprotocol.com/protocol/tool-calls#requesting-permission)
// RequestPermissionRequest represents a [schema] type.
type RequestPermissionRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Available permission options for the user to choose from
	Options []*PermissionOption `json:"options"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
	// Details about the tool call requiring permission
	ToolCall *ToolCallUpdate `json:"toolCall"`
}

// Response to a permission request
// RequestPermissionResponse represents a [schema] type.
type RequestPermissionResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The user's decision on the permission request
	Outcome *RequestPermissionOutcome `json:"outcome"`
}

// Request parameters for setting a session configuration option
// SetSessionConfigOptionRequest represents a [schema] type.
type SetSessionConfigOptionRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The ID of the configuration option to set
	ConfigId *SessionConfigId `json:"configId"`
	// The ID of the session to set the configuration option for
	SessionId *SessionId `json:"sessionId"`
	// The ID of the configuration option value to set
	Value *SessionConfigValueId `json:"value"`
}

// Response to `session/set_config_option` method
// SetSessionConfigOptionResponse represents a [schema] type.
type SetSessionConfigOptionResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The full set of configuration options and their current values
	ConfigOptions []*SessionConfigOption `json:"configOptions"`
}

// Request parameters for setting a session mode
// SetSessionModeRequest represents a [schema] type.
type SetSessionModeRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The ID of the mode to set
	ModeId *SessionModeId `json:"modeId"`
	// The ID of the session to set the mode for
	SessionId *SessionId `json:"sessionId"`
}

// Response to `session/set_mode` method
// SetSessionModeResponse represents a [schema] type.
type SetSessionModeResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
}

// Request to get the current output and status of a terminal
// TerminalOutputRequest represents a [schema] type.
type TerminalOutputRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
	// The ID of the terminal to get output from
	TerminalId string `json:"terminalId"`
}

// Response containing the terminal output and exit status
// TerminalOutputResponse represents a [schema] type.
type TerminalOutputResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// Exit status if the command has completed
	ExitStatus *TerminalExitStatus `json:"exitStatus,omitempty"`
	// The terminal output captured so far
	Output string `json:"output"`
	// Whether the output was truncated due to byte limits
	Truncated bool `json:"truncated"`
}

// Request to wait for a terminal command to exit
// WaitForTerminalExitRequest represents a [schema] type.
type WaitForTerminalExitRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
	// The ID of the terminal to wait for
	TerminalId string `json:"terminalId"`
}

// Response containing the exit status of a terminal command
// WaitForTerminalExitResponse represents a [schema] type.
type WaitForTerminalExitResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The process exit code (may be null if terminated by signal)
	ExitCode *int `json:"exitCode,omitempty"`
	// The signal that terminated the process (may be null if exited normally)
	Signal *string `json:"signal,omitempty"`
}

// Request to write content to a text file.
// Only available if the client supports the `fs.writeTextFile` capability
// WriteTextFileRequest represents a [schema] type.
type WriteTextFileRequest struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
	// The text content to write to the file
	Content string `json:"content"`
	// Absolute path to the file to write
	Path string `json:"path"`
	// The session ID for this request
	SessionId *SessionId `json:"sessionId"`
}

// Response to `fs/write_text_file`
// WriteTextFileResponse represents a [schema] type.
type WriteTextFileResponse struct {
	// The _meta property is reserved by ACP to allow clients and agents to attach additional
	Meta Meta `json:"_meta,omitempty"`
}
