/**
 * OpenRouter Models Service — caches the list of tool-calling-capable models
 * from OpenRouter's public /models endpoint.
 *
 * The list rarely changes, so we fetch it once on startup (non-blocking) and
 * keep it for the process lifetime. The endpoint is public — no API key is
 * required — so the cache warms even before the user configures OpenRouter.
 *
 * Mirrors the cache shape of {@link ./sdk-info.ts}.
 */
import type { OpenRouterModelInfo, OpenRouterModelAliasInfo } from "shared/types/index.js";
interface OpenRouterModelsCache {
    models: OpenRouterModelInfo[];
    fetchedAt: number;
}
/**
 * Initialize the OpenRouter models cache. Call once at startup.
 * Non-blocking — runs in the background.
 */
export declare function initOpenRouterModelsCache(): void;
/**
 * Get cached OpenRouter models, waiting for the initial fetch if needed.
 * If init was never called, kicks it off now.
 */
export declare function getOpenRouterModelsAsync(): Promise<OpenRouterModelInfo[]>;
/**
 * Invalidate and re-fetch the models cache. Useful after the base URL changes.
 */
export declare function refreshOpenRouterModelsCache(): Promise<OpenRouterModelsCache>;
/**
 * Format an OpenRouter per-token USD price into a clean per-1M-token display:
 *  - free -> "0"
 *  - whole dollars >= 1 -> no decimals ("$30")
 *  - otherwise -> two decimals ("$1.25", "$0.08")
 */
export declare function formatOpenRouterPrice(perToken: string): string;
/**
 * Subsequence-search the cached tool-calling models by slug.
 * An empty query returns the full (sorted) list.
 */
export declare function searchOpenRouterModels(query: string, limit?: number): Promise<OpenRouterModelInfo[]>;
/**
 * List user-defined model aliases, each joined with its target model's name
 * and pricing from the cached catalog. Targets that aren't in the cache
 * (stale cache, typo, non-tool-calling model) come back without the joined
 * fields rather than being dropped — the alias still resolves at run time.
 */
export declare function getOpenRouterModelAliasesAsync(): Promise<OpenRouterModelAliasInfo[]>;
/**
 * Subsequence-search user-defined aliases by alias name or target slug.
 * An empty query returns all aliases.
 */
export declare function searchOpenRouterModelAliases(query: string, limit?: number): Promise<OpenRouterModelAliasInfo[]>;
export {};
//# sourceMappingURL=openrouter-models.d.ts.map