import { Journal } from "./journal.cjs"; import { ChatCompletionRequest, Fixture, HandlerDefaults } from "./types.cjs"; import * as http$1 from "node:http"; //#region src/gemini-interactions.d.ts interface InteractionsContentBlock { type: string; text?: string; name?: string; call_id?: string; id?: string; arguments?: Record; output?: unknown; result?: unknown; } interface InteractionsTurn { role: string; content?: InteractionsContentBlock[]; parts?: InteractionsContentBlock[]; } /** * Top-level Step envelope accepted by the live Gemini Interactions API. * The SDK's TypeScript union does not include Step[], but the wire contract * does — clients following the live API send these at the top level of `input`. * Discriminated by `type`; no `role` field (distinguishes from Turn[]). */ interface InteractionsStep { type: string; content?: InteractionsContentBlock[]; call_id?: string; id?: string; name?: string; result?: unknown; output?: unknown; is_error?: boolean; signature?: string; } interface InteractionsFunctionTool { type: "function"; name: string; description?: string; parameters?: object; } interface InteractionsRequest { model?: string; input?: string | InteractionsTurn[] | InteractionsStep[] | InteractionsContentBlock[]; system_instruction?: string; tools?: InteractionsFunctionTool[]; generation_config?: { temperature?: number; max_output_tokens?: number; [key: string]: unknown; }; stream?: boolean; previous_interaction_id?: string; [key: string]: unknown; } declare function geminiInteractionsToCompletionRequest(req: InteractionsRequest): ChatCompletionRequest; declare function handleGeminiInteractions(req: http$1.IncomingMessage, res: http$1.ServerResponse, raw: string, fixtures: Fixture[], journal: Journal, defaults: HandlerDefaults, setCorsHeaders: (res: http$1.ServerResponse) => void): Promise; //#endregion export { geminiInteractionsToCompletionRequest, handleGeminiInteractions }; //# sourceMappingURL=gemini-interactions.d.cts.map