// GENERATED CODE! DO NOT MODIFY BY HAND!

// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
import type { AbsolutePathBuf } from "../AbsolutePathBuf";
import type { CollaborationMode } from "../CollaborationMode";
import type { MultiAgentMode } from "../MultiAgentMode";
import type { Personality } from "../Personality";
import type { ReasoningEffort } from "../ReasoningEffort";
import type { ReasoningSummary } from "../ReasoningSummary";
import type { JsonValue } from "../serde_json/JsonValue";
import type { AdditionalContextEntry } from "./AdditionalContextEntry";
import type { ApprovalsReviewer } from "./ApprovalsReviewer";
import type { AskForApproval } from "./AskForApproval";
import type { SandboxPolicy } from "./SandboxPolicy";
import type { TurnEnvironmentParams } from "./TurnEnvironmentParams";
import type { UserInput } from "./UserInput";

export type TurnStartParams = { threadId: string, clientUserMessageId?: string | null, input: Array<UserInput>,
/**
 * Optional metadata to enrich Codex's ResponsesAPI turn metadata.
 *
 * Entries are flattened into the JSON string sent as
 * `client_metadata["x-codex-turn-metadata"]` on ResponsesAPI HTTP and websocket requests.
 *
 * They are not sent as top-level ResponsesAPI `client_metadata` keys, and reserved keys
 * such as `session_id`, `thread_id`, `turn_id`, and `window_id` cannot be overridden.
 */
responsesapiClientMetadata?: { [key in string]?: string } | null,
/**
 * Optional client-provided context fragments keyed by an opaque source identifier.
 */
additionalContext?: { [key in string]?: AdditionalContextEntry } | null,
/**
 * Optional environments for this turn and subsequent turns.
 *
 * Omitted uses the thread sticky environments. Empty disables
 * environment access for this turn. Non-empty selects the first
 * environment as the current turn environment for this turn.
 */
environments?: Array<TurnEnvironmentParams> | null,
/**
 * Override the working directory for this turn and subsequent turns.
 */
cwd?: string | null,
/**
 * Replace the thread's runtime workspace roots for this turn and
 * subsequent turns. Paths must be absolute.
 */
runtimeWorkspaceRoots?: Array<AbsolutePathBuf> | null,
/**
 * Override the approval policy for this turn and subsequent turns.
 */
approvalPolicy?: AskForApproval | null,
/**
 * Override where approval requests are routed for review on this turn and
 * subsequent turns.
 */
approvalsReviewer?: ApprovalsReviewer | null,
/**
 * Override the sandbox policy for this turn and subsequent turns.
 */
sandboxPolicy?: SandboxPolicy | null,
/**
 * Select a named permissions profile id for this turn and subsequent
 * turns. Cannot be combined with `sandboxPolicy`.
 */
permissions?: string | null,
/**
 * Override the model for this turn and subsequent turns.
 */
model?: string | null,
/**
 * Override the service tier for this turn and subsequent turns.
 */
serviceTier?: string | null | null,
/**
 * Override the reasoning effort for this turn and subsequent turns.
 */
effort?: ReasoningEffort | null,
/**
 * Override the reasoning summary for this turn and subsequent turns.
 */
summary?: ReasoningSummary | null,
/**
 * Override the personality for this turn and subsequent turns.
 */
personality?: Personality | null,
/**
 * Optional JSON Schema used to constrain the final assistant message for
 * this turn.
 */
outputSchema?: JsonValue | null,
/**
 * EXPERIMENTAL - Set a pre-set collaboration mode.
 * Takes precedence over model, reasoning_effort, and developer instructions if set.
 *
 * For `collaboration_mode.settings.developer_instructions`, `null` means
 * "use the built-in instructions for the selected mode".
 */
collaborationMode?: CollaborationMode | null,
/**
 * @deprecated Ignored. Use `effort: "ultra"` for proactive multi-agent behavior.
 */
multiAgentMode?: MultiAgentMode | null, };
