Skip to content
Catalog

cn8/image-from-text

Turn a text prompt into finished images in a single request. Pick a model with the

Learn more about Image from Text
ImagesyncInstant previewimagegenerationtext-to-image

Describe your image

Style
Model
Aspect ratio
Quality
Images
Avoid (optional)

Result

Your images show up here

Pick a style and a model — prices are per image, shown on the button.

Overview

Turn a text prompt into finished images in a single request. Pick a model with the model field — Google Imagen, OpenAI GPT Image, Black Forest Labs FLUX.2, Stability AI, Ideogram 4.0 or Leonardo — then add a style preset, optional negative prompts, aspect ratio, quality and how many images you want (1–4). Responses are synchronous — you get hosted image URLs back directly, with no polling.

Call List Image Models (media-image-models) for the live catalog: every model's provider, per-image price and supported aspect ratios.

Pricing is per image and depends on the model — from 3 credits (FLUX.2 Klein) to 20 credits (Ideogram 4.0 Quality). The default model flash (Imagen 3 Fast) is 4 credits/image.

Key capabilities

Six providers, one API

The model field picks the provider: Imagen (flash, pro, imagen4-fast, imagen4), OpenAI (gpt-image-2), FLUX (flux-2-klein-4b/9b, flux-2-pro, flux-2-max), Stability (stable-core, stable-sd35-*, stable-ultra), Ideogram (ideogram-4-turbo/-4/-4-quality) or Leonardo (leonardo-lucid-*, leonardo-phoenix).

Live model catalog

GET media-image-models (free) returns every model with its per-image price and aspect ratios — ideal for building a model picker.

25 style presets

From photorealistic to anime, cinematic, ukiyo-e, pixel-art, vaporwave, studio-ghibli, surreal and art-deco — call media-image-styles for the full list with descriptions.

Configurable aspect ratio & quality

aspect_ratio: 1:1 (default), 16:9, 9:16 or 4:3. quality: standard or hd (provider-dependent tiers).

Multiple images per call

Request 1–4 images per call. You're billed only for the images actually returned, at the selected model's per-image rate.

Synchronous — no polling

Images come back in the response as hosted URLs. No async job, no polling required.

When to use it

Marketing & social posts

Generate hero images for blog posts, ads, and social campaigns from a brief prompt + style preset.

Product mockups

Quickly visualise concepts before commissioning real photography.

Editorial illustrations

Article headers, podcast cover art, newsletter visuals — pick a style preset matching your brand.

Game / app assets

Background art, character concepts, UI illustrations — multiple aspect ratios supported.

Input & output

input

prompt + optional model (default: flash), style preset, negatives, aspect_ratio, quality, quantity

JSON body

output

An array of generated images (hosted URLs) with id, url and index — plus the style, model, aspect_ratio, quality and generation time.

JSON

Guides & tips

Picking a style preset

Each style preset adds descriptive text to your prompt to steer the look. Pick by intent:

  • photorealistic / cinematic — realism, photography, ads
  • anime / studio-ghibli / digital-art — illustration & character art
  • oil-painting / watercolor / impressionism / ukiyo-e — fine-art styles
  • 3d-render / fantasy-art / cyberpunk / steampunk — concept art
  • minimalistic / abstract / art-deco — graphic design / posters
  • pixel-art / vaporwave — retro / synthwave aesthetic
  • gothic / surreal / film-noir — moody / atmospheric

Choosing a model / provider

Call media-image-models for the live list. Snapshot:

ProviderModels$/imageNotes
Imagen (Google)flash (default), pro, imagen4-fast, imagen40.04 / 0.08 / 0.06 / 0.12Balanced default; imagen4 for top Imagen quality.
OpenAIgpt-image-20.10Strong prompt following & text rendering.
FLUX (BFL)flux-2-klein-4b, flux-2-klein-9b, flux-2-pro, flux-2-max0.03 / 0.03 / 0.06 / 0.14Klein = cheapest option overall.
Stabilitystable-core, stable-sd35-flash/-medium/-turbo/-large, stable-ultra0.05–0.16SD 3.5 family + Ultra tier.
Ideogramideogram-4-turbo, ideogram-4, ideogram-4-quality0.06 / 0.12 / 0.20Excellent typography/text-in-image.
Leonardoleonardo-lucid-origin, leonardo-lucid-realism, leonardo-phoenix0.08 / 0.08 / 0.10Stylised & realistic art looks.

Rules of thumb: iterate on flux-2-klein-4b (3 credits) or flash (4 credits); text-heavy designs on Ideogram; finals on imagen4, flux-2-max or ideogram-4-quality.

Using negative prompts

Provide a comma-separated list of things to avoid. Common patterns:

  • Photo realism: low quality, blurry, watermark, text, distorted
  • Faces: extra fingers, malformed hands, asymmetric eyes
  • Art: signature, frame, border, cropped

Negatives reduce common artefacts but don't guarantee they're removed entirely.

Specs

Latency
~5-15s for flash; ~10-30s for pro, depending on how many images you request
Async
false
Rate Limit
60 req/min per API key
Max Input
Long prompts are supported

Schema

Request body

promptrequiredstring

Text description of the image to generate.

stylestring · default: photorealistic

Style preset key (see media-image-styles for the full list of 25).

enum: photorealistic, anime, digital-art, oil-painting, watercolor, 3d-render, sketch, cinematic, cyberpunk, steampunk, minimalistic, vintage, futuristic, abstract, pop-art, impressionism, ukiyo-e, pixel-art, vaporwave, studio-ghibli, fantasy-art, gothic, surreal, film-noir, art-deco

negativesstring

Comma-separated list of things to avoid (e.g. 'low quality, blurry, watermark').

aspect_ratiostring · default: 1:1

Output aspect ratio.

enum: 1:1, 16:9, 9:16, 4:3

qualitystring · default: standard

Output quality tier: 'low' | 'standard' | 'hd'. Interpretation is provider-dependent (OpenAI maps to low/medium/high; on Imagen, hd enables prompt enhancement).

enum: low, standard, hd

quantityinteger · default: 1

Number of images to generate (clamped to 1-4).

modelstring · default: flash

Picks the provider and model — use a model_id / call_as / alias from media-image-models. Imagen: 'flash' (default, 4 credits), 'pro' (8 credits), 'imagen4-fast' (6 credits), 'imagen4' (12 credits). OpenAI: 'gpt-image-2' (10 credits). FLUX: 'flux-2-klein-4b'/'−9b' (3 credits), 'flux-2-pro' (6 credits), 'flux-2-max' (14 credits). Stability: 'stable-core' (6 credits), 'stable-sd35-flash/-medium/-turbo/-large', 'stable-ultra' (5 credits-0.16). Ideogram: 'ideogram-4-turbo' (6 credits), 'ideogram-4' (12 credits), 'ideogram-4-quality' (20 credits). Leonardo: 'leonardo-lucid-origin'/'−realism' (8 credits), 'leonardo-phoenix' (10 credits).

Response

data.imagesarray

Array of {id, url, index} per generated image.

data.images[].idstring

Per-image identifier.

data.images[].urlstring

Hosted URL to the image file.

data.images[].indexinteger

0-based index within this batch of images.

data.quantity_requestedinteger

Number of images you asked for (1–4).

data.quantity_generatedinteger

Number of images returned — this is what you're billed for.

data.modelstring

Resolved model id (e.g. flash, gpt-image-2, flux-2-pro).

data.providerstring

Provider the model belongs to (imagen / openai / bfl / stability / ideogram / leonardo).

data.stylestring

Style preset applied.

data.aspect_ratiostring

Aspect ratio used.

data.qualitystring

Quality tier used.

data.promptstring

The prompt you sent, returned for reference.

data.generation_time_secondsnumber

How long generation took, in seconds (informational).

cost.unitsnumber

Number of images billed (equals data.quantity_generated).

cost.unit_pricenumber

The selected model's per-image price — this is the rate you're billed at.

cost.tokensnumber

Total charged for this call (units × unit_price).

cost.balancenumber

Your remaining credit balance after this call.

Pricing

Per image, at the model's own rate. Listing models and style presets is free. media-image-models always returns the live prices.

ServiceUnitPrice
Imagen — flash (default)item4 credits/image
Imagen — pro / imagen4-fast / imagen4item8 credits / 6 credits / 12 credits per image
OpenAI — gpt-image-2item10 credits/image
FLUX — flux-2-klein-4b/9b · flux-2-pro · flux-2-maxitem3 credits · 6 credits · 14 credits per image
Stability — stable-core · sd35-flash/-medium/-turbo/-large · stable-ultraitem6 credits · 5 credits-0.13 · 16 credits per image
Ideogram — ideogram-4-turbo · ideogram-4 · ideogram-4-qualityitem6 credits · 12 credits · 20 credits per image
Leonardo — lucid-origin / lucid-realism · phoenixitem8 credits · 10 credits per image
List Image Models / Image StylesitemFree

You're billed for the number of images actually returned (data.quantity_generated) × the selected model's per-image rate.

If you request 4 images and only 2 come back, you're billed for 2.

Cheapest: flux-2-klein (3 credits). Default: flash (4 credits). Premium: ideogram-4-quality (20 credits).

FAQ

Related models