# Imagen 4 MCP and API - Text to image by Google | FlyMy.AI

> Google Imagen 4 creates realistic, high-quality images from a text prompt, up to four per run at 1K or 2K, in five aspect ratios.

Page: https://flymy.ai/mcp/models/imagen-4/

MCP / Models / Image generation

# Imagen 4 MCP: photorealistic images with no API key

Google Imagen 4 creates realistic, high-quality images from a text prompt, up to four per run at 1K or 2K, in five aspect ratios. Run it from Claude Code, Codex, Cursor or any MCP client through one FlyMy.AI MCP, or call its API.

[Use Imagen 4](https://flymy.ai/mcp/models/imagen-4/#start) [Inputs and price](https://flymy.ai/mcp/models/imagen-4/#inputs)

No API key, $0.04 / run, Text to image, Google, Commercial use

$ YOUR NEXT RUN

Claude Code, Codex, Cursor, Any agent

## Use Imagen 4 in your assistant

Paste this prompt into Claude Code, Codex, Cursor or any agent. It reads the guide and helps you connect.

```
Read https://flymy.ai/skill.md and https://flymy.ai/mcp/models/imagen-4.md. Help me connect the FlyMy.AI MCP to this assistant, then run Imagen 4 (flymyai/imagen-4) for this task: Generate a 9:16 product photo of a cozy reading nook with a green armchair with Imagen 4 at 2K.
```

[Open FlyMy.AI](https://app.flymy.ai/new-agent) [Download brief](https://flymy.ai/mcp/models/imagen-4.md)

## What Imagen 4 does

Imagen 4 is Google's text-to-image model for realistic photos and clean compositions. Set number_of_images (1 to 4), image_size (1K or 2K), aspect_ratio (1:1, 3:4, 4:3, 9:16 or 16:9) and person_generation (dont_allow or allow_adult). Every image carries Google's SynthID watermark. Imagen 4 Fast and Imagen 4 Ultra take the same inputs.

## Imagen 4 inputs

Every input of `flymyai/imagen-4` as its live schema lists them. Returns `images` (file).

| Input | Type, values and default |
|---|---|
| [#](https://flymy.ai/mcp/models/imagen-4/#input-prompt) `prompt` | string required |
| [#](https://flymy.ai/mcp/models/imagen-4/#input-number_of_images) `number_of_images` | integer optional Allowed: 1 to 4 Default: `1` |
| [#](https://flymy.ai/mcp/models/imagen-4/#input-image_size) `image_size` | string optional Allowed: 1K, 2K |
| [#](https://flymy.ai/mcp/models/imagen-4/#input-aspect_ratio) `aspect_ratio` | string optional Allowed: 1:1, 3:4, 4:3, 9:16, 16:9 |
| [#](https://flymy.ai/mcp/models/imagen-4/#input-person_generation) `person_generation` | string optional Allowed: dont_allow, allow_adult |

## Ask your agent

Requests to paste as they are, once the FlyMy.AI MCP is connected.

**“Generate a 9:16 product photo of a cozy reading nook with a green armchair with Imagen 4 at 2K.”** runs `flymyai/imagen-4`

**“Make three versions of a poster for a coffee shop opening with Imagen 4 in one run and send me the links.”** runs `flymyai/imagen-4`

**“Create a 1970s travel poster illustration of rain on a neon-lit street, a cyclist passing with Imagen 4.”** runs `flymyai/imagen-4`

## Imagen 4 price

$0.04 per run. A run at the default settings costs $0.04. Billed to your FlyMy.AI balance; no seats, no subscription and no minimum.

[See usage pricing →](https://flymy.ai/pricing/)

## Call Imagen 4 from code

The same model, from an agent or from your own code. Keys stay in your FlyMy.AI account.

### From an agent, through the MCP

The agent calls `get_model_schema`, then `run_model` with:

```
{
  "endpoint_id": "flymyai/imagen-4",
  "input": {
    "prompt": "A ceramic mug on a sunlit kitchen counter, product photo"
  }
}
```

### From your code, over HTTP

Form fields, not JSON; files go as uploads or public URLs. The answer is a `prediction_id`; read the result at `https://api.flymy.ai/api/v1/flymyai/imagen-4/predict/async/result/?request_id=<prediction_id>`.

```
curl -X POST https://api.flymy.ai/api/v1/flymyai/imagen-4/predict/async/ \
  -H "X-API-KEY: $FLYMYAI_API_KEY" \
  -F 'prompt=A ceramic mug on a sunlit kitchen counter, product photo'
```

## Questions about Imagen 4

**Do I need a Google API key for Imagen 4?**

No. Imagen 4 runs on FlyMy.AI's account, so you need no Google key or plan: sign in to FlyMy.AI once and each run is billed to your FlyMy.AI balance.

**How much does Imagen 4 cost?**

$0.04 per run. There is no subscription or minimum; the price comes from FlyMy.AI billing and was checked on 2026-11-09.

**How do I use Imagen 4 in Claude Code, Codex or Cursor?**

Add the FlyMy.AI MCP with one command and sign in, then ask in plain words, for example: "Generate a 9:16 product photo of a cozy reading nook with a green armchair with Imagen 4 at 2K." Your agent reads the inputs with get_model_schema and runs flymyai/imagen-4 with run_model.

**What does Imagen 4 need as input?**

Imagen 4 requires prompt; it also takes 4 optional inputs, each listed on this page with its allowed values and default.

**Can I call Imagen 4 from my own code?**

Yes. Send form fields to https://api.flymy.ai/api/v1/flymyai/imagen-4/predict/async/ with your FlyMy.AI API key in the X-API-KEY header.

## More image generation models

Text to image: product shots, ads, posters and illustrations from a prompt, many with reference images.

### Nano Banana 2.1

Gemini's newest image model: 14 references, up to 4K, with adjustable thinking.

Text and image to image / from $0.0336 / image

Link: https://flymy.ai/mcp/models/nano-banana-2-1/

### Nano Banana 2 Lite

The cheapest Nano Banana 2 tier: 1K images in volume with the same prompt understanding.

Text and image to image / from $0.0376 / run

Link: https://flymy.ai/mcp/models/nano-banana-2-lite/

### Nano Banana 2

Gemini 3.1 Image: up to 10 images per run at up to 4K, with optional web search.

Text and image to image / from $0.071 / run

Link: https://flymy.ai/mcp/models/nano-banana-2/

### Nano Banana Pro

Gemini 3 Pro Image for posters, packaging and logos where the words must be right.

Text and image to image / from $0.15 / run

Link: https://flymy.ai/mcp/models/nano-banana-pro/

### Nano Banana

The original Gemini 2.5 image model: quick drafts and conversational edits.

Text and image to image / $0.039 / run

Link: https://flymy.ai/mcp/models/nano-banana/

### Nano Banana 2 Flex

Nano Banana 2 on Google's lower-priced flex tier, for batches where cost matters most.

Text and image to image / from $0.0355 / run

Link: https://flymy.ai/mcp/models/nano-banana-2-flex-inference/

## Go to the source

[Imagen 4 in the playground →](https://app.flymy.ai/models/flymyai/imagen-4), [Model endpoints in the docs →](https://docs.flymy.ai/api/models-endpoints), [Image generation guide →](https://docs.flymy.ai/guides/generate-images), [Every model on FlyMy.AI →](https://flymy.ai/mcp/models/), [Every MCP in the catalog →](https://flymy.ai/mcp/#catalog), [Usage pricing →](https://flymy.ai/pricing/)

From the FlyMy.AI model catalog of 2026-11-09: inputs from the model's live schema, prices from FlyMy.AI billing. Requests are examples to paste, not recorded runs.

---

For agents: the FlyMyAI operating guide (sign up, connect, run models, tools and agents) is https://flymy.ai/skill.md, and https://flymy.ai/llms.txt lists the other pages and the documentation.
