// This file is generated by the effect-codex-app-server package. Do not edit manually.// Upstream protocol ref: 678157acaa819d5510adfe359abb5d0392cfe461 import * as Schema from "effect/Schema"; export type ApplyPatchApprovalParams__FileChange = | { readonly content: string; readonly type: "add" } | { readonly content: string; readonly type: "delete" } | { readonly move_path?: string | null; readonly type: "update"; readonly unified_diff: string };export const ApplyPatchApprovalParams__FileChange = Schema.Union( [ Schema.Struct({ content: Schema.String, type: Schema.Literal("add").annotate({ title: "AddFileChangeType" }), }).annotate({ title: "AddFileChange" }), Schema.Struct({ content: Schema.String, type: Schema.Literal("delete").annotate({ title: "DeleteFileChangeType" }), }).annotate({ title: "DeleteFileChange" }), Schema.Struct({ move_path: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), type: Schema.Literal("update").annotate({ title: "UpdateFileChangeType" }), unified_diff: Schema.String, }).annotate({ title: "UpdateFileChange" }), ], { mode: "oneOf" },); export type ApplyPatchApprovalParams__ThreadId = string;export const ApplyPatchApprovalParams__ThreadId = Schema.String; export type ApplyPatchApprovalResponse__NetworkPolicyRuleAction = "allow" | "deny";export const ApplyPatchApprovalResponse__NetworkPolicyRuleAction = Schema.Literals([ "allow", "deny",]); export type ChatgptAuthTokensRefreshParams__ChatgptAuthTokensRefreshReason = "unauthorized";export const ChatgptAuthTokensRefreshParams__ChatgptAuthTokensRefreshReason = Schema.Literal("unauthorized"); export type ClientRequest__AbsolutePathBuf = string;export const ClientRequest__AbsolutePathBuf = Schema.String.annotate({ description: "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.",}); export type ClientRequest__AddCreditsNudgeCreditType = "credits" | "usage_limit";export const ClientRequest__AddCreditsNudgeCreditType = Schema.Literals(["credits", "usage_limit"]); export type ClientRequest__AdditionalContextKind = "untrusted" | "application";export const ClientRequest__AdditionalContextKind = Schema.Literals(["untrusted", "application"]); export type ClientRequest__AgentMessageInputContent = | { readonly text: string; readonly type: "input_text" } | { readonly encrypted_content: string; readonly type: "encrypted_content" };export const ClientRequest__AgentMessageInputContent = Schema.Union( [ Schema.Struct({ text: Schema.String, type: Schema.Literal("input_text").annotate({ title: "InputTextAgentMessageInputContentType", }), }).annotate({ title: "InputTextAgentMessageInputContent" }), Schema.Struct({ encrypted_content: Schema.String, type: Schema.Literal("encrypted_content").annotate({ title: "EncryptedContentAgentMessageInputContentType", }), }).annotate({ title: "EncryptedContentAgentMessageInputContent" }), ], { mode: "oneOf" },); export type ClientRequest__ApprovalsReviewer = "user" | "auto_review" | "guardian_subagent";export const ClientRequest__ApprovalsReviewer = Schema.Literals([ "user", "auto_review", "guardian_subagent",]).annotate({ description: "Configures who approval requests are routed to for review. Examples include sandbox escapes, blocked network access, MCP approval prompts, and ARC escalations. Defaults to `user`. `auto_review` uses a carefully prompted subagent to gather relevant context and apply a risk-based decision framework before approving or denying the request. The legacy value `guardian_subagent` is accepted for compatibility.",}); export type ClientRequest__AppsInstalledParams = { readonly forceRefresh?: boolean; readonly threadId?: string | null;};export const ClientRequest__AppsInstalledParams = Schema.Struct({ forceRefresh: Schema.optionalKey( Schema.Boolean.annotate({ description: "When true and Apps are permitted, refresh and publish the hosted connector runtime tool snapshot first.", }), ), threadId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional loaded thread id used to evaluate effective app configuration.", }), Schema.Null, ]), ),}).annotate({ description: "Read the committed installed connector runtime snapshot." }); export type ClientRequest__AppsListParams = { readonly cursor?: string | null; readonly forceRefetch?: boolean; readonly limit?: number | null; readonly threadId?: string | null;};export const ClientRequest__AppsListParams = Schema.Struct({ cursor: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Opaque pagination cursor returned by a previous call.", }), Schema.Null, ]), ), forceRefetch: Schema.optionalKey( Schema.Boolean.annotate({ description: "When true, bypass app caches and fetch the latest data from sources.", }), ), limit: Schema.optionalKey( Schema.Union([ Schema.Number.annotate({ description: "Optional page size; defaults to a reasonable server-side value.", format: "uint32", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), Schema.Null, ]), ), threadId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional thread id used to evaluate app feature gating from that thread's config.", }), Schema.Null, ]), ),}).annotate({ description: "EXPERIMENTAL - list available apps/connectors." }); export type ClientRequest__AppsReadParams = { readonly appIds: ReadonlyArray<string>; readonly includeTools?: boolean;};export const ClientRequest__AppsReadParams = Schema.Struct({ appIds: Schema.Array(Schema.String).annotate({ description: "App ids to read. The server accepts at most 100 ids and deduplicates repeated ids while preserving their first-request order.", }), includeTools: Schema.optionalKey( Schema.Boolean.annotate({ description: "When true, include display-only public tool summaries in the returned metadata.", }), ),}).annotate({ description: "EXPERIMENTAL - read metadata for specific apps/connectors." }); export type ClientRequest__AskForApproval = | "untrusted" | "on-request" | "never" | { readonly granular: { readonly mcp_elicitations: boolean; readonly request_permissions?: boolean; readonly rules: boolean; readonly sandbox_approval: boolean; readonly skill_approval?: boolean; }; };export const ClientRequest__AskForApproval = Schema.Union( [ Schema.Literals(["untrusted", "on-request", "never"]), Schema.Struct({ granular: Schema.Struct({ mcp_elicitations: Schema.Boolean, request_permissions: Schema.optionalKey(Schema.Boolean.annotate({ default: false })), rules: Schema.Boolean, sandbox_approval: Schema.Boolean, skill_approval: Schema.optionalKey(Schema.Boolean.annotate({ default: false })), }), }).annotate({ title: "GranularAskForApproval" }), ], { mode: "oneOf" },); export type ClientRequest__CancelLoginAccountParams = { readonly loginId: string };export const ClientRequest__CancelLoginAccountParams = Schema.Struct({ loginId: Schema.String }); export type ClientRequest__ClientInfo = { readonly name: string; readonly title?: string | null; readonly version: string;};export const ClientRequest__ClientInfo = Schema.Struct({ name: Schema.String, title: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), version: Schema.String,}); export type ClientRequest__CommandExecResizeParams = { readonly processId: string; readonly size: { readonly cols: number; readonly rows: number };};export const ClientRequest__CommandExecResizeParams = Schema.Struct({ processId: Schema.String.annotate({ description: "Client-supplied, connection-scoped `processId` from the original `command/exec` request.", }), size: Schema.Struct({ cols: Schema.Number.annotate({ description: "Terminal width in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), rows: Schema.Number.annotate({ description: "Terminal height in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), }).annotate({ description: "PTY size in character cells for `command/exec` PTY sessions." }),}).annotate({ description: "Resize a running PTY-backed `command/exec` session." }); export type ClientRequest__CommandExecTerminalSize = { readonly cols: number; readonly rows: number;};export const ClientRequest__CommandExecTerminalSize = Schema.Struct({ cols: Schema.Number.annotate({ description: "Terminal width in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), rows: Schema.Number.annotate({ description: "Terminal height in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)),}).annotate({ description: "PTY size in character cells for `command/exec` PTY sessions." }); export type ClientRequest__CommandExecTerminateParams = { readonly processId: string };export const ClientRequest__CommandExecTerminateParams = Schema.Struct({ processId: Schema.String.annotate({ description: "Client-supplied, connection-scoped `processId` from the original `command/exec` request.", }),}).annotate({ description: "Terminate a running `command/exec` session." }); export type ClientRequest__CommandExecWriteParams = { readonly closeStdin?: boolean; readonly deltaBase64?: string | null; readonly processId: string;};export const ClientRequest__CommandExecWriteParams = Schema.Struct({ closeStdin: Schema.optionalKey( Schema.Boolean.annotate({ description: "Close stdin after writing `deltaBase64`, if present.", }), ), deltaBase64: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional base64-encoded stdin bytes to write." }), Schema.Null, ]), ), processId: Schema.String.annotate({ description: "Client-supplied, connection-scoped `processId` from the original `command/exec` request.", }),}).annotate({ description: "Write stdin bytes to a running `command/exec` session, close stdin, or both.",}); export type ClientRequest__CommandMigration = { readonly name: string };export const ClientRequest__CommandMigration = Schema.Struct({ name: Schema.String }); export type ClientRequest__ConfigReadParams = { readonly cwd?: string | null; readonly includeLayers?: boolean;};export const ClientRequest__ConfigReadParams = Schema.Struct({ cwd: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional working directory to resolve project config layers. If specified, return the effective config as seen from that directory (i.e., including any project layers between `cwd` and the project/repo root).", }), Schema.Null, ]), ), includeLayers: Schema.optionalKey(Schema.Boolean),}); export type ClientRequest__ConsumeAccountRateLimitResetCreditParams = { readonly creditId?: string | null; readonly idempotencyKey: string;};export const ClientRequest__ConsumeAccountRateLimitResetCreditParams = Schema.Struct({ creditId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Opaque reset-credit identifier to redeem. When omitted, the backend selects the next available credit.", }), Schema.Null, ]), ), idempotencyKey: Schema.String.annotate({ description: "Identifies one logical reset attempt. A UUID is recommended; reuse the same value when retrying that attempt.", }),}); export type ClientRequest__ConversationTextRole = "user" | "developer" | "assistant";export const ClientRequest__ConversationTextRole = Schema.Literals([ "user", "developer", "assistant",]); export type ClientRequest__DynamicToolNamespaceTool = { readonly deferLoading?: boolean; readonly description: string; readonly inputSchema: unknown; readonly name: string; readonly type: "function";};export const ClientRequest__DynamicToolNamespaceTool = Schema.Union( [ Schema.Struct({ deferLoading: Schema.optionalKey(Schema.Boolean), description: Schema.String, inputSchema: Schema.Unknown, name: Schema.String, type: Schema.Literal("function").annotate({ title: "FunctionDynamicToolNamespaceToolType" }), }).annotate({ title: "FunctionDynamicToolNamespaceTool" }), ], { mode: "oneOf" },); export type ClientRequest__ExperimentalFeatureEnablementSetParams = { readonly enablement: { readonly [x: string]: boolean };};export const ClientRequest__ExperimentalFeatureEnablementSetParams = Schema.Struct({ enablement: Schema.Record(Schema.String, Schema.Boolean).annotate({ description: "Process-wide runtime feature enablement keyed by canonical feature name.\n\nOnly named features are updated. Omitted features are left unchanged. Send an empty map for a no-op.", }),}); export type ClientRequest__ExperimentalFeatureListParams = { readonly cursor?: string | null; readonly limit?: number | null; readonly threadId?: string | null;};export const ClientRequest__ExperimentalFeatureListParams = Schema.Struct({ cursor: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Opaque pagination cursor returned by a previous call.", }), Schema.Null, ]), ), limit: Schema.optionalKey( Schema.Union([ Schema.Number.annotate({ description: "Optional page size; defaults to a reasonable server-side value.", format: "uint32", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), Schema.Null, ]), ), threadId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional loaded thread id. Pass this when showing feature state for an existing thread so enablement is computed from that thread's refreshed config, including project-local config for the thread's cwd.", }), Schema.Null, ]), ),}); export type ClientRequest__ExternalAgentConfigDetectParams = { readonly cwds?: ReadonlyArray<string> | null; readonly includeHome?: boolean; readonly migrationSource?: string | null; readonly source?: string | null;};export const ClientRequest__ExternalAgentConfigDetectParams = Schema.Struct({ cwds: Schema.optionalKey( Schema.Union([ Schema.Array(Schema.String).annotate({ description: "Zero or more working directories to include for repo-scoped detection.", }), Schema.Null, ]), ), includeHome: Schema.optionalKey( Schema.Boolean.annotate({ description: "If true, include detection under the user's home directory.", }), ), migrationSource: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional migration-source selector. Missing or unrecognized values use the default source.", }), Schema.Null, ]), ), source: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Deprecated field retained for compatibility. This field is ignored; use `migrationSource` to select the migration source.", }), Schema.Null, ]), ),}); export type ClientRequest__ExternalAgentConfigMigrationItemType = | "AGENTS_MD" | "CONFIG" | "SKILLS" | "PLUGINS" | "MCP_SERVER_CONFIG" | "SUBAGENTS" | "HOOKS" | "COMMANDS" | "MEMORY" | "SESSIONS";export const ClientRequest__ExternalAgentConfigMigrationItemType = Schema.Literals([ "AGENTS_MD", "CONFIG", "SKILLS", "PLUGINS", "MCP_SERVER_CONFIG", "SUBAGENTS", "HOOKS", "COMMANDS", "MEMORY", "SESSIONS",]); export type ClientRequest__FeedbackUploadParams = { readonly classification: string; readonly extraLogFiles?: ReadonlyArray<string> | null; readonly includeLogs?: boolean; readonly reason?: string | null; readonly tags?: { readonly [x: string]: string } | null; readonly threadId?: string | null;};export const ClientRequest__FeedbackUploadParams = Schema.Struct({ classification: Schema.String, extraLogFiles: Schema.optionalKey(Schema.Union([Schema.Array(Schema.String), Schema.Null])), includeLogs: Schema.optionalKey(Schema.Boolean), reason: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), tags: Schema.optionalKey( Schema.Union([Schema.Record(Schema.String, Schema.String), Schema.Null]), ), threadId: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])),}); export type ClientRequest__FsCopyParams = { readonly destinationPath: string; readonly recursive?: boolean; readonly sourcePath: string;};export const ClientRequest__FsCopyParams = Schema.Struct({ destinationPath: Schema.String.annotate({ description: "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.", }), recursive: Schema.optionalKey( Schema.Boolean.annotate({ description: "Required for directory copies; ignored for file copies.", }), ), sourcePath: Schema.String.annotate({ description: "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.", }),}).annotate({ description: "Copy a file or directory tree on the host filesystem." });Lines 1–500 of 43644. Load more
// This file is generated by the effect-codex-app-server package. Do not edit manually. // Upstream protocol ref: 678157acaa819d5510adfe359abb5d0392cfe461 import * as Schema from "effect/Schema"; export type ApplyPatchApprovalParams__FileChange = | { readonly content: string; readonly type: "add" } | { readonly content: string; readonly type: "delete" } | { readonly move_path?: string | null; readonly type: "update"; readonly unified_diff: string }; export const ApplyPatchApprovalParams__FileChange = Schema.Union( [ Schema.Struct({ content: Schema.String, type: Schema.Literal("add").annotate({ title: "AddFileChangeType" }), }).annotate({ title: "AddFileChange" }), Schema.Struct({ content: Schema.String, type: Schema.Literal("delete").annotate({ title: "DeleteFileChangeType" }), }).annotate({ title: "DeleteFileChange" }), Schema.Struct({ move_path: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), type: Schema.Literal("update").annotate({ title: "UpdateFileChangeType" }), unified_diff: Schema.String, }).annotate({ title: "UpdateFileChange" }), ], { mode: "oneOf" }, ); export type ApplyPatchApprovalParams__ThreadId = string; export const ApplyPatchApprovalParams__ThreadId = Schema.String; export type ApplyPatchApprovalResponse__NetworkPolicyRuleAction = "allow" | "deny"; export const ApplyPatchApprovalResponse__NetworkPolicyRuleAction = Schema.Literals([ "allow", "deny", ]); export type ChatgptAuthTokensRefreshParams__ChatgptAuthTokensRefreshReason = "unauthorized"; export const ChatgptAuthTokensRefreshParams__ChatgptAuthTokensRefreshReason = Schema.Literal("unauthorized"); export type ClientRequest__AbsolutePathBuf = string; export const ClientRequest__AbsolutePathBuf = Schema.String.annotate({ description: "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.", }); export type ClientRequest__AddCreditsNudgeCreditType = "credits" | "usage_limit"; export const ClientRequest__AddCreditsNudgeCreditType = Schema.Literals(["credits", "usage_limit"]); export type ClientRequest__AdditionalContextKind = "untrusted" | "application"; export const ClientRequest__AdditionalContextKind = Schema.Literals(["untrusted", "application"]); export type ClientRequest__AgentMessageInputContent = | { readonly text: string; readonly type: "input_text" } | { readonly encrypted_content: string; readonly type: "encrypted_content" }; export const ClientRequest__AgentMessageInputContent = Schema.Union( [ Schema.Struct({ text: Schema.String, type: Schema.Literal("input_text").annotate({ title: "InputTextAgentMessageInputContentType", }), }).annotate({ title: "InputTextAgentMessageInputContent" }), Schema.Struct({ encrypted_content: Schema.String, type: Schema.Literal("encrypted_content").annotate({ title: "EncryptedContentAgentMessageInputContentType", }), }).annotate({ title: "EncryptedContentAgentMessageInputContent" }), ], { mode: "oneOf" }, ); export type ClientRequest__ApprovalsReviewer = "user" | "auto_review" | "guardian_subagent"; export const ClientRequest__ApprovalsReviewer = Schema.Literals([ "user", "auto_review", "guardian_subagent", ]).annotate({ description: "Configures who approval requests are routed to for review. Examples include sandbox escapes, blocked network access, MCP approval prompts, and ARC escalations. Defaults to `user`. `auto_review` uses a carefully prompted subagent to gather relevant context and apply a risk-based decision framework before approving or denying the request. The legacy value `guardian_subagent` is accepted for compatibility.", }); export type ClientRequest__AppsInstalledParams = { readonly forceRefresh?: boolean; readonly threadId?: string | null; }; export const ClientRequest__AppsInstalledParams = Schema.Struct({ forceRefresh: Schema.optionalKey( Schema.Boolean.annotate({ description: "When true and Apps are permitted, refresh and publish the hosted connector runtime tool snapshot first.", }), ), threadId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional loaded thread id used to evaluate effective app configuration.", }), Schema.Null, ]), ), }).annotate({ description: "Read the committed installed connector runtime snapshot." }); export type ClientRequest__AppsListParams = { readonly cursor?: string | null; readonly forceRefetch?: boolean; readonly limit?: number | null; readonly threadId?: string | null; }; export const ClientRequest__AppsListParams = Schema.Struct({ cursor: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Opaque pagination cursor returned by a previous call.", }), Schema.Null, ]), ), forceRefetch: Schema.optionalKey( Schema.Boolean.annotate({ description: "When true, bypass app caches and fetch the latest data from sources.", }), ), limit: Schema.optionalKey( Schema.Union([ Schema.Number.annotate({ description: "Optional page size; defaults to a reasonable server-side value.", format: "uint32", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), Schema.Null, ]), ), threadId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional thread id used to evaluate app feature gating from that thread's config.", }), Schema.Null, ]), ), }).annotate({ description: "EXPERIMENTAL - list available apps/connectors." }); export type ClientRequest__AppsReadParams = { readonly appIds: ReadonlyArray<string>; readonly includeTools?: boolean; }; export const ClientRequest__AppsReadParams = Schema.Struct({ appIds: Schema.Array(Schema.String).annotate({ description: "App ids to read. The server accepts at most 100 ids and deduplicates repeated ids while preserving their first-request order.", }), includeTools: Schema.optionalKey( Schema.Boolean.annotate({ description: "When true, include display-only public tool summaries in the returned metadata.", }), ), }).annotate({ description: "EXPERIMENTAL - read metadata for specific apps/connectors." }); export type ClientRequest__AskForApproval = | "untrusted" | "on-request" | "never" | { readonly granular: { readonly mcp_elicitations: boolean; readonly request_permissions?: boolean; readonly rules: boolean; readonly sandbox_approval: boolean; readonly skill_approval?: boolean; }; }; export const ClientRequest__AskForApproval = Schema.Union( [ Schema.Literals(["untrusted", "on-request", "never"]), Schema.Struct({ granular: Schema.Struct({ mcp_elicitations: Schema.Boolean, request_permissions: Schema.optionalKey(Schema.Boolean.annotate({ default: false })), rules: Schema.Boolean, sandbox_approval: Schema.Boolean, skill_approval: Schema.optionalKey(Schema.Boolean.annotate({ default: false })), }), }).annotate({ title: "GranularAskForApproval" }), ], { mode: "oneOf" }, ); export type ClientRequest__CancelLoginAccountParams = { readonly loginId: string }; export const ClientRequest__CancelLoginAccountParams = Schema.Struct({ loginId: Schema.String }); export type ClientRequest__ClientInfo = { readonly name: string; readonly title?: string | null; readonly version: string; }; export const ClientRequest__ClientInfo = Schema.Struct({ name: Schema.String, title: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), version: Schema.String, }); export type ClientRequest__CommandExecResizeParams = { readonly processId: string; readonly size: { readonly cols: number; readonly rows: number }; }; export const ClientRequest__CommandExecResizeParams = Schema.Struct({ processId: Schema.String.annotate({ description: "Client-supplied, connection-scoped `processId` from the original `command/exec` request.", }), size: Schema.Struct({ cols: Schema.Number.annotate({ description: "Terminal width in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), rows: Schema.Number.annotate({ description: "Terminal height in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), }).annotate({ description: "PTY size in character cells for `command/exec` PTY sessions." }), }).annotate({ description: "Resize a running PTY-backed `command/exec` session." }); export type ClientRequest__CommandExecTerminalSize = { readonly cols: number; readonly rows: number; }; export const ClientRequest__CommandExecTerminalSize = Schema.Struct({ cols: Schema.Number.annotate({ description: "Terminal width in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), rows: Schema.Number.annotate({ description: "Terminal height in character cells.", format: "uint16", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), }).annotate({ description: "PTY size in character cells for `command/exec` PTY sessions." }); export type ClientRequest__CommandExecTerminateParams = { readonly processId: string }; export const ClientRequest__CommandExecTerminateParams = Schema.Struct({ processId: Schema.String.annotate({ description: "Client-supplied, connection-scoped `processId` from the original `command/exec` request.", }), }).annotate({ description: "Terminate a running `command/exec` session." }); export type ClientRequest__CommandExecWriteParams = { readonly closeStdin?: boolean; readonly deltaBase64?: string | null; readonly processId: string; }; export const ClientRequest__CommandExecWriteParams = Schema.Struct({ closeStdin: Schema.optionalKey( Schema.Boolean.annotate({ description: "Close stdin after writing `deltaBase64`, if present.", }), ), deltaBase64: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional base64-encoded stdin bytes to write." }), Schema.Null, ]), ), processId: Schema.String.annotate({ description: "Client-supplied, connection-scoped `processId` from the original `command/exec` request.", }), }).annotate({ description: "Write stdin bytes to a running `command/exec` session, close stdin, or both.", }); export type ClientRequest__CommandMigration = { readonly name: string }; export const ClientRequest__CommandMigration = Schema.Struct({ name: Schema.String }); export type ClientRequest__ConfigReadParams = { readonly cwd?: string | null; readonly includeLayers?: boolean; }; export const ClientRequest__ConfigReadParams = Schema.Struct({ cwd: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional working directory to resolve project config layers. If specified, return the effective config as seen from that directory (i.e., including any project layers between `cwd` and the project/repo root).", }), Schema.Null, ]), ), includeLayers: Schema.optionalKey(Schema.Boolean), }); export type ClientRequest__ConsumeAccountRateLimitResetCreditParams = { readonly creditId?: string | null; readonly idempotencyKey: string; }; export const ClientRequest__ConsumeAccountRateLimitResetCreditParams = Schema.Struct({ creditId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Opaque reset-credit identifier to redeem. When omitted, the backend selects the next available credit.", }), Schema.Null, ]), ), idempotencyKey: Schema.String.annotate({ description: "Identifies one logical reset attempt. A UUID is recommended; reuse the same value when retrying that attempt.", }), }); export type ClientRequest__ConversationTextRole = "user" | "developer" | "assistant"; export const ClientRequest__ConversationTextRole = Schema.Literals([ "user", "developer", "assistant", ]); export type ClientRequest__DynamicToolNamespaceTool = { readonly deferLoading?: boolean; readonly description: string; readonly inputSchema: unknown; readonly name: string; readonly type: "function"; }; export const ClientRequest__DynamicToolNamespaceTool = Schema.Union( [ Schema.Struct({ deferLoading: Schema.optionalKey(Schema.Boolean), description: Schema.String, inputSchema: Schema.Unknown, name: Schema.String, type: Schema.Literal("function").annotate({ title: "FunctionDynamicToolNamespaceToolType" }), }).annotate({ title: "FunctionDynamicToolNamespaceTool" }), ], { mode: "oneOf" }, ); export type ClientRequest__ExperimentalFeatureEnablementSetParams = { readonly enablement: { readonly [x: string]: boolean }; }; export const ClientRequest__ExperimentalFeatureEnablementSetParams = Schema.Struct({ enablement: Schema.Record(Schema.String, Schema.Boolean).annotate({ description: "Process-wide runtime feature enablement keyed by canonical feature name.\n\nOnly named features are updated. Omitted features are left unchanged. Send an empty map for a no-op.", }), }); export type ClientRequest__ExperimentalFeatureListParams = { readonly cursor?: string | null; readonly limit?: number | null; readonly threadId?: string | null; }; export const ClientRequest__ExperimentalFeatureListParams = Schema.Struct({ cursor: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Opaque pagination cursor returned by a previous call.", }), Schema.Null, ]), ), limit: Schema.optionalKey( Schema.Union([ Schema.Number.annotate({ description: "Optional page size; defaults to a reasonable server-side value.", format: "uint32", }) .check(Schema.isInt()) .check(Schema.isGreaterThanOrEqualTo(0)), Schema.Null, ]), ), threadId: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional loaded thread id. Pass this when showing feature state for an existing thread so enablement is computed from that thread's refreshed config, including project-local config for the thread's cwd.", }), Schema.Null, ]), ), }); export type ClientRequest__ExternalAgentConfigDetectParams = { readonly cwds?: ReadonlyArray<string> | null; readonly includeHome?: boolean; readonly migrationSource?: string | null; readonly source?: string | null; }; export const ClientRequest__ExternalAgentConfigDetectParams = Schema.Struct({ cwds: Schema.optionalKey( Schema.Union([ Schema.Array(Schema.String).annotate({ description: "Zero or more working directories to include for repo-scoped detection.", }), Schema.Null, ]), ), includeHome: Schema.optionalKey( Schema.Boolean.annotate({ description: "If true, include detection under the user's home directory.", }), ), migrationSource: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Optional migration-source selector. Missing or unrecognized values use the default source.", }), Schema.Null, ]), ), source: Schema.optionalKey( Schema.Union([ Schema.String.annotate({ description: "Deprecated field retained for compatibility. This field is ignored; use `migrationSource` to select the migration source.", }), Schema.Null, ]), ), }); export type ClientRequest__ExternalAgentConfigMigrationItemType = | "AGENTS_MD" | "CONFIG" | "SKILLS" | "PLUGINS" | "MCP_SERVER_CONFIG" | "SUBAGENTS" | "HOOKS" | "COMMANDS" | "MEMORY" | "SESSIONS"; export const ClientRequest__ExternalAgentConfigMigrationItemType = Schema.Literals([ "AGENTS_MD", "CONFIG", "SKILLS", "PLUGINS", "MCP_SERVER_CONFIG", "SUBAGENTS", "HOOKS", "COMMANDS", "MEMORY", "SESSIONS", ]); export type ClientRequest__FeedbackUploadParams = { readonly classification: string; readonly extraLogFiles?: ReadonlyArray<string> | null; readonly includeLogs?: boolean; readonly reason?: string | null; readonly tags?: { readonly [x: string]: string } | null; readonly threadId?: string | null; }; export const ClientRequest__FeedbackUploadParams = Schema.Struct({ classification: Schema.String, extraLogFiles: Schema.optionalKey(Schema.Union([Schema.Array(Schema.String), Schema.Null])), includeLogs: Schema.optionalKey(Schema.Boolean), reason: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), tags: Schema.optionalKey( Schema.Union([Schema.Record(Schema.String, Schema.String), Schema.Null]), ), threadId: Schema.optionalKey(Schema.Union([Schema.String, Schema.Null])), }); export type ClientRequest__FsCopyParams = { readonly destinationPath: string; readonly recursive?: boolean; readonly sourcePath: string; }; export const ClientRequest__FsCopyParams = Schema.Struct({ destinationPath: Schema.String.annotate({ description: "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.", }), recursive: Schema.optionalKey( Schema.Boolean.annotate({ description: "Required for directory copies; ignored for file copies.", }), ), sourcePath: Schema.String.annotate({ description: "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.", }), }).annotate({ description: "Copy a file or directory tree on the host filesystem." });