Image Generation APIs for AI Agents

Access Sora 2, Veo 3.1, GPT Image, Flux 2 Pro, Grok, and more through a single API. No subscriptions — pay only for what you generate.

1API
28endpoints
$0.01–$10.00per call
2mo agoupdated
Pay per callNo API keysUSDC · Base
Get started with AgentCash →
npx agentcash try https://stablestudio.dev
StableStudio
stablestudio.dev

How It Works

Send a POST request with your prompt and parameters to any supported model endpoint. The API returns your generated image or video, and you pay only for that single generation.

Authentication uses x402 micropayments through AgentCash. There are no API keys to manage, no subscription tiers to navigate, and no monthly minimums. Each generation costs between $0 and $10 depending on the model and output complexity.

Supported Models for Image Generation

GPT Image 1 and 1.5 support both generation from text prompts and editing of existing images. Flux 2 Pro offers high-fidelity image generation and editing. Grok Image provides generation and editing endpoints.

Nano Banana and Nano Banana Pro are available for both generation and editing workflows. Each model has distinct strengths in style, resolution, and prompt adherence, so you can route requests to whichever model fits your use case.

Supported Models for Video Generation

Sora 2 and Sora 2 Pro generate video from text prompts. Veo 3.1 is available in standard and fast variants for different latency and quality tradeoffs.

Wan 2.6 and Seedance (including Seedance Fast) support both text-to-video and image-to-video workflows, letting you animate still images or generate video from scratch.

Grok Video rounds out the video model roster with its own text-to-video generation endpoint.

Job Management

Long-running generations are tracked as jobs. Use the GET /api/jobs endpoint to list all your jobs, check individual job status by ID, or soft-delete failed jobs to keep your workspace clean.

Upload endpoints let you send source images for image-to-video or editing workflows. You receive a client token for direct upload, then confirm with the final blob URL.

Use cases

Automated product image creation

Generate product mockups and lifestyle imagery programmatically by sending text descriptions to GPT Image or Flux 2 Pro endpoints, then downloading results for your e-commerce catalog.

AI agent visual content pipeline

Let your AI agent generate illustrations, diagrams, or social media graphics on demand by calling image generation endpoints as part of an automated content workflow.

Video ad generation from text briefs

Pass creative briefs as text prompts to Sora 2 or Veo 3.1 to produce short video clips for advertising, then review results via the job status endpoint.

Image-to-video animation

Upload a still image and use Wan 2.6 or Seedance i2v endpoints to animate it into a short video, useful for bringing product photos or artwork to life.

Batch image editing

Send existing images to GPT Image or Grok edit endpoints for programmatic modifications like background removal, style transfer, or object insertion at scale.

Multi-model comparison testing

Route the same prompt to multiple model endpoints in parallel to compare output quality, style, and generation time, then select the best model for production use.

Endpoints

POST
/api/upload
Get a client token for direct upload to Vercel Blob
$0.01 USD
POST
/api/generate/sora-2/generate
generate with Sora 2
$0-10.00 USD
POST
/api/generate/sora-2-pro/generate
generate with Sora 2 Pro
$0-10.00 USD
POST
/api/generate/veo-3.1/generate
generate with Veo 3.1
$0-10.00 USD
POST
/api/generate/veo-3.1-fast/generate
generate with Veo 3.1 Fast
$0-10.00 USD
POST
/api/generate/wan-2.6/t2v
t2v with Wan 2.6
$0-10.00 USD
POST
/api/generate/wan-2.6/i2v
i2v with Wan 2.6
$0-10.00 USD
POST
/api/generate/gpt-image-1/generate
generate with GPT Image 1
$0-10.00 USD
POST
/api/generate/gpt-image-1/edit
edit with GPT Image 1
$0-10.00 USD
POST
/api/generate/gpt-image-1.5/generate
generate with GPT Image 1.5
$0-10.00 USD
POST
/api/generate/gpt-image-1.5/edit
edit with GPT Image 1.5
$0-10.00 USD
POST
/api/generate/nano-banana/generate
generate with Nano Banana
$0-10.00 USD
POST
/api/generate/nano-banana/edit
edit with Nano Banana
$0-10.00 USD
POST
/api/generate/nano-banana-pro/generate
generate with Nano Banana Pro
$0-10.00 USD
POST
/api/generate/nano-banana-pro/edit
edit with Nano Banana Pro
$0-10.00 USD

Frequently asked questions

What authentication method does this API use?

Requests are authenticated via x402 micropayments and the MPP protocol through AgentCash. No API key signup is needed — you pay per generation directly from your AgentCash wallet.

How much does each generation cost?

Pricing ranges from $0 to $10 per generation depending on the model and output parameters. Simple image generations tend to cost less, while high-resolution video generations from premium models like Sora 2 Pro cost more. The upload endpoint costs $0.01.

Which image models are available?

GPT Image 1, GPT Image 1.5, Flux 2 Pro, Grok Image, Nano Banana, and Nano Banana Pro. Most support both generation from text and editing of existing images.

Which video models are available?

Sora 2, Sora 2 Pro, Veo 3.1, Veo 3.1 Fast, Wan 2.6, Seedance, Seedance Fast, and Grok Video. Wan 2.6 and Seedance variants support both text-to-video and image-to-video.

How do I track long-running video generations?

Each generation creates a job. Poll GET /api/jobs/{jobId} to check status. You can list all jobs with GET /api/jobs and clean up failed ones with DELETE /api/jobs/{jobId}.

Do I need a subscription?

No. Every generation is pay-per-use with no subscription, no monthly commitment, and no minimum spend. You only pay when you make a request.

This page is compiled from live OpenAPI specs published by each API provider. Content last reviewed Apr 20, 2026 by the AgentCash team. How we build these pages.