import type { TDefaultLLMDeliveryPath, TDefaultLLMDeliveryPathConfig } from './file-config'; import type { EndpointFileConfig, FileConfig } from './types/files'; export declare const SYSTEM_LLM_DELIVERY_DEFAULTS: Required; export declare function isNativelyReadableText(mimeType: string): boolean; export declare function hasTextExtractionPath(mimeType: string): boolean; /** * Resolves the default file path destination for a given mime type. * Resolution chain: endpoint overrides -> endpoint fallback -> global overrides -> global fallback -> system defaults. */ export declare function resolveDefaultLLMDeliveryPath(mimeType: string, endpointConfig?: TDefaultLLMDeliveryPathConfig, globalConfig?: TDefaultLLMDeliveryPathConfig, endpoint?: string, useResponsesApi?: boolean, sttConfigured?: boolean): TDefaultLLMDeliveryPath; /** * Delivery path for an upload that named no tool resource. The legacy chooser makes the * destination explicit, so nothing is inferred there. */ export declare function resolveDefaultUploadLLMDeliveryPath({ mimeType, endpointConfig, fileConfig, endpoint, useResponsesApi, sttConfigured, }: { mimeType: string; endpointConfig?: EndpointFileConfig; fileConfig?: FileConfig; endpoint?: string; useResponsesApi?: boolean; sttConfigured?: boolean; }): TDefaultLLMDeliveryPath; /** Delivery path for an upload, honoring an explicitly chosen tool resource. */ export declare function resolveUploadLLMDeliveryPath({ toolResource, mimeType, endpointConfig, fileConfig, endpoint, useResponsesApi, sttConfigured, }: { toolResource?: string | null; mimeType: string; endpointConfig?: EndpointFileConfig; fileConfig?: FileConfig; endpoint?: string; useResponsesApi?: boolean; sttConfigured?: boolean; }): TDefaultLLMDeliveryPath; /** * Whether a file tool can do anything with this type. `file_search` indexes extracted * text, so it needs a type some step can turn into text and cannot use media, whose * extraction paths are OCR and speech rather than the vector store. Code execution is * judged by the list the client offers it from. Shared by upload-time selection and * deferred provisioning so the two cannot queue a file the other would refuse. */ export declare function canToolResourceConsume(toolResource: string, mimeType: string): boolean; /** Why an upload cannot be accepted, when nothing would be able to read it. */ export type UploadRejection = 'no-agent-resource' | 'context-disabled' | 'no-consumer'; /** * Where a unified upload will end up, and whether it can be accepted at all. * * An upload has to be readable by something: the model, an extraction step, or a file * tool. A permanent one has to land on an agent resource too, or storing it succeeds * while leaving the agent no reference to it. Both outcomes are decided here rather than * discovered later, so a request that would change nothing is refused with a reason. * * `agentTools` is undefined when no agent record backs the upload, as for an ephemeral * agent that exists only for the request. An unknown tool set is not judged. */ export declare function resolveUploadDestination(params: { toolResource?: string | null; deliveryPath: TDefaultLLMDeliveryPath; mimeType: string; agentTools?: string[]; hasAgent: boolean; isMessageAttachment: boolean; /** True when a message attachment may acquire a compatible tool on a later turn. */ allowUnknownMessageConsumer?: boolean; /** Undefined when not looked up, as for an upload that cannot land on context. */ contextEnabled?: boolean; }): { toolResource?: string; rejection?: UploadRejection; };