{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Bria for AI agents","description":"Generate and edit images and video with Bria's FIBO models through a REST API, Python SDK, MCP server and agent skills. Licensed training data, controllable output, provenance on every result.","siteUrl":"https://docs.bria.ai","image":"/assets/logo.4aab4827f8ef484ab0149a267109951af9b35a6e5d7ddacfc52a0cb2bf07aec6.db81178d.png","llmstxt":{"hide":false,"title":"Bria API documentation","description":"Bria's developer platform: controllable, commercially safe visual generative AI (images and video) as a REST API, Python SDK, MCP server and agent skills.","details":{"path":"_llmstxt-details.md"},"sections":[{"title":"Getting started","description":"First call, authentication, async jobs and webhooks, rate limits, inputs.","includeFiles":["index.md","getting-started/quickstart.md","getting-started/authentication.md","getting-started/async-requests.md","status.yaml","getting-started/rate-limits-and-errors.md","getting-started/working-with-images.md"]},{"title":"Integrate","description":"Python SDK, MCP server, agent skills, and machine-readable docs for agents.","includeFiles":["integration-methods/python-sdk.md","MCP-authentication.md","integration-methods/bria-skill.md","integration-methods/for-ai-agents.md"]},{"title":"Concepts","description":"Platform map, VGL and the FIBO models, safety, best practices.","includeFiles":["products-overview.md","VGL.md","safety.md","best-practices-overview.md","image-generation-best-practices.md","image-editing-best-practices.md","product-shots-best-practices.md"]},{"title":"Image Generation","description":"Generate images from text, reference images or structured (VGL) prompts with FIBO.","includeFiles":["image-generation-overview.md","image-generation.yaml"]},{"title":"Image Editing","description":"Instruction-based editing plus specialized endpoints for backgrounds, erasing, fill, expansion, upscaling and style.","includeFiles":["image-editing-overview.md","image-editing.yaml"]},{"title":"Product Shot Editing","description":"Cutouts, packshots, shadows, lifestyle scenes, product integration, holding, virtual try-on, automotive.","includeFiles":["product-shot-overview.md","product-shot-editing.yaml"]},{"title":"Video Editing","description":"Background removal (REST or real-time streaming), erasing, upscaling and masks for video; local video upload.","includeFiles":["video-editing-overview.md","local-video-upload-service.md","streaming-rmbg.md","video-editing.yaml"]},{"title":"Ad Delayer","description":"Turn a flat ad into editable layers; the guide holds the layer document contract.","includeFiles":["ad-delayer-overview.md","ad-delayer.yaml"]},{"title":"Trust and provenance","description":"Public verification of Bria provenance, and attribution of outputs to licensed training data.","includeFiles":["trust-and-provenance-overview.md","visual-verification-overview.md","visual-verification.yaml","enterprise/attribution.md","bria-attribution-service.yaml"]},{"title":"Enterprise","description":"Run Bria in your own cloud or on-premises.","includeFiles":["enterprise/deployment-options.md"]}],"excludeFiles":["_llmstxt-details.md","README.md"]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"bria-for-ai-agents","__idx":0},"children":["Bria for AI agents"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Bria is built to be used by agents as much as by people. This page lists the machine-readable surfaces of the documentation and the shortest paths from an agent to a working call. If you are an agent reading this: everything you need is linked from here."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"read-the-docs-programmatically","__idx":1},"children":["Read the docs programmatically"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Surface"},"children":["Surface"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"URL"},"children":["URL"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Use it for"},"children":["Use it for"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Index for LLMs"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://docs.bria.ai/llms.txt"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://docs.bria.ai/llms.txt"]}]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["A curated list of every page with one-line descriptions, plus the key facts about auth, async jobs and limits."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Markdown for every page"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Append ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":[".md"]}," to any page URL, for example ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/webhooks.md"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/image-editing/v2-endpoints/blur-bg.md"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Clean page content without navigation. Requests that send ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["Accept: text/markdown"]}," or a known agent user agent receive Markdown automatically."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Docs MCP server"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://docs.bria.ai/mcp"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Search the docs, list APIs and endpoints, and fetch endpoint schemas and security schemes as tools. Connect it from Cursor, VS Code or Claude Code, or use the \"Connect\" actions at the top of any page."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["OpenAPI descriptions"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Download button on each API reference page (for example ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/image-editing"},"children":["Image Editing"]},")"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["The full OpenAPI 3.0 description of each API for code generation and validation."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Sandbox"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://platform.bria.ai/console"},"children":["platform.bria.ai"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Try any endpoint interactively with your token."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Connect the docs MCP server in Claude Code:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"claude mcp add --transport http bria-docs https://docs.bria.ai/mcp\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"call-bria-from-an-agent","__idx":2},"children":["Call Bria from an agent"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Path"},"children":["Path"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Best for"},"children":["Best for"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Setup"},"children":["Setup"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/mcp-authentication"},"children":["Bria MCP server"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Claude, Cursor, VS Code, ChatGPT, the Anthropic and OpenAI APIs, custom agents"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://mcp.prod.bria-api.com/mcp"]}," with the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["api_token"]}," header, or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["uvx bria-mcp"]}," locally"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/integration-methods/bria-skill"},"children":["Agent skills"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Claude Code, Cursor, Codex, Cline and other coding agents"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["npx skills add bria-ai/bria-skill"]},", key in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["BRIA_API_KEY"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/integration-methods/python-sdk"},"children":["Python SDK"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Agents that write and run Python"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["pip install bria-client"]},", key in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["BRIA_API_TOKEN"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JavaScript / TypeScript"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Agents that write Node or edge code"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["fetch"]}," against the REST API with the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["api_token"]}," header; see the ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/getting-started/quickstart"},"children":["Quickstart"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["REST API (cURL, any language)"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Anything else"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["api_token"]}," header; see the ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/getting-started/quickstart"},"children":["Quickstart"]}]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"facts-every-agent-should-know","__idx":3},"children":["Facts every agent should know"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Base URL ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["https://engine.prod.bria-api.com"]},". Authenticate with the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["api_token"]}," header; only ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/v2/image/verify"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/v2/video/verify"]}," are public."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["v2 endpoints are asynchronous: they return ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["202"]}," with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["request_id"]}," and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["status_url"]},". Poll ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["GET /v2/status/{request_id}"]}," every 1 to 2 seconds until ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["status"]}," is ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["COMPLETED"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ERROR"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["UNKNOWN"]},", or pass ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["webhook_url"]},". ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["sync: true"]}," blocks and returns the result, except for async-only options such as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["resolution: \"4MP\""]},"."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Images are a public URL or a raw base64 string (no ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["data:"]}," prefix). JPEG, PNG and WEBP."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Do not send optional parameters you do not need. Defaults are tuned for quality."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["For a transparent background or a cutout of a single image, use ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/v2/image/edit/remove_background"]},". For live video use ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/streaming-rmbg"},"children":["Streaming Background Removal"]},"; for files use ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/v2/video/edit/remove_background"]},"."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Generation returns a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["structured_prompt"]}," and a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["seed"]},". Store both: sending them back reproduces the image, and adding a ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["prompt"]}," refines it without changing the composition."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Rate limits are per organization and endpoint: Free 10, Pay-as-you-go 60, Enterprise 1000 requests per minute. On ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["429"]},", back off exponentially."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Please send ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["User-Agent: BriaPlatform/APIdocs/LLMsAgent"]}," on API calls made on behalf of an agent, so Bria can support agent traffic well."]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"a-brief-you-can-paste-into-a-system-prompt","__idx":4},"children":["A brief you can paste into a system prompt"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"text","header":{"controls":{"copy":{}}},"source":"You can generate and edit images and video with Bria (https://docs.bria.ai). Authenticate with the\napi_token header. Prefer v2 endpoints under https://engine.prod.bria-api.com/v2. Requests are async:\nPOST returns request_id and status_url; poll GET /v2/status/{request_id} until status is COMPLETED,\nthen download result.image_url or result.video_url. Pass images as public URLs or raw base64. Use\n/image/generate for new images, /image/edit for instruction edits, /image/edit/remove_background for\ncutouts, /image/edit/expand for outpainting, /image/edit/increase_resolution for upscaling, and\n/image/edit/product/* for product photography. Read https://docs.bria.ai/llms.txt for the full index.\n","lang":"text"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"ask-the-docs","__idx":5},"children":["Ask the docs"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Ask AI"]}," button in the header answers questions from these docs only, with code where it helps. It follows the same conventions as this page: REST by default, Python when a language is not specified, and the status endpoint for anything asynchronous."]}]},"headings":[{"value":"Bria for AI agents","id":"bria-for-ai-agents","depth":1},{"value":"Read the docs programmatically","id":"read-the-docs-programmatically","depth":2},{"value":"Call Bria from an agent","id":"call-bria-from-an-agent","depth":2},{"value":"Facts every agent should know","id":"facts-every-agent-should-know","depth":2},{"value":"A brief you can paste into a system prompt","id":"a-brief-you-can-paste-into-a-system-prompt","depth":2},{"value":"Ask the docs","id":"ask-the-docs","depth":2}],"frontmatter":{"title":"Bria for AI agents","description":"How agents and LLMs should read these docs and call Bria. llms.txt, Markdown for every page, the docs MCP server, the Bria MCP server, skills and the SDK.","seo":{"title":"Bria for AI agents"}},"lastModified":"2026-09-27T11:58:15.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/integration-methods/for-ai-agents","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}