The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
import { modelCostMap } from "@/components/networking";
import { useQuery } from "@tanstack/react-query";
import { createQueryKeys } from "../common/queryKeysFactory";
export const modelCostMapKeys = createQueryKeys("modelCostMap");
export const useModelCostMap = (enabled = true, catalogOnly = false) => {
return useQuery<Record<string, any>>({
enabled,
queryKey: modelCostMapKeys.list(catalogOnly ? { filters: { catalog_only: "true" } } : {}),
queryFn: async () => await modelCostMap(catalogOnly),
staleTime: 60 * 1000, // 1 minute
gcTime: 60 * 1000, // 1 minute
});
};