import { type SecretRequestDelivery, type SecretRequestField, type SecretRequestView } from '@xopcai/gateway-contract'; import { type SessionInput } from './session-input-repository.js'; export type SecretRequestRecord = { view: SecretRequestView; principalId: string; transcriptId: string; }; export type CreateSecretRequestInput = { conversationId: string; runId: string; toolCallId: string; label: string; reason: string; url?: string; placeholder?: string; delivery: SecretRequestDelivery; fields?: SecretRequestField[]; supportsReference: boolean; principalId?: string; expiresAt?: number; now?: number; }; export type ResolveSecretRequestInput = { requestId: string; status: 'saved' | 'declined'; deliveryResult?: { ref?: string; file?: string; files?: Record; }; now?: number; }; export type ResolveSecretRequestResult = { ok: true; request: SecretRequestView; resumeInputId: string; } | { ok: false; reason: 'not_found' | 'already_answered' | 'agent_stopped'; }; export declare function getSecretRequest(requestId: string): SecretRequestRecord | undefined; export declare function listSecretRequests(conversationId: string): SecretRequestView[]; export declare function isSecretRequestSuspended(conversationId: string, runId: string): boolean; export declare function createSecretRequest(input: CreateSecretRequestInput): SecretRequestView; export declare function resolveSecretRequest(input: ResolveSecretRequestInput): ResolveSecretRequestResult; export declare function getSecretResumeInput(conversationId: string, runId: string): SessionInput | undefined; export declare function consumeSecretResume(input: SessionInput): boolean; export declare function cancelActiveSecretRequests(conversationId: string, runId?: string, now?: number): SecretRequestView[];