All the AI media models in one API
Compose Glif projects, generate images, video, and audio, manage assets, and get structured media results from a single HTTP endpoint.
OpenAPI 3.1 spec
Start here for generated clients, API explorers, and schema-aware tooling.
What you can build
Use the same core platform that powers Glif chats, packaged for product integrations, automation scripts, internal tools, and agent runtimes.
Project-based media generation
Compose durable Glif projects from natural language and let Glif pick models, run tools, and return media links.
Assets and media
Upload files to use as references, and read a project's generated media and recent messages with get_project.
One endpoint, agent-ready
The same surface powers the Glif MCP server — connect an agent client via /mcp, or call it as plain HTTP from anywhere.
AI models behind the API
These are the ones Glif currently reaches for first. Explore all models
Quickstart
List the available tools, then call one. Replace $GLIF_TOKEN with a token from /settings/api-tokens.
intelligence picks the agent: lite, smart, or genius. Without a tier, new projects use your preferred model and existing ones keep theirs.
At a glance
Endpoint
POST https://glif.app
/api/mcp
Auth
Authorization: Bearer
glif_v1_...
Accept
application/json, text/event-stream
both required
Format
JSON-RPC 2.0
over HTTP
Wire format
The API uses JSON-RPC 2.0 so every function can share one authenticated endpoint and one response shape. A function call is always method="tools/call" with params.name and params.arguments.
Call tools/list for the authoritative, machine-readable input/output schema of every tool. The OpenAPI spec documents the endpoint and tool set for API-catalog tooling.
Reference
- /openapi.ymlOpenAPI YAML.
- /openapi.jsonOpenAPI JSON.
- /llms.txtLLM-readable capabilities.
- JSON-RPC 2.0Wire protocol.
- /mcpMCP setup for agent clients.
Frequently asked questions
No. Describe what you want and Glif picks the models and tools. You can set a lite, smart or genius tier, which changes the model and cost.
Only compose_project costs credits, because it's the only call that runs a model. Other tools, such as reading a project or uploading a file, don't. See the pricing page for plans.
Create a token in your API token settings and send it in the Authorization header as a bearer token.
compose_project returns a job ID straight away. Pass it to get_job_status to get saved text and media links as they arrive.
Yes. Upload them with upload_file to use as references in a project.
They're the same tools on the same endpoint. Use MCP to connect an agent client, or call the endpoint over HTTP from your own code.
