Edits or extends one or more uploaded images (multipart/form-data, fields image or image[], optional mask). Billing, size tiers, n, b64_json output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.
Tags for this call as comma-separated key=value pairs, for example client=acme,env=prod. Merged with the API key's default tags; the tags body field wins on the same key. X-OmniRelay-Tags is the same header under its former name and stays accepted.
Send enabled to receive a gateway_metadata block describing what the gateway decided. Any other value, or no header, leaves the response unchanged. X-OmniRelay-Metadata is the same header under its former name and stays accepted.
Available options:
enabled
Body
multipart/form-data
Other fields (background, output_format, output_compression, moderation, user) are passed to the model, which accepts or refuses them.
Present only when the request sent X-Gateway-Metadata: enabled. Returned under both gateway_metadata and its former name omnirelay_metadata, with the same content. On a stream it rides the first chunk.
Present only when the request sent X-Gateway-Metadata: enabled. Returned under both gateway_metadata and its former name omnirelay_metadata, with the same content. On a stream it rides the first chunk.
Show child attributes
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"OmniRelay Documentation","description":"One OpenAI-compatible API for every model: keys, routing, usage and billing in one gateway.","colors":{"primary":"#3155f5","light":"#7d95ff","dark":"#3155f5"},"logo":{"light":"https://mintcdn.com/mirvos/m9J_0EZqJ57fDiaC/logo.svg?fit=max\u0026auto=format\u0026n=m9J_0EZqJ57fDiaC\u0026q=85\u0026s=ca602e0318071154028ed8989c7110cc","dark":"https://mintcdn.com/mirvos/m9J_0EZqJ57fDiaC/logo.svg?fit=max\u0026auto=format\u0026n=m9J_0EZqJ57fDiaC\u0026q=85\u0026s=ca602e0318071154028ed8989c7110cc","href":"https://omnirelay.ai"},"favicon":"https://mintcdn.com/mirvos/m9J_0EZqJ57fDiaC/favicon.svg?fit=max\u0026auto=format\u0026n=m9J_0EZqJ57fDiaC\u0026q=85\u0026s=87700ecee580e455626d4376f120e405","api":{"playground":{"display":"interactive"},"examples":{"defaults":"required","languages":["curl","python","javascript"]}},"appearance":{"default":"system"},"navbar":{"links":[{"href":"https://omnirelay.ai","label":"Website"},{"href":"https://omnirelay.instatus.com","label":"Status"}],"primary":{"type":"button","label":"Open Console","href":"https://omnirelay.ai/login"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"styling":{"latex":false},"navigation":{"languages":[{"language":"en","href":""},{"language":"cn","navbar":{"links":[{"href":"https://omnirelay.ai","label":"官网"},{"href":"https://omnirelay.instatus.com","label":"服务状态"}],"primary":{"type":"button","label":"打开控制台","href":"https://omnirelay.ai/login"}},"href":"cn"},{"language":"es","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Sitio web"},{"href":"https://omnirelay.instatus.com","label":"Estado"}],"primary":{"type":"button","label":"Abrir consola","href":"https://omnirelay.ai/login"}},"href":"es/user-manual"},{"language":"fr","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Site web"},{"href":"https://omnirelay.instatus.com","label":"État du service"}],"primary":{"type":"button","label":"Ouvrir la console","href":"https://omnirelay.ai/login"}},"href":"fr/user-manual"},{"language":"de","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Website"},{"href":"https://omnirelay.instatus.com","label":"Dienststatus"}],"primary":{"type":"button","label":"Konsole öffnen","href":"https://omnirelay.ai/login"}},"href":"de/user-manual"},{"language":"pt-BR","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Site"},{"href":"https://omnirelay.instatus.com","label":"Status"}],"primary":{"type":"button","label":"Abrir console","href":"https://omnirelay.ai/login"}},"href":"pt-BR/user-manual"},{"language":"jp","navbar":{"links":[{"href":"https://omnirelay.ai","label":"ウェブサイト"},{"href":"https://omnirelay.instatus.com","label":"サービス状況"}],"primary":{"type":"button","label":"コンソールを開く","href":"https://omnirelay.ai/login"}},"href":"jp/user-manual"},{"language":"ko","navbar":{"links":[{"href":"https://omnirelay.ai","label":"웹사이트"},{"href":"https://omnirelay.instatus.com","label":"서비스 상태"}],"primary":{"type":"button","label":"콘솔 열기","href":"https://omnirelay.ai/login"}},"href":"ko/user-manual"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"mirvos","hasAudioNarration":false,"actualSubdomain":"mirvos","customDomains":["omnirelay.ai"],"gitSource":{"type":"github","owner":"mirvos-ai","repo":"omnirelay-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"DISABLED"},"WEB_MCP":{"status":"DISABLED"},"NARRATION":{"status":"DISABLED"}},"buildId":"6aea0b3298ee2cfbfea93cfe","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"cn","tag":"V1 文档","count":24},{"language":"en","tag":"V1 Documentation","count":24},{"language":"cn","tag":"V1 API 参考","count":18},{"language":"en","tag":"V1 API Reference","count":18},{"language":"cn","tag":"管理 API","count":9},{"language":"en","tag":"Management","count":9},{"language":"cn","tag":"通用","count":8},{"language":"en","tag":"General","count":8},{"language":"cn","tag":"LLM","count":4},{"language":"cn","tag":"视频","count":4},{"language":"en","tag":"LLMs","count":4},{"language":"en","tag":"Videos","count":4},{"language":"cn","tag":"图片","count":3},{"language":"cn","tag":"概览","count":3},{"language":"cn","tag":"快速开始","count":3},{"language":"de","tag":"V1-Dokumentation","count":3},{"language":"es","tag":"Documentación V1","count":3},{"language":"fr","tag":"Documentation V1","count":3},{"language":"en","tag":"Images","count":3},{"language":"en","tag":"Overview","count":3},{"language":"en","tag":"Quick Start","count":3},{"language":"jp","tag":"V1 ドキュメント","count":3},{"language":"ko","tag":"V1 문서","count":3},{"language":"pt-BR","tag":"Documentação V1","count":3},{"language":"de","tag":"Allgemein","count":2},{"language":"es","tag":"General","count":2},{"language":"fr","tag":"Général","count":2},{"language":"jp","tag":"一般","count":2},{"language":"ko","tag":"일반","count":2},{"language":"pt-BR","tag":"Geral","count":2},{"language":"cn","tag":"用户手册","count":1},{"language":"de","tag":"Benutzerhandbuch","count":1},{"language":"es","tag":"Manual de usuario","count":1},{"language":"fr","tag":"Guide utilisateur","count":1},{"language":"en","tag":"User manual","count":1},{"language":"jp","tag":"ユーザーマニュアル","count":1},{"language":"ko","tag":"사용자 매뉴얼","count":1},{"language":"pt-BR","tag":"Manual do usuário","count":1}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"/docs","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/images/edit-images","slug":"/api-reference/images/edit-images","pageMetadata":{"title":"Edit images","description":"Edits or extends one or more uploaded images (multipart/form-data, fields `image` or `image[]`, optional `mask`). Billing, size tiers, `n`, `b64_json` output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/images/edits","href":"/api-reference/images/edit-images","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n code: \"code\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_components.p, {\n children: [\"Edits or extends one or more uploaded images (multipart/form-data, fields \", _jsx(_components.code, {\n children: \"image\"\n }), \" or \", _jsx(_components.code, {\n children: \"image[]\"\n }), \", optional \", _jsx(_components.code, {\n children: \"mask\"\n }), \"). Billing, size tiers, \", _jsx(_components.code, {\n children: \"n\"\n }), \", \", _jsx(_components.code, {\n children: \"b64_json\"\n }), \" output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.\"]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Edit images","description":"Edits or extends one or more uploaded images (multipart/form-data, fields `image` or `image[]`, optional `mask`). Billing, size tiers, `n`, `b64_json` output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/images/edits","href":"/api-reference/images/edit-images","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"tags":["Images"],"summary":"Edit images","description":"Edits or extends one or more uploaded images (multipart/form-data, fields `image` or `image[]`, optional `mask`). Billing, size tiers, `n`, `b64_json` output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.","operationId":"editImage","parameters":["dd7d608e-9583-475e-989c-2ac5029b8855","00ddf499-e8f1-4fb9-a33c-c3aeb6042fd7"],"requestBody":"5e65b4ce-c13c-4dc4-b90d-55f695485f41","responses":{"200":"ba8b2d96-a96a-4315-b33d-b5723caf0a1f","400":"303ef02e-fdae-4715-91e1-739de256f9b8","401":"41f76f66-3db8-44f1-8101-4173f19275d7","402":"ca113d19-0106-46f9-b409-ffbb75647373","403":"811df718-65ee-4283-a00b-a4cbf817106d","404":"0f4b4f85-e2ff-4581-a172-9cbf55a7bcdb","413":"9c3173ef-c9e3-43c2-947f-60aba76c77e0","429":"fa66d29d-aaf8-4ab3-9af2-dfad8a600ccf","502":"aeff5a68-28bd-4473-ab4b-bfe26b2aa3e0","503":"48e9218f-89a9-499d-ab86-8e8138456721","504":"6408a13a-7fb8-4fb3-a2bc-21fbfa3e48ea"},"method":"post","type":"path","servers":["8343319b-fc64-466b-b314-1aa49367d633"],"security":["0cfd7c8d-004d-4e0d-96de-988610dc14a3"],"path":"/v1/images/edits","baseUrlOptions":["https://api.omnirelay.ai"],"title":"Edit images","codeSamples":[],"requestExampleLanguages":["bash","python","javascript"],"requiredOnlyExamples":true,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{"dd7d608e-9583-475e-989c-2ac5029b8855":{"name":"X-Gateway-Tags","in":"header","required":false,"description":"Tags for this call as comma-separated `key=value` pairs, for example `client=acme,env=prod`. Merged with the API key's default tags; the `tags` body field wins on the same key. `X-OmniRelay-Tags` is the same header under its former name and stays accepted.","schema":{"type":"string","isRequired":false,"description":"Tags for this call as comma-separated `key=value` pairs, for example `client=acme,env=prod`. Merged with the API key's default tags; the `tags` body field wins on the same key. `X-OmniRelay-Tags` is the same header under its former name and stays accepted.","uniqueKey":"","typeLabel":"string"},"example":"client=acme,env=prod"},"00ddf499-e8f1-4fb9-a33c-c3aeb6042fd7":{"name":"X-Gateway-Metadata","in":"header","required":false,"description":"Send `enabled` to receive a `gateway_metadata` block describing what the gateway decided. Any other value, or no header, leaves the response unchanged. `X-OmniRelay-Metadata` is the same header under its former name and stays accepted.","schema":{"type":"string","enum":["enabled"],"isRequired":false,"description":"Send `enabled` to receive a `gateway_metadata` block describing what the gateway decided. Any other value, or no header, leaves the response unchanged. `X-OmniRelay-Metadata` is the same header under its former name and stays accepted.","uniqueKey":"","typeLabel":"enum\u003cstring>"}}},"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["model","prompt","image"],"description":"Other fields (`background`, `output_format`, `output_compression`, `moderation`, `user`) are passed to the model, which accepts or refuses them.","properties":{"model":{"type":"string","description":"Image model ID, for example `gpt-image-2`.","example":"gpt-image-2","isRequired":true,"uniqueKey":"model","typeLabel":"string"},"prompt":{"type":"string","maxLength":32000,"description":"Text description of the image, up to 32000 characters.","isRequired":true,"uniqueKey":"prompt","typeLabel":"string"},"image":{"type":"string","format":"binary","description":"One or more source images (PNG, JPEG or WebP).","isRequired":true,"uniqueKey":"image","typeLabel":"file"},"n":{"type":"integer","minimum":1,"maximum":4,"default":1,"description":"Number of images, 1 to the model limit (4). n images are reserved; only the images returned are charged.","uniqueKey":"n","typeLabel":"integer"},"size":{"type":"string","default":"auto","example":"1024x1024","description":"`WIDTHxHEIGHT` or `auto`. Decides the price tier: longest side up to 1024 px is 1K, up to 2048 px is 2K, up to 4096 px is 4K; `auto` or omitted is 2K.","uniqueKey":"size","typeLabel":"string"},"quality":{"type":"string","description":"Passed to the model, for example `low`, `medium`, `high` or `auto`. Does not change the price.","uniqueKey":"quality","typeLabel":"string"},"response_format":{"type":"string","enum":["b64_json"],"description":"Only `b64_json` is supported.","uniqueKey":"response_format","typeLabel":"enum\u003cstring>"},"mask":{"type":"string","format":"binary","description":"Optional mask image; transparent areas mark where to edit.","uniqueKey":"mask","typeLabel":"file"}},"additionalProperties":true,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"model":"gpt-image-2","prompt":"\u003cstring>","image":"\u003cstring>","n":1,"size":"1024x1024","quality":"\u003cstring>","response_format":"b64_json","mask":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"ba8b2d96-a96a-4315-b33d-b5723caf0a1f":{"description":"Images with settled usage and cost.","headers":{"X-Request-ID":{"description":"OmniRelay request ID for diagnostics. It is separate from the provider trace, header and response IDs.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","required":["created","data","model","cost_microusd"],"properties":{"created":{"type":"integer","isRequired":true,"uniqueKey":"created","typeLabel":"integer"},"model":{"type":"string","isRequired":true,"uniqueKey":"model","typeLabel":"string"},"data":{"type":"array","description":"Generated images.","items":{"type":"object","required":["b64_json"],"properties":{"b64_json":{"type":"string","description":"Base64-encoded image.","isRequired":true,"uniqueKey":"data.items.[INDEX].b64_json","typeLabel":"string"},"revised_prompt":{"type":"string","uniqueKey":"data.items.[INDEX].revised_prompt","typeLabel":"string"}},"uniqueKey":"data.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"data","typeLabel":"object[]"},"cost_microusd":{"type":"integer","description":"Charged amount in micro-USD after your discount.","isRequired":true,"uniqueKey":"cost_microusd","typeLabel":"integer"},"background":{"type":"string","uniqueKey":"background","typeLabel":"string"},"output_format":{"type":"string","uniqueKey":"output_format","typeLabel":"string"},"quality":{"type":"string","uniqueKey":"quality","typeLabel":"string"},"size":{"type":"string","uniqueKey":"size","typeLabel":"string"},"usage":{"type":"object","description":"Token counts reported by the model, for information; images are billed per image, not per token.","additionalProperties":true,"uniqueKey":"usage","typeLabel":"object"},"omnirelay_metadata":{"type":"object","description":"Present only when the request sent `X-Gateway-Metadata: enabled`. Returned under both `gateway_metadata` and its former name `omnirelay_metadata`, with the same content. On a stream it rides the first chunk.","properties":{"request_id":{"type":"string","description":"The request ID, as in `X-Request-ID`.","uniqueKey":"omnirelay_metadata.request_id","typeLabel":"string"},"requested":{"type":"string","description":"The model ID you sent.","uniqueKey":"omnirelay_metadata.requested","typeLabel":"string"},"model":{"type":"string","description":"The model that served the call.","uniqueKey":"omnirelay_metadata.model","typeLabel":"string"},"provider":{"type":"string","description":"The provider of that model.","uniqueKey":"omnirelay_metadata.provider","typeLabel":"string"},"mode":{"type":"string","enum":["live"],"description":"live: a real provider was called.","uniqueKey":"omnirelay_metadata.mode","typeLabel":"enum\u003cstring>"},"strategy":{"type":"string","enum":["direct"],"description":"How the model was resolved. Every model has one channel today, so this is always `direct`.","uniqueKey":"omnirelay_metadata.strategy","typeLabel":"enum\u003cstring>"},"attempt":{"type":"integer","description":"1-based position of the attempt that served. Always 1 until fallback exists.","uniqueKey":"omnirelay_metadata.attempt","typeLabel":"integer"},"attempts":{"type":"array","description":"Every attempt made, in order.","items":{"type":"object","properties":{"provider":{"type":"string","uniqueKey":"omnirelay_metadata.attempts.items.[INDEX].provider","typeLabel":"string"},"model":{"type":"string","uniqueKey":"omnirelay_metadata.attempts.items.[INDEX].model","typeLabel":"string"},"mode":{"type":"string","uniqueKey":"omnirelay_metadata.attempts.items.[INDEX].mode","typeLabel":"string"}},"uniqueKey":"omnirelay_metadata.attempts.items.[INDEX]","typeLabel":"object"},"uniqueKey":"omnirelay_metadata.attempts","typeLabel":"object[]"},"tags":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"omnirelay_metadata.tags.additionalProperties","typeLabel":"string"},"description":"The tags recorded for this call, or `{}`.","uniqueKey":"omnirelay_metadata.tags","typeLabel":"object"},"deprecated_header":{"type":"string","description":"Present when the request sent an old-style header (`X-OmniRelay-Tags` or `X-OmniRelay-Metadata`) together with its new name carrying a different value: names the old header that was ignored.","uniqueKey":"omnirelay_metadata.deprecated_header","typeLabel":"string"}},"uniqueKey":"omnirelay_metadata","typeLabel":"object"},"gateway_metadata":{"type":"object","description":"Present only when the request sent `X-Gateway-Metadata: enabled`. Returned under both `gateway_metadata` and its former name `omnirelay_metadata`, with the same content. On a stream it rides the first chunk.","properties":{"request_id":{"type":"string","description":"The request ID, as in `X-Request-ID`.","uniqueKey":"gateway_metadata.request_id","typeLabel":"string"},"requested":{"type":"string","description":"The model ID you sent.","uniqueKey":"gateway_metadata.requested","typeLabel":"string"},"model":{"type":"string","description":"The model that served the call.","uniqueKey":"gateway_metadata.model","typeLabel":"string"},"provider":{"type":"string","description":"The provider of that model.","uniqueKey":"gateway_metadata.provider","typeLabel":"string"},"mode":{"type":"string","enum":["live"],"description":"live: a real provider was called.","uniqueKey":"gateway_metadata.mode","typeLabel":"enum\u003cstring>"},"strategy":{"type":"string","enum":["direct"],"description":"How the model was resolved. Every model has one channel today, so this is always `direct`.","uniqueKey":"gateway_metadata.strategy","typeLabel":"enum\u003cstring>"},"attempt":{"type":"integer","description":"1-based position of the attempt that served. Always 1 until fallback exists.","uniqueKey":"gateway_metadata.attempt","typeLabel":"integer"},"attempts":{"type":"array","description":"Every attempt made, in order.","items":{"type":"object","properties":{"provider":{"type":"string","uniqueKey":"gateway_metadata.attempts.items.[INDEX].provider","typeLabel":"string"},"model":{"type":"string","uniqueKey":"gateway_metadata.attempts.items.[INDEX].model","typeLabel":"string"},"mode":{"type":"string","uniqueKey":"gateway_metadata.attempts.items.[INDEX].mode","typeLabel":"string"}},"uniqueKey":"gateway_metadata.attempts.items.[INDEX]","typeLabel":"object"},"uniqueKey":"gateway_metadata.attempts","typeLabel":"object[]"},"tags":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"gateway_metadata.tags.additionalProperties","typeLabel":"string"},"description":"The tags recorded for this call, or `{}`.","uniqueKey":"gateway_metadata.tags","typeLabel":"object"},"deprecated_header":{"type":"string","description":"Present when the request sent an old-style header (`X-OmniRelay-Tags` or `X-OmniRelay-Metadata`) together with its new name carrying a different value: names the old header that was ignored.","uniqueKey":"gateway_metadata.deprecated_header","typeLabel":"string"}},"uniqueKey":"gateway_metadata","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"created":123,"model":"\u003cstring>","data":[{"b64_json":"\u003cstring>","revised_prompt":"\u003cstring>"}],"cost_microusd":123,"background":"\u003cstring>","output_format":"\u003cstring>","quality":"\u003cstring>","size":"\u003cstring>","usage":{},"omnirelay_metadata":{"request_id":"\u003cstring>","requested":"\u003cstring>","model":"\u003cstring>","provider":"\u003cstring>","mode":"live","strategy":"direct","attempt":123,"attempts":[{"provider":"\u003cstring>","model":"\u003cstring>","mode":"\u003cstring>"}],"tags":{},"deprecated_header":"\u003cstring>"},"gateway_metadata":{"request_id":"\u003cstring>","requested":"\u003cstring>","model":"\u003cstring>","provider":"\u003cstring>","mode":"live","strategy":"direct","attempt":123,"attempts":[{"provider":"\u003cstring>","model":"\u003cstring>","mode":"\u003cstring>"}],"tags":{},"deprecated_header":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"303ef02e-fdae-4715-91e1-739de256f9b8":{"description":"Invalid JSON, form or parameters (`response_format` other than `b64_json`, `stream`, an unknown `size`, `n` above the model limit), or a parameter the model refused. Nothing is charged.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"unsupported_parameter"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"unsupported_parameter"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"41f76f66-3db8-44f1-8101-4173f19275d7":{"description":"`unauthorized`: the API key is missing, revoked, or invalid.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"unauthorized"}},"examples":{"Example":{"title":"Example","value":{"error":{"code":"unauthorized"}}}},"exampleType":"examples"}},"exampleType":"examples"},"ca113d19-0106-46f9-b409-ffbb75647373":{"description":"inference_budget_or_access_denied: wallet, key or platform budget cannot cover n images at the requested tier; member_budget_exceeded: member cap exceeded. Rejected before dispatch.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"inference_budget_or_access_denied"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"inference_budget_or_access_denied"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"811df718-65ee-4283-a00b-a4cbf817106d":{"description":"`model_not_allowed`: the API key is limited to other models; `ip_not_allowed`. Nothing is charged.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"model_not_allowed"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"model_not_allowed"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"0f4b4f85-e2ff-4581-a172-9cbf55a7bcdb":{"description":"`model_unavailable`: the model is not an image model available to this workspace.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"model_unavailable"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"model_unavailable"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"9c3173ef-c9e3-43c2-947f-60aba76c77e0":{"description":"payload_too_large: the request body exceeds 20 MiB.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"payload_too_large"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"payload_too_large"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"fa66d29d-aaf8-4ab3-9af2-dfad8a600ccf":{"description":"Rate or concurrency limit. Nothing is charged; retry after Retry-After seconds.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"rate_limited"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"rate_limited"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"aeff5a68-28bd-4473-ab4b-bfe26b2aa3e0":{"description":"`upstream_rejected`: the provider refused the call; nothing is charged. `image_call_held`: a dropped connection, a provider server error or an answer that could not be verified; the call is held for review and charged only if the provider produced the images.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"image_call_held"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"image_call_held"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"48e9218f-89a9-499d-ab86-8e8138456721":{"description":"Live access is not ready or paused. Nothing is sent or charged.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"live_provider_unavailable"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"live_provider_unavailable"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"},"6408a13a-7fb8-4fb3-a2bc-21fbfa3e48ea":{"description":"`image_call_held`: the call did not finish in time. It is held for review and charged only if the provider produced the images.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message","type"],"properties":{"code":{"type":"string","example":"model_unavailable","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","example":"The model does not exist or is disabled.","description":"Short English description for logs and SDK exceptions. Its wording can change; branch on code.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","example":"not_found_error","description":"Error family by HTTP status: invalid_request_error, authentication_error, insufficient_quota, permission_error, not_found_error, conflict_error, rate_limit_error, service_unavailable or api_error.","isRequired":true,"uniqueKey":"error.type","typeLabel":"string"},"param":{"type":"string","maxLength":200,"description":"Rejected request field path when identifiable; never a parameter value. Responses uses native field names.","uniqueKey":"error.param","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"},"request_id":{"type":"string","description":"Present on chat completion, Responses and embeddings errors.","uniqueKey":"request_id","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"code":"image_call_held"},"request_id":"2f6c1d0e9a"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"image_call_held"},"request_id":"2f6c1d0e9a"}}},"exampleType":"examples"}},"exampleType":"examples"}},"security":{"0cfd7c8d-004d-4e0d-96de-988610dc14a3":{"bearerAuth":{"type":"http","scheme":"bearer","description":"An API key created in the OmniRelay console. The owner can view it again in the console after confirming their identity.","scopes":[],"schemeName":"bearerAuth"}}},"servers":{"8343319b-fc64-466b-b314-1aa49367d633":{"url":"https://api.omnirelay.ai"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","description":"An API key created in the OmniRelay console. The owner can view it again in the console after confirming their identity.","scopes":[],"schemeName":"bearerAuth"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"An API key created in the OmniRelay console. The owner can view it again in the console after confirming their identity.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"openapi.json"},"subdomain":"mirvos","siteName":"OmniRelay Documentation","title":"Edit images - OmniRelay Documentation","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"en":{"href":"/api-reference/images/edit-images","matchLevel":0},"cn":{"href":"/cn/api-reference/images/edit-images","matchLevel":1},"es":{"href":"/es/user-manual","matchLevel":4},"fr":{"href":"/fr/user-manual","matchLevel":4},"de":{"href":"/de/user-manual","matchLevel":4},"pt-BR":{"href":"/pt-BR/user-manual","matchLevel":4},"jp":{"href":"/jp/user-manual","matchLevel":4},"ko":{"href":"/ko/user-manual","matchLevel":4}}},"lastModified":"2026-11-02T19:46:13.823Z","originalFileLocation":"api-reference/images/edit-images.mdx","locale":"en"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Edits or extends one or more uploaded images (multipart/form-data, fields image or image[], optional mask). Billing, size tiers, n, b64_json output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.\">\u003cmeta data-mint-head name=\"application-name\" content=\"OmniRelay Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Edit images - OmniRelay Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Edits or extends one or more uploaded images (multipart/form-data, fields image or image[], optional mask). Billing, size tiers, n, b64_json output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"OmniRelay Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://omnirelay.ai/docs/api-reference/images/edit-images\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://mirvos.mintlify.site/docs/_mintlify/api/og/v2?division=Images\u0026amp;title=Edit+images\u0026amp;description=Edits+or+extends+one+or+more+uploaded+images+%28multipart%2Fform-data%2C+fields+%60image%60+or+%60image%5B%5D%60%2C+optional+%60mask%60%29.+Billing%2C+size+tiers%2C+%60n%60%2C+%60b64_json%60+output+an\u0026amp;theme=43c50d0778dfe81e3173fcea\u0026amp;signature=b657a0d1f47fd4e4b63d43d51163e1a654f92856da2b4b6ee3bb056027e60d1f\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Edit images - OmniRelay Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Edits or extends one or more uploaded images (multipart/form-data, fields image or image[], optional mask). Billing, size tiers, n, b64_json output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://mirvos.mintlify.site/docs/_mintlify/api/og/v2?division=Images\u0026amp;title=Edit+images\u0026amp;description=Edits+or+extends+one+or+more+uploaded+images+%28multipart%2Fform-data%2C+fields+%60image%60+or+%60image%5B%5D%60%2C+optional+%60mask%60%29.+Billing%2C+size+tiers%2C+%60n%60%2C+%60b64_json%60+output+an\u0026amp;theme=43c50d0778dfe81e3173fcea\u0026amp;signature=b657a0d1f47fd4e4b63d43d51163e1a654f92856da2b4b6ee3bb056027e60d1f\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/mirvos/6nifCMTl7rKBlB9L/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"OmniRelay Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3155f5\">\u003clink data-mint-head rel=\"canonical\" href=\"https://omnirelay.ai/docs/api-reference/images/edit-images\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/api-reference/images/edit-images.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://omnirelay.ai/docs/api-reference/images/edit-images\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh\" href=\"https://omnirelay.ai/docs/cn/api-reference/images/edit-images\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://omnirelay.ai/docs/api-reference/images/edit-images\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://omnirelay.ai/#organization\",\"name\":\"OmniRelay Documentation\",\"url\":\"https://omnirelay.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/mirvos/m9J_0EZqJ57fDiaC/logo.svg?fit=max\u0026auto=format\u0026n=m9J_0EZqJ57fDiaC\u0026q=85\u0026s=ca602e0318071154028ed8989c7110cc\"}},{\"@type\":\"WebSite\",\"@id\":\"https://omnirelay.ai/docs#website\",\"name\":\"OmniRelay Documentation\",\"url\":\"https://omnirelay.ai/docs\",\"publisher\":{\"@id\":\"https://omnirelay.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://omnirelay.ai/docs/api-reference/images/edit-images#webpage\",\"url\":\"https://omnirelay.ai/docs/api-reference/images/edit-images\",\"name\":\"Edit images\",\"description\":\"Edits or extends one or more uploaded images (multipart/form-data, fields image or image[], optional mask). Billing, size tiers, n, b64_json output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.\",\"dateModified\":\"2026-11-02T19:46:13.823Z\",\"isPartOf\":{\"@id\":\"https://omnirelay.ai/docs#website\"},\"breadcrumb\":{\"@id\":\"https://omnirelay.ai/docs/api-reference/images/edit-images#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://omnirelay.ai/docs/api-reference/images/edit-images#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Images\",\"item\":\"https://omnirelay.ai/docs/api-reference/images/create-images\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Edit images\",\"item\":\"https://omnirelay.ai/docs/api-reference/images/edit-images\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://omnirelay.ai/docs/api-reference/images/edit-images#apireference\",\"headline\":\"Edit images\",\"name\":\"Edit images\",\"description\":\"Edits or extends one or more uploaded images (multipart/form-data, fields image or image[], optional mask). Billing, size tiers, n, b64_json output and the long-call behaviour are the same as Create images. The whole request may be up to 20 MiB.\",\"url\":\"https://omnirelay.ai/docs/api-reference/images/edit-images\",\"mainEntityOfPage\":{\"@id\":\"https://omnirelay.ai/docs/api-reference/images/edit-images#webpage\"},\"dateModified\":\"2026-11-02T19:46:13.823Z\",\"publisher\":{\"@id\":\"https://omnirelay.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://omnirelay.ai/docs#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"OmniRelay Documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"OmniRelay Documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/docs/api-reference/images/edit-images.md","siteName":"OmniRelay Documentation","nav":{"global":null,"languages":[{"language":"en","tabs":[{"tab":"V1 Documentation","pages":[{"title":"V1 Documentation","href":""}]},{"tab":"V1 API Reference","groups":[{"group":"Service","pages":[{"title":"Health check","deprecated":null,"version":null,"openapi":"/openapi.json get /health","href":"/api-reference/service/health-check"}]},{"group":"Models","pages":[{"title":"List models","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/models","href":"/api-reference/models/list-models"}]},{"group":"Chat","pages":[{"title":"Create chat completion","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/chat/completions","href":"/api-reference/chat/create-chat-completion"}]},{"group":"Management","pages":[{"title":"List API keys","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/manage/keys","href":"/api-reference/management/list-api-keys"},{"title":"Create API key","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/manage/keys","href":"/api-reference/management/create-api-key"},{"title":"List key budgets","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/manage/keys/budgets","href":"/api-reference/management/list-key-budgets"},{"title":"Revoke API key","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/manage/keys/{id}","href":"/api-reference/management/revoke-api-key"},{"title":"Update API key","deprecated":null,"version":null,"openapi":"/openapi.json patch /v1/manage/keys/{id}","href":"/api-reference/management/update-api-key"},{"title":"Rotate API key","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/manage/keys/{id}/rotate","href":"/api-reference/management/rotate-api-key"},{"title":"Update key budget","deprecated":null,"version":null,"openapi":"/openapi.json patch /v1/manage/keys/{id}/budget","href":"/api-reference/management/update-key-budget"},{"title":"Read usage summary","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/manage/usage","href":"/api-reference/management/read-usage-summary"},{"title":"List request records","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/manage/requests","href":"/api-reference/management/list-request-records"}]},{"group":"Responses","pages":[{"title":"Create responses","deprecated":null,"version":null,"sidebarTitle":"Create responses","openapi":"/openapi.json post /v1/responses","href":"/api-reference/responses/create-response"}]},{"group":"Embeddings","pages":[{"title":"Create embeddings","deprecated":null,"version":null,"sidebarTitle":"Create embeddings","openapi":"/openapi.json post /v1/embeddings","href":"/api-reference/embeddings/create-embeddings"}]},{"group":"Images","pages":[{"title":"Create images","description":"Generates images from a text prompt with an image model (capabilities.image_generation=true). Billed per image returned at the tier of the requested `size`: longest side up to 1024 px is 1K, up to 2048 px is 2K, up to 4096 px is 4K; an omitted or `auto` size is billed as 2K. Quality does not change the price. `n` images are reserved before the call and only the images returned are charged. Images are returned as `b64_json` only. A call that takes longer than about 25 seconds answers 200 at once and sends spaces until the JSON body follows; that body may then be an error object.","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/images/generations","href":"/api-reference/images/create-images"},{"title":"Edit images","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/images/edits","href":"/api-reference/images/edit-images"}]},{"group":"Videos","pages":[{"title":"Create video task","description":"Submits a text-to-video task and returns its ID at once; poll the task until it finishes. Billed by output tokens generated (USD 25 per million list price): width x height x (24 x seconds + 1) / 1024. The cost of the largest frame at the requested resolution and duration, plus 10 percent, is held at submit; a succeeded task settles the tokens actually generated, and failed, expired or cancelled tasks are not charged. Only the documented fields are accepted.","deprecated":null,"version":null,"openapi":"/openapi.json post /api/v3/contents/generations/tasks","href":"/api-reference/videos/create-video-task"},{"title":"Get video task","deprecated":null,"version":null,"openapi":"/openapi.json get /api/v3/contents/generations/tasks/{id}","href":"/api-reference/videos/get-video-task"}]}]}]},{"language":"cn","navbar":{"links":[{"href":"https://omnirelay.ai","label":"官网"},{"href":"https://omnirelay.instatus.com","label":"服务状态"}],"primary":{"type":"button","label":"打开控制台","href":"https://omnirelay.ai/login"}},"pages":[{"title":"cn","href":"/cn/api-reference/images/edit-images"}]},{"language":"es","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Sitio web"},{"href":"https://omnirelay.instatus.com","label":"Estado"}],"primary":{"type":"button","label":"Abrir consola","href":"https://omnirelay.ai/login"}},"pages":[{"title":"es","href":"/es/user-manual"}]},{"language":"fr","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Site web"},{"href":"https://omnirelay.instatus.com","label":"État du service"}],"primary":{"type":"button","label":"Ouvrir la console","href":"https://omnirelay.ai/login"}},"pages":[{"title":"fr","href":"/fr/user-manual"}]},{"language":"de","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Website"},{"href":"https://omnirelay.instatus.com","label":"Dienststatus"}],"primary":{"type":"button","label":"Konsole öffnen","href":"https://omnirelay.ai/login"}},"pages":[{"title":"de","href":"/de/user-manual"}]},{"language":"pt-BR","navbar":{"links":[{"href":"https://omnirelay.ai","label":"Site"},{"href":"https://omnirelay.instatus.com","label":"Status"}],"primary":{"type":"button","label":"Abrir console","href":"https://omnirelay.ai/login"}},"pages":[{"title":"pt-BR","href":"/pt-BR/user-manual"}]},{"language":"jp","navbar":{"links":[{"href":"https://omnirelay.ai","label":"ウェブサイト"},{"href":"https://omnirelay.instatus.com","label":"サービス状況"}],"primary":{"type":"button","label":"コンソールを開く","href":"https://omnirelay.ai/login"}},"pages":[{"title":"jp","href":"/jp/user-manual"}]},{"language":"ko","navbar":{"links":[{"href":"https://omnirelay.ai","label":"웹사이트"},{"href":"https://omnirelay.instatus.com","label":"서비스 상태"}],"primary":{"type":"button","label":"콘솔 열기","href":"https://omnirelay.ai/login"}},"pages":[{"title":"ko","href":"/ko/user-manual"}]}]},"basePath":"","title":"Edit images - OmniRelay Documentation","buildId":"dpl_6PxPD4Fj1JDU9BJxEHvfdUmxKThw","deploymentId":"dpl_6PxPD4Fj1JDU9BJxEHvfdUmxKThw","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CASS2Vpq.js","utils-4k9fyWRu.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-UU-UueZb.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-BgJ0LOYq.js","snippetPresets-CMgzlMR-.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-BzEJegkK.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CZuQIZdk.js","shallow-Bw5arfMA.js","getApiPlaygroundDisplay-Ds834aVN.js","CodeSnippet-CKzmjw9L.js","CodeSnippets-BRpgomdp.js","Page-DvEUoD2H.js","getPastedJson-B0N-Tn76.js","icon-DASMs9nC.js","MethodPill-BA6DBLqx.js","DuplicateIcon-BMT5qfbJ.js","createIcon-CNfwVWPx.js","DynamicMarkdown-JYyBNlrJ.js","SectionHeading-BbZnmz8a.js","axios-vUo_bRtp.js","Markdown-LUU0YLpA.js","clsx-Di4ek5Ae.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-VEVWQCR4.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-CPszyu99.js"]}