# generate_image (https://sellersheetai.com/docs/mcp-api/tools/generate_image)

> Generate images from a text prompt — listing photos, A+ banners, lifestyle and infographic shots, icons.

Access: **WRITE** · toolset sellersheet · family null

Priced per delivered image (credits_quote gives the number; HTTP 402 with error_code insufficient_credits when the balance is short — top up at sellersheetai.com/billing); a failure is refunded.

## Call it

MCP tool call:

```json
{
  "name": "generate_image",
  "arguments": {
    "prompt": "<prompt>"
  }
}
```

Tool API (early access — contact us):

```bash
curl -X POST https://api.sellersheetai.com/api/v1/tools/generate_image \
  -H "Authorization: Bearer $SELLERSHEET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"prompt":"<prompt>"}'
```

## Arguments

| Name | Type | Required | Description |
|---|---|---|---|
| `prompt` | string | yes | the image description. |
| `provider` | string |  | 'openai' (default; gpt-image-2 — precise, legible text) \| 'nanobanana' (Gemini — fast, search-grounded; renders and is priced at the default canvas, so size, quality and background apply to openai only) \| 'both'. |
| `size` | string |  | '1024x1024' (default, the same canvas Studio uses) \| '2048x2048' (Amazon zoom headroom; costs more) \| '1024x1536' \| '1536x1024' \| 'auto'. |
| `quality` | string |  | 'low' \| 'medium' \| 'high' (default) \| 'auto'. |
| `n` | integer |  | variations, 1–4 (default 1). |
| `background` | string |  | 'auto' (default) \| 'opaque'. gpt-image-2 has no transparent background — 'transparent' is treated as 'auto' and the response carries background_note; generate opaque and remove the background downstream. |
| `output_format` | string |  | 'png' \| 'jpeg' \| 'webp'; omit and the server decides (currently jpeg). |
| `use_search_grounding` | boolean |  | Google Search grounding (nanobanana); default false. |
| `synthetic_performer` | boolean |  | Amazon's contains-synthetic-performer disclosure (XMP metadata in the upload); omit and the server infers it from the prompt; true or false overrides. set_synthetic_performer toggles it later without regenerating. |
| `store` | string |  | the store ref `<store>-<CC>` (name-country, e.g. 'myStore-US') — one of get_user_context's store_refs, verbatim. Required. |
| `parent_sku` | string |  | the family SKU; defaults to sku. |
| `sku` | string |  | the child SKU. Required. |
| `slot` | string |  | the Image Library slot: 's0'–'s8' (PDP) or 'a1'–'a5' / 'p1'–'p5' (A+). Required — a call missing store, sku or slot is refused (400) before billing. |
| `filename_prefix` | string |  | upload filename prefix. |

## Result

- `data.images` — one entry per image — cdn_url (saved at store/parent_sku/sku/slot), thumbnail_url, provider, model, revised_prompt (how the model rewrote the prompt — mention it), background_note (relay it when set), or error. An entry with r2_upload_error has no cdn_url; its image arrives as an inline image block.
- `data.credits.charged / data.credits.balance` — this call's cost and what is left.