Skip to main content
An OpenAI-compatible API for visual AI: OCR, VQA, document extraction, and text detection, all behind one base URL and one Authorization header. See Introduction for the full rationale.
General-purpose routers are built for text and carry lots of LLMs, but only a small slice of visual workloads. The VLM Run Gateway is built for OCR and VQA, and exposes each supported model through the same chat.completions shape so switching models is a one-line change.
Yes. Pass a PDF as a document_url content part and the Gateway decodes it, fans out per-page inference, and returns the assembled pages, concatenated or streamed, through the same chat completions response. In text mode that is one <document> block per PDF, wrapping one <page> block per page; method decides each page’s body, and the page declares it in format. Pass multiple document_url parts to get one block per input. See Flexible Document OCR for the full walkthrough, including the method and document_dpi knobs for tuning cost, latency, and accuracy per request.
Not on the Gateway. response_format={"type":"json_object"} returns the Gateway’s own response object.For extraction against a schema you define, use the VLM Run API, which supports structured responses, custom schemas, and the prebuilt schemas in the VLM Run Hub. See Methods & Response Format for the Gateway’s full contract.
Yes, behind the same base URL and API key as chat completions. See Embeddings and Audio Transcriptions for request schemas, or Models for the models that back each endpoint.
Every model bills per token, at the rates published in the model catalog. Read usage.cost on a chat completion for the exact metered charge of that request. See Pricing and Rate Limits.
Not to start. Every endpoint accepts anonymous access today, rate limited per IP. Authenticate with an API key from app.vlm.run to get usage attributed to your account instead of a shared IP bucket, which matters once you’re building something you plan to run in production. See Authentication.
The Gateway is in alpha: rate-limited, and the model catalog is intentionally small. It already returns a live model catalog, per-request usage.cost for metering, x-request-id for tracing, and sanitized error responses. Authenticate with an API key if you’re building something you plan to run in production, since alpha limits are subject to change.
Retry after a short delay with backoff. Batch or chunk the workload per request, keep your client timeout above the Gateway window, or use stream=true. See Inference timeout (504) for the response contract and more guidance.
Use qwen/qwen3.5-0.8b for VQA over images or video. It does not accept document_url, so use an OCR model for PDFs. Use paddleocr/pp-ocrv6 for general OCR or method: "detect" when you only need bounding polygons. zai-org/glm-ocr serves markdown. deepseek-ai/deepseek-ocr-2 defaults to markdown and adds grounding_ocr to locate a phrase on the page. rednote-hilab/dots.mocr also defaults to markdown and adds parse_layout for structured document layout, plus parse_layout_only and ocr. For layout regions without text recognition, use rednote-hilab/dots.mocr with parse_layout_only. paddlepaddle/paddleocr-vl-1.6 defaults to ocr and adds table, formula, and chart when you need a page’s tables, equations, or charts as text. For documents, treat model, method, and document_dpi as one tunable unit: start with the cheapest combination that clears your accuracy bar on your own data, and only pay for more where it actually moves the numbers.

Introduction

Why the VLM Run Gateway exists and what it’s built to help you do.

Models

Full catalog with availability, methods, and accepted inputs.

Methods

Per-model method reference and request parameters.

Quickstart

First requests for VQA and document OCR.