[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-112523":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":13,"contributorsCount":13,"subscribersCount":13,"size":13,"stars1d":13,"stars7d":13,"stars30d":15,"stars90d":13,"forks30d":13,"starsTrendScore":13,"compositeScore":16,"rankGlobal":10,"rankLanguage":10,"license":17,"archived":18,"fork":18,"defaultBranch":19,"hasWiki":20,"hasPages":18,"topics":21,"createdAt":10,"pushedAt":31,"updatedAt":32,"readmeContent":33,"aiSummary":34,"trendingCount":13,"starSnapshotCount":13,"syncStatus":35,"lastSyncTime":36,"discoverSource":37},112523,"flux-kontext-api-pt","atpfffifl97hm\u002Fflux-kontext-api-pt","atpfffifl97hm","FLUX Kontext API (`flux-kontext-pro`): model id, pricing, parameters and copy-paste examples for the OpenAI-compatible APIMart endpoint.","https:\u002F\u002Fgo.apimart.ai\u002Fk-272283",null,"Python",74,0,57,17,41.7,"Other",false,"main",true,[22,23,24,25,26,27,28,29,30],"ai-api-gateway","ai-image-api","apimart","flux-kontext","flux-kontext-api","image-api","image-editing","image-generation","text-to-image","2026-10-16 08:16:40","2026-11-14 20:12:55","# FLUX Kontext API (`flux-kontext-pro`)\n\n\u003C!-- conv-kit:v1 -->\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002Fbadges\u002Fprice.svg\" alt=\"observed unit price\"> \u003Cimg src=\"assets\u002Fbadges\u002Fbilling.svg\" alt=\"billing model\"> \u003Cimg src=\"assets\u002Fbadges\u002Fcompat.svg\" alt=\"OpenAI-compatible endpoint\">\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002F01-product-hero-perfume.jpg\" width=\"820\" alt=\"Sample render via the APIMart image API\">\n\u003C\u002Fp>\n\n> **from $0.032 per image** — um único endpoint compatível com OpenAI em `https:\u002F\u002Fapi.apimart.ai\u002Fv1`, sem plano mensal. *(observado em 2026-10-12)*\n\n**[Obter uma chave de API](https:\u002F\u002Fgo.apimart.ai\u002Fk-67fd12)** · **[Preços ao vivo](https:\u002F\u002Fgo.apimart.ai\u002Fk-0ba1a9)** · **[Página do modelo](https:\u002F\u002Fgo.apimart.ai\u002Fk-272283)** · [⚡ Início rápido em 60 segundos](#quickstart)\n\n**Por que os times usam FLUX Kontext (`flux-kontext-pro`) via APIMart**\n\n- **Uma chave, o catálogo inteiro.** A mesma base URL `https:\u002F\u002Fapi.apimart.ai\u002Fv1` e o mesmo cabeçalho `Authorization` alcançam FLUX Kontext (`flux-kontext-pro`) e mais de 300 modelos de imagem, vídeo e linguagem — troque o campo `model`, não o seu cliente.\n- **Mínimo de $1, pague conforme o uso.** Sem assinatura e sem plano pré-pago para dimensionar antes: recarregue a partir de $1 e gaste em chamadas.\n- **A cobrança volta na resposta.** Toda tarefa concluída informa o valor cobrado (`cost` \u002F `credits_cost`); uma tarefa marcada como `failed` é reembolsada.\n- **Assíncrono por design.** Envie, pegue o `task_id`, consulte `GET \u002Fv1\u002Ftasks\u002F{id}` — batching e retries são trabalho comum de fila, não uma integração sob medida.\n\n\u003C!-- \u002Fconv-kit:v1 -->\n\n\n\nFLUX Kontext edits and generates images from a prompt or a reference, priced per image.\n\n## Model id and routes\n\n| Route | `model` value | Billing | Notes |\n| --- | --- | --- | --- |\n| Per-image | `flux-kontext-pro` | per delivered image, by resolution | see the [model page](https:\u002F\u002Fgo.apimart.ai\u002Fk-272283) for the exact tiers |\n\nEndpoint: `POST https:\u002F\u002Fapi.apimart.ai\u002Fv1\u002Fimages\u002Fgenerations`, then poll `GET \u002Fv1\u002Ftasks\u002F{task_id}`.\n\n## Pricing\n\n\u003C!-- pricing:model:start -->\n| Output | List price | Effective price |\n| --- | --- | --- |\n| default | 0.04 | 0.032 |\n\n\n\u003C!-- pricing:model:end -->\n\nPrices are a snapshot; the [pricing page](https:\u002F\u002Fgo.apimart.ai\u002Fk-0ba1a9) and [`data\u002Fmodel.json`](data\u002Fmodel.json) are refreshed by CI, and a completed task reports the exact amount in its `cost` field.\n\n## Request parameters\n\n| Field | Type | Default | Notes |\n| --- | --- | --- | --- |\n| `model` | string | required | the model id shown in the route table above |\n| `prompt` | string | required | what to generate, or what to change when editing |\n| `size` | string | `auto` \u002F `1:1` | aspect ratio, or `auto` where the route supports it |\n| `resolution` | string | `1K` | output resolution tier — cost scales with it |\n| `n` | integer | `1` | number of images per task, where the route allows more than one |\n| `image_urls` | string[] | — | reference images as public HTTP(S) URLs or base64 data URLs |\n| `nsfw_check` | boolean | `false` | runs `omni-moderation-latest` before submitting |\n\nThe table lists the fields accepted by the APIMart `images\u002Fgenerations` endpoint. Check the [model page](https:\u002F\u002Fgo.apimart.ai\u002Fk-272283) for anything this model adds on top.\n\n## Quickstart\n\n```bash\ncurl --request POST --url https:\u002F\u002Fapi.apimart.ai\u002Fv1\u002Fimages\u002Fgenerations \\\n  --header \"Authorization: Bearer $APIMART_API_KEY\" --header 'Content-Type: application\u002Fjson' \\\n  -d '{\"model\":\"flux-kontext-pro\",\"prompt\":\"A bamboo forest at sunrise, slow push-in\",\"size\":\"1:1\",\"resolution\":\"1K\"}'\n```\n\n```python\nimport os, time, requests\n\nBASE = \"https:\u002F\u002Fapi.apimart.ai\u002Fv1\"\nHEADERS = {\"Authorization\": f\"Bearer {os.environ['APIMART_API_KEY']}\", \"Content-Type\": \"application\u002Fjson\"}\n\ncreated = requests.post(f\"{BASE}\u002Fimages\u002Fgenerations\", headers=HEADERS, timeout=60, json={\n    \"model\": \"flux-kontext-pro\", \"prompt\": \"A bamboo forest at sunrise, slow push-in\",\n}).json()\ntask_id = created[\"data\"][\"id\"]\n\nwhile True:\n    task = requests.get(f\"{BASE}\u002Ftasks\u002F{task_id}\", headers=HEADERS, timeout=60).json()[\"data\"]\n    if task[\"status\"] in (\"completed\", \"failed\"):\n        break\n    time.sleep(5)\nprint(task.get(\"cost\"), task[\"result\"][\"images\"][0][\"url\"])\n```\n\nRunnable versions: [`examples\u002F`](examples). The task lifecycle is `pending → processing → completed | failed`.\n\n## FAQ\n\n**Qual é o id do modelo FLUX Kontext?**\n\n`flux-kontext-pro`. Veja a tabela de rotas acima.\n\n**Como é a cobrança?**\n\n**from $0.032 per image**. A tarefa concluída informa o valor exato no campo `cost`; uma tarefa com falha é reembolsada.\n\n**How do I get a key?**\n\nUse the [Get an API key](https:\u002F\u002Fgo.apimart.ai\u002Fk-67fd12) link — $1 minimum top-up, no plan required.\n\n\u003C!-- related-repos:auto -->\n## Related repositories\n\n- **Same model, this language** — the other half of this pair: [flux-kontext-prompts-pt](https:\u002F\u002Fgithub.com\u002Fatpfffifl97hm\u002Fflux-kontext-prompts-pt)\n- **Same model, other languages** — 9 more language builds: 中文 `flux-kontext-api-cn` · Deutsch [flux-kontext-api-de](https:\u002F\u002Fgithub.com\u002Fsjprcowvapx3\u002Fflux-kontext-api-de) · Español [flux-kontext-api-es](https:\u002F\u002Fgithub.com\u002Ftrfdg5acl147p\u002Fflux-kontext-api-es) · Français [flux-kontext-api-fr](https:\u002F\u002Fgithub.com\u002Fbmoefvec\u002Fflux-kontext-api-fr) · Relay\u002Fgateway `flux-kontext-api-gateway` · Bahasa [flux-kontext-api-id](https:\u002F\u002Fgithub.com\u002Flnbqjduxe\u002Fflux-kontext-api-id) · 日本語 [flux-kontext-api-ja](https:\u002F\u002Fgithub.com\u002Fuy47nxvbx\u002Fflux-kontext-api-ja) · 한국어 [flux-kontext-api-ko](https:\u002F\u002Fgithub.com\u002Fgjkqh-v\u002Fflux-kontext-api-ko) · Русский [flux-kontext-api-ru](https:\u002F\u002Fgithub.com\u002Fz9umz0nkurue8\u002Fflux-kontext-api-ru)\n- **More models in this language** — [midjourney-api-pt](https:\u002F\u002Fgithub.com\u002Fl-ca0\u002Fmidjourney-api-pt) · [gemini-2-5-flash-image-preview-api-pt](https:\u002F\u002Fgithub.com\u002Fycx8l0\u002Fgemini-2-5-flash-image-preview-api-pt) · [nano-banana-api-pt](https:\u002F\u002Fgithub.com\u002Ferujt71i1lx\u002Fnano-banana-api-pt) · [gemini-3-1-flash-image-preview-api-pt](https:\u002F\u002Fgithub.com\u002Fhutjwux0nt9h\u002Fgemini-3-1-flash-image-preview-api-pt) · [nano-banana-2-api-pt](https:\u002F\u002Fgithub.com\u002Fydkd8kdkl8n\u002Fnano-banana-2-api-pt) · [gemini-3-pro-image-preview-api-pt](https:\u002F\u002Fgithub.com\u002Fqss2d-66qb2n7\u002Fgemini-3-pro-image-preview-api-pt)\n- **Topic hubs** — every build of this model, all languages: [flux-kontext](https:\u002F\u002Fgithub.com\u002Ftopics\u002Fflux-kontext) · [flux-kontext-api](https:\u002F\u002Fgithub.com\u002Ftopics\u002Fflux-kontext-api)\n\nThis repository is one build in a cross-linked set of API guides for the same model family; each language build links back to the others.\n\u003C!-- \u002Frelated-repos:auto -->\n\n## Attributed links (how this repository is measured)\n\n| Purpose | Attributed link | Target |\n| --- | --- | --- |\n| Model page | \u003Chttps:\u002F\u002Fgo.apimart.ai\u002Fk-272283> | `apimart.ai\u002Fpt\u002Fmodel\u002Fflux-kontext` |\n| Live pricing | \u003Chttps:\u002F\u002Fgo.apimart.ai\u002Fk-0ba1a9> | `apimart.ai\u002Fpt\u002Fpricing` |\n| Get an API key | \u003Chttps:\u002F\u002Fgo.apimart.ai\u002Fk-67fd12> | `apimart.ai\u002Fpt\u002Fkeys` |\n\nOutbound APIMart links are minted through the promo link API; hand-made tracking parameters are rejected by\n`tools\u002Fcheck_links.py` in CI.\n\n## Disclosure\n\nFLUX Kontext is a third-party model served through APIMart; this repository documents how to call it and publishes\nmodel ids and prices, and does not claim official status. Model names, prices and documentation belong to their\nrespective owners.\n\n## License\n\nMIT — see [LICENSE](LICENSE).\n","FLUX Kontext API 是一个基于 APIMart 平台的 OpenAI 兼容图像生成与编辑服务接口，专为按需调用设计。它支持通过统一 endpoint（`\u002Fv1\u002Fimages\u002Fgenerations`）提交文生图或图生图任务，提供 `flux-kontext-pro` 模型的完整参数控制（如 prompt、size、resolution、image_urls）、异步任务轮询机制、精确到单图的实时计费反馈（含 `cost` 字段），以及免订阅、最低 $1 充值的用量付费模式。适用于需要灵活接入高质量图像模型、避免长期合约、重视成本透明性与多模型可扩展性的 AI 应用开发、内容自动化及低代码集成场景。",2,"2026-11-24 04:43:43","CREATED_QUERY"]