generate_image
Generate an image from a text prompt. Returns JSON with image URL. Models: Grok Imagine 2 (fast creative generation, 100 sats), Seedream 5 Pro (most permissive content policy, 150 sats at 1K / 300 at 2K), GPT Image 2.6 (ranked #1 on the Artificial Analysis text-to-image leaderboard as of November 2026 at its maximum quality setting; this API uses the automatic setting; 1200 sats, default). Supports img2img with optional base64 input. Optional aspectRatio (default 1:1) works on every model tier and does not change the price. Stable endpoints — models upgrade automatically as SOTA evolves. Pay per request with Bitcoin Lightning — no API key or signup needed. Requires create_payment with toolName='generate_image'.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Text prompt describing the image | |
| modelId | No | Optional. Omit for default (best) model. | |
| paymentId | Yes | Valid payment ID (must be paid) | |
| resultKey | No | Optional. The resultKey from create_payment. Send it with the same arguments to get this result again after a timeout. | |
| aspectRatio | No | Optional output shape, default 1:1. Same price for every shape. | |
| imageBase64 | No | Optional base64 image for img2img generation |