import * as z from "zod/v4"; import { ClosedEnum, OpenEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import * as models from "../index.js"; export type GetModelsGlobals = { /** * The app identifier should be your app's URL and is used as the primary identifier for rankings. * * @remarks * This is used to track API usage per application. */ httpReferer?: string | undefined; /** * The app display name allows you to customize how your app appears in OpenRouter's dashboard. * * @remarks */ appTitle?: string | undefined; /** * Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings. * * @remarks */ appCategories?: string | undefined; }; /** * Filter models by use case category */ export declare const GetModelsCategory: { readonly Programming: "programming"; readonly Roleplay: "roleplay"; readonly Marketing: "marketing"; readonly MarketingSeo: "marketing/seo"; readonly Technology: "technology"; readonly Science: "science"; readonly Translation: "translation"; readonly Legal: "legal"; readonly Finance: "finance"; readonly Health: "health"; readonly Trivia: "trivia"; readonly Academia: "academia"; }; /** * Filter models by use case category */ export type GetModelsCategory = OpenEnum; /** * Sort the returned models server-side. Prefer this over fetching the full list and sorting client-side. Options: pricing-low-to-high, pricing-high-to-low (average prompt/completion price), context-high-to-low (context length), throughput-high-to-low, latency-low-to-high (recent median performance), most-popular, top-weekly (tokens processed in the last week), newest (creation date), intelligence-high-to-low, coding-high-to-low, agentic-high-to-low (Artificial Analysis indices), design-arena-elo-high-to-low (best Design Arena ELO across arenas). Models without a score for the chosen benchmark are placed last. When omitted, the existing default ordering is preserved. */ export declare const GetModelsSort: { readonly MostPopular: "most-popular"; readonly Newest: "newest"; readonly TopWeekly: "top-weekly"; readonly PricingLowToHigh: "pricing-low-to-high"; readonly PricingHighToLow: "pricing-high-to-low"; readonly ContextHighToLow: "context-high-to-low"; readonly ThroughputHighToLow: "throughput-high-to-low"; readonly LatencyLowToHigh: "latency-low-to-high"; readonly IntelligenceHighToLow: "intelligence-high-to-low"; readonly CodingHighToLow: "coding-high-to-low"; readonly AgenticHighToLow: "agentic-high-to-low"; readonly DesignArenaEloHighToLow: "design-arena-elo-high-to-low"; }; /** * Sort the returned models server-side. Prefer this over fetching the full list and sorting client-side. Options: pricing-low-to-high, pricing-high-to-low (average prompt/completion price), context-high-to-low (context length), throughput-high-to-low, latency-low-to-high (recent median performance), most-popular, top-weekly (tokens processed in the last week), newest (creation date), intelligence-high-to-low, coding-high-to-low, agentic-high-to-low (Artificial Analysis indices), design-arena-elo-high-to-low (best Design Arena ELO across arenas). Models without a score for the chosen benchmark are placed last. When omitted, the existing default ordering is preserved. */ export type GetModelsSort = OpenEnum; /** * Filter by distillation capability. "true" returns only distillable models, "false" excludes them. */ export declare const Distillable: { readonly True: "true"; readonly False: "false"; }; /** * Filter by distillation capability. "true" returns only distillable models, "false" excludes them. */ export type Distillable = OpenEnum; /** * When set to "true", return only models with zero data retention endpoints. */ export declare const Zdr: { readonly True: "true"; }; /** * When set to "true", return only models with zero data retention endpoints. */ export type Zdr = ClosedEnum; /** * Filter to models with endpoints in the given data region ("eu" or "us"). */ export declare const Region: { readonly Eu: "eu"; readonly Us: "us"; }; /** * Filter to models with endpoints in the given data region ("eu" or "us"). */ export type Region = OpenEnum; export type GetModelsRequest = { /** * The app identifier should be your app's URL and is used as the primary identifier for rankings. * * @remarks * This is used to track API usage per application. */ httpReferer?: string | undefined; /** * The app display name allows you to customize how your app appears in OpenRouter's dashboard. * * @remarks */ appTitle?: string | undefined; /** * Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings. * * @remarks */ appCategories?: string | undefined; /** * Number of records to skip for pagination. When both offset and limit are omitted, the full list is returned */ offset?: number | null | undefined; /** * Maximum number of records to return (max 1000). When both offset and limit are omitted, the full list is returned */ limit?: number | undefined; /** * Filter models by use case category */ category?: GetModelsCategory | undefined; /** * Filter models by supported parameter (comma-separated) */ supportedParameters?: string | undefined; /** * Filter models by output modality. Accepts a comma-separated list of modalities (text, image, embeddings, audio, video, rerank, decisions, speech, transcription) or "all" to include all models. Defaults to "text". */ outputModalities?: string | undefined; /** * Sort the returned models server-side. Prefer this over fetching the full list and sorting client-side. Options: pricing-low-to-high, pricing-high-to-low (average prompt/completion price), context-high-to-low (context length), throughput-high-to-low, latency-low-to-high (recent median performance), most-popular, top-weekly (tokens processed in the last week), newest (creation date), intelligence-high-to-low, coding-high-to-low, agentic-high-to-low (Artificial Analysis indices), design-arena-elo-high-to-low (best Design Arena ELO across arenas). Models without a score for the chosen benchmark are placed last. When omitted, the existing default ordering is preserved. */ sort?: GetModelsSort | undefined; /** * Free-text search by model name or slug. */ q?: string | undefined; /** * Filter models by input modality. Comma-separated list of: text, image, audio, file. */ inputModalities?: string | undefined; /** * Minimum context length (tokens). Models with smaller context are excluded. */ context?: number | undefined; /** * Minimum prompt price in $/M tokens. */ minPrice?: number | null | undefined; /** * Maximum prompt price in $/M tokens. */ maxPrice?: number | null | undefined; /** * Filter models by architecture/model family (e.g. GPT, Claude, Gemini, Llama). */ arch?: string | undefined; /** * Filter models by the organization that created the model. Comma-separated list of author slugs. */ modelAuthors?: string | undefined; /** * Filter models by hosting provider. Comma-separated list of provider names. */ providers?: string | undefined; /** * Filter by distillation capability. "true" returns only distillable models, "false" excludes them. */ distillable?: Distillable | undefined; /** * When set to "true", return only models with zero data retention endpoints. */ zdr?: Zdr | undefined; /** * Filter to models with endpoints in the given data region ("eu" or "us"). */ region?: Region | undefined; /** * Minimum completion (output) price in $/M tokens. */ minOutputPrice?: number | null | undefined; /** * Maximum completion (output) price in $/M tokens. */ maxOutputPrice?: number | null | undefined; /** * Minimum model age in days since its creation date. */ minAgeDays?: number | null | undefined; /** * Maximum model age in days since its creation date. */ maxAgeDays?: number | null | undefined; /** * Minimum Artificial Analysis intelligence index. */ minIntelligenceIndex?: number | null | undefined; /** * Maximum Artificial Analysis intelligence index. */ maxIntelligenceIndex?: number | null | undefined; /** * Minimum Artificial Analysis coding index. */ minCodingIndex?: number | null | undefined; /** * Maximum Artificial Analysis coding index. */ maxCodingIndex?: number | null | undefined; /** * Minimum Artificial Analysis agentic index. */ minAgenticIndex?: number | null | undefined; /** * Maximum Artificial Analysis agentic index. */ maxAgenticIndex?: number | null | undefined; /** * Minimum tool-calling success rate, as a fraction in [0, 1] (e.g. 0.9 = 90% of requests finishing with a tool_calls finish reason). */ minToolSuccessRate?: number | null | undefined; /** * Maximum tool-calling success rate, as a fraction in [0, 1]. */ maxToolSuccessRate?: number | null | undefined; }; export type GetModelsResponse = { result: models.ModelsListResponse; }; /** @internal */ export declare const GetModelsCategory$outboundSchema: z.ZodType; /** @internal */ export declare const GetModelsSort$outboundSchema: z.ZodType; /** @internal */ export declare const Distillable$outboundSchema: z.ZodType; /** @internal */ export declare const Zdr$outboundSchema: z.ZodEnum; /** @internal */ export declare const Region$outboundSchema: z.ZodType; /** @internal */ export type GetModelsRequest$Outbound = { "HTTP-Referer"?: string | undefined; appTitle?: string | undefined; appCategories?: string | undefined; offset: number | null; limit: number; category?: string | undefined; supported_parameters?: string | undefined; output_modalities?: string | undefined; sort?: string | undefined; q?: string | undefined; input_modalities?: string | undefined; context?: number | undefined; min_price?: number | null | undefined; max_price?: number | null | undefined; arch?: string | undefined; model_authors?: string | undefined; providers?: string | undefined; distillable?: string | undefined; zdr?: string | undefined; region?: string | undefined; min_output_price?: number | null | undefined; max_output_price?: number | null | undefined; min_age_days?: number | null | undefined; max_age_days?: number | null | undefined; min_intelligence_index?: number | null | undefined; max_intelligence_index?: number | null | undefined; min_coding_index?: number | null | undefined; max_coding_index?: number | null | undefined; min_agentic_index?: number | null | undefined; max_agentic_index?: number | null | undefined; min_tool_success_rate?: number | null | undefined; max_tool_success_rate?: number | null | undefined; }; /** @internal */ export declare const GetModelsRequest$outboundSchema: z.ZodType; export declare function getModelsRequestToJSON(getModelsRequest: GetModelsRequest): string; /** @internal */ export declare const GetModelsResponse$inboundSchema: z.ZodType; export declare function getModelsResponseFromJSON(jsonString: string): SafeParseResult; //# sourceMappingURL=getmodels.d.ts.map