# impossibl > Use one API key for models across providers. Get started, connect your app, and manage usage and billing. - [impossibl gateway](https://impossibl.com/docs/introduction.md): One API key to call models from multiple providers, with usage and billing in one workspace. - [Make your first request](https://impossibl.com/docs/quickstart.md): Create an API key, call a model with cURL, Python, or TypeScript, and find the request in your console. - [Agent quickstart: first API call](https://impossibl.com/docs/agent-quickstart.md): Register a funded account and make your first model call in two requests. No signup form, no dashboard, and no human step to get an agent running. - [API keys](https://impossibl.com/docs/authentication.md): Create, use, and rotate workspace API keys without interrupting your application. - [Choose a model](https://impossibl.com/docs/models.md): Find a model for your task, copy its API ID, and check live capabilities and prices. - [SDKs and integrations](https://impossibl.com/docs/integrations.md): Connect your SDK or coding tool with an impossibl key and the correct base URL. - [Choose an API](https://impossibl.com/docs/api-compatibility.md): Pick the request format for your application and understand which provider features the gateway supports. - [Move an existing app to impossibl](https://impossibl.com/docs/migration.md): Update your credentials, base URL, and model IDs, then verify text, tools, streams, and billing before switching traffic. - [Streaming responses over SSE](https://impossibl.com/docs/streaming.md): Consume Server-Sent Events from Chat Completions, the Responses API and Anthropic Messages, with the exact event shapes each surface sends back. - [Tool calling](https://impossibl.com/docs/tool-calling.md): Let a model call your tools on Chat Completions, the Responses API and Anthropic Messages, with full request and response examples for each surface. - [Control reasoning](https://impossibl.com/docs/reasoning.md): Set reasoning effort, leave room for the final answer, and inspect reported reasoning usage. - [Prompt caching](https://impossibl.com/docs/prompt-caching.md): Reuse a repeated prompt prefix and check whether the provider billed a cache read. - [Fix a failed request](https://impossibl.com/docs/errors.md): Diagnose authentication, credit, model, and provider errors, and decide when to retry. - [Vision and image input](https://impossibl.com/docs/vision.md): Send images alongside text on Chat Completions, the Responses API and Anthropic Messages. Output stays text, and image tokens are billed as input tokens. - [Image generation](https://impossibl.com/docs/image-generation.md): Generate images with OpenAI GPT Image and Google Gemini through the OpenAI-compatible images endpoint, billed per token from the same prepaid credit balance. - [Audio transcription](https://impossibl.com/docs/audio-transcription.md): Transcribe completed audio files with OpenAI, Groq Whisper, xAI, and ElevenLabs Scribe through the OpenAI-compatible audio transcriptions endpoint. - [Text to speech](https://impossibl.com/docs/text-to-speech.md): Generate speech from text with Grok Voice TTS and Gemini Flash TTS through the OpenAI-compatible audio speech endpoint. - [Audio and video input](https://impossibl.com/docs/audio-video.md): Send audio and video alongside text on Chat Completions, the Responses API, and the Gemini-native endpoint. Output stays text; audio tokens can carry their own rate. - [Embeddings](https://impossibl.com/docs/embeddings.md): Turn text into vectors on /v1/embeddings, OpenAI-compatible. Billed on input tokens only. - [Reranking](https://impossibl.com/docs/reranking.md): Rank documents against a query on /v1/rerank, billed on input tokens. - [Evaluation](https://impossibl.com/docs/evaluation.md): Ask typed yes/no, choice and score questions about any state on /v1/systemone or /v1/decisions, billed on input tokens. - [Billing and credits](https://impossibl.com/docs/billing.md): Understand request costs, add credits, and keep your workspace funded. - [Bring your own key (BYOK)](https://impossibl.com/docs/byok.md): Route requests through your own OpenAI, Anthropic, Google, xAI, Z.ai, Bedrock or Azure credentials instead of the shared gateway key, and see how routing precedence resolves. - [Routing and failover](https://impossibl.com/docs/routing.md): Understand how the gateway serves your chosen model, handles failed routes, and bills BYOK fallbacks. - [Workspaces](https://impossibl.com/docs/workspaces.md): Share one account with your team. A workspace holds your API keys, credits, and usage, and every member gets a role that says what they can do. - [Inspect requests and usage](https://impossibl.com/docs/request-logs.md): Find a request, understand its cost or failure, and inspect the captured payload. - [Complete Artificial Analysis benchmark snapshot for a serving model](https://impossibl.com/docs/api-reference/complete-artificial-analysis-benchmark-snapshot-for-a-serving-model.md) - [Get executable agent onboarding manifest](https://impossibl.com/docs/api-reference/get-executable-agent-onboarding-manifest.md) - [Get auth.md manifest from the well-known compatibility path](https://impossibl.com/docs/api-reference/get-authmd-manifest-from-the-well-known-compatibility-path.md) - [Get OAuth protected-resource metadata for agent discovery](https://impossibl.com/docs/api-reference/get-oauth-protected-resource-metadata-for-agent-discovery.md) - [List available models and pricing](https://impossibl.com/docs/api-reference/list-available-models-and-pricing.md) - [Create a funded account (agent onboarding)](https://impossibl.com/docs/api-reference/create-a-funded-account-agent-onboarding.md): Creates an account, grants the signup bonus, and mints a first API key. The raw key is returned exactly once. - [Get the authenticated account and balance](https://impossibl.com/docs/api-reference/get-the-authenticated-account-and-balance.md) - [List API keys (metadata only)](https://impossibl.com/docs/api-reference/list-api-keys-metadata-only.md) - [Mint a new API key](https://impossibl.com/docs/api-reference/mint-a-new-api-key.md) - [Revoke an API key](https://impossibl.com/docs/api-reference/revoke-an-api-key.md) - [Rename an API key](https://impossibl.com/docs/api-reference/rename-an-api-key.md) - [List BYOK provider credentials (metadata only)](https://impossibl.com/docs/api-reference/list-byok-provider-credentials-metadata-only.md): See the [BYOK guide](/byok). Never returns the stored credential itself. - [Add (or replace) a BYOK provider credential](https://impossibl.com/docs/api-reference/add-or-replace-a-byok-provider-credential.md): Verified with one live call before being stored; a bad key or Azure config is rejected with the provider's own error and nothing is persisted. Resubmitting for the same `provider` replaces the existing credential. See the [BYOK guide](/byok) for the per-provider field requirements. - [Revoke a BYOK provider credential](https://impossibl.com/docs/api-reference/revoke-a-byok-provider-credential.md) - [Recent usage ledger](https://impossibl.com/docs/api-reference/recent-usage-ledger.md) - [Live usage stream (SSE)](https://impossibl.com/docs/api-reference/live-usage-stream-sse.md): Server-sent events. On connect, a `snapshot` event with the last 20 request log rows, the credit balance, the server-authoritative month-to-date totals (`monthToDate`: tokens, spentCredits, requests) and their read-time `cutoff`; then one `request` event per settled or failed request. Live `request`… - [Recent request log](https://impossibl.com/docs/api-reference/recent-request-log.md): Every gateway request including failures, newest first. Rows only, no payloads. - [One request with its captured payload](https://impossibl.com/docs/api-reference/one-request-with-its-captured-payload.md) - [Start a claim ceremony (hand the account to a human)](https://impossibl.com/docs/api-reference/start-a-claim-ceremony-hand-the-account-to-a-human.md): Begins the WorkOS auth.md "user claimed flow". Authenticated by the agent's API key; the account claimed is that key's account. Returns an RFC 8628-shaped `user_code` + `verification_uri`. Show them to the human, who signs in with WorkOS as `email` and enters the code; poll POST /oauth2/token until… - [Poll a claim ceremony (claim grant)](https://impossibl.com/docs/api-reference/poll-a-claim-ceremony-claim-grant.md): Polls the claim ceremony with `grant_type=urn:workos:agent-auth:grant-type:claim`. Authenticate with the account API key (bearer, or the `claim_token` form field). Returns `authorization_pending` until the human finishes, `expired_token` if the code window closed, `access_denied` if the account was… - [Complete a claim (called by the frontend after WorkOS sign-in)](https://impossibl.com/docs/api-reference/complete-a-claim-called-by-the-frontend-after-workos-sign-in.md): Binds the agent-created account to the signed-in human. Called by the Impossibl web app after WorkOS AuthKit sign-in, authenticated with the human's WorkOS access token (`Authorization: Bearer `), which the gateway verifies via JWKS. The signed-in verified email must match the e… - [Current balance and top-up pricing](https://impossibl.com/docs/api-reference/current-balance-and-top-up-pricing.md) - [Buy net credits with a hosted Stripe Invoice](https://impossibl.com/docs/api-reference/buy-net-credits-with-a-hosted-stripe-invoice.md): A fixed 5% platform fee is added to the net credit amount before applicable tax. Provider usage remains billed at provider list prices with no usage markup. - [Verify Stripe webhook and credit paid invoices](https://impossibl.com/docs/api-reference/verify-stripe-webhook-and-credit-paid-invoices.md): Handles invoice.paid. This is the wallet crediting source of truth; Supabase Stripe Sync Engine is only a mirror for analytics/reconciliation. - [Create a chat completion (OpenAI-compatible)](https://impossibl.com/docs/api-reference/create-a-chat-completion-openai-compatible.md): Drop-in compatible with OpenAI's Chat Completions API. Set `stream: true` for SSE. - [Generate images (OpenAI-compatible)](https://impossibl.com/docs/api-reference/generate-images-openai-compatible.md): OpenAI-compatible image generation with models advertising output_modality=image in GET /v1/models. Returns base64-encoded image bytes (never URLs). Gemini selects PNG or JPEG natively and reports data[].mime_type; omit output_format for Gemini. Image output and Gemini text/thinking output have sepa… - [Transcribe a completed audio file](https://impossibl.com/docs/api-reference/transcribe-a-completed-audio-file.md): Transcribe with any model advertising the audio_transcription modality in GET /v1/models. Pricing and minimum billed duration are published there. `openai/gpt-transcribe` supports SSE with stream=true; Groq Whisper, xAI STT, and ElevenLabs Scribe accept completed files without streaming. Fields a mo… - [Synthesize speech from text](https://impossibl.com/docs/api-reference/synthesize-speech-from-text.md): OpenAI-compatible text to speech. The response body is the raw audio. - [Create a response (OpenAI Responses API)](https://impossibl.com/docs/api-reference/create-a-response-openai-responses-api.md): Implements OpenAI's Responses API for text. Set `stream: true` for semantic-event SSE. - [Create a message (Anthropic Messages API)](https://impossibl.com/docs/api-reference/create-a-message-anthropic-messages-api.md): Drop-in compatible with Anthropic's Messages API. Authenticate with `x-api-key` (or `Authorization: Bearer`). A bare model id like `claude-haiku-4-5` routes to Anthropic; use `provider/model` for others. Set `stream: true` for SSE. - [Create embeddings (OpenAI-compatible)](https://impossibl.com/docs/api-reference/create-embeddings-openai-compatible.md): Drop-in compatible with OpenAI's Embeddings API. Requires a model whose `output_modality` is `embedding` (see GET /v1/models); text models return 400. Billed on input tokens only. - [Evaluate state against typed questions (TypeSafe System One)](https://impossibl.com/docs/api-reference/evaluate-state-against-typed-questions-typesafe-system-one.md): Mirrors TypeSafe AI's native `POST /v1/systemone` exactly, so the official TypeSafe SDKs work by pointing `TYPESAFE_BASE_URL` at this API. Send a `state` plus a map of typed `questions` (noul, choice, score) and receive one typed `answer` per question with probabilities and confidence. Requires a mo… - [Answer typed questions about an input (OpenAI Decisions)](https://impossibl.com/docs/api-reference/answer-typed-questions-about-an-input-openai-decisions.md): Mirrors OpenAI's native `POST /v1/decisions` exactly, so the official OpenAI SDKs work by pointing `OPENAI_BASE_URL` at this API. Send an `input` (text, or user messages with `input_text`/base64 `input_image` parts) plus an array of typed `questions` (predicate, choice, score), each with a unique `n… - [Rerank documents by relevance](https://impossibl.com/docs/api-reference/rerank-documents-by-relevance.md): Rank document strings against a query. Requires a model whose output_modality is rerank. Billed on provider-reported input tokens only; non-streaming. Input is capped at 1,200,000 characters across query/document pairs, including the repeated query and optional task. ## OpenAPI Specs - [openapi](/docs/openapi.yaml) This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.