dall-e-2

by OpenAIImage

dall-e-2 is available through TTAPI. OpenAI image generation through TTAPI, with fixed-price GPT Image models and official-channel DALL·E 2 and DALL·E 3 support.

InputPrompttext
Models5available
FlowAsyncresult URL
Price20% offofficial
Teddy bears using 1990s computers while conducting AI research underwaterUnderwater AI researchExample 01
A metallic robot hand using a pencil to draw another robotic handRobot artistExample 02
Close-up portrait of a monkey wearing a white astronaut helmet in spaceMonkey astronautExample 03
Tiny astronomer studying glowing constellations inside a glass terrarium observatoryTerrarium observatoryExample 04
Examples

Prompt to image, in context

01 · Underwater AI researchdall-e-2
Prompt

Teddy bears working on new AI research underwater with 1990s technology

02 · Robot artistdall-e-2
Prompt

A photo of a robot hand drawing, digital art

03 · Monkey astronautdall-e-2
Prompt

A close-up portrait of a monkey astronaut in a white spacesuit, floating against a deep blue star field

Capabilities

What you can build with dall-e-2

Prompt driven generation

Submit a concise prompt and get production-ready image output through one TTAPI job.

Core controls only

Keep integration simple with prompt, model, output settings, and callback handling.

Async result flow

Use polling or webhook callbacks so long-running generations do not block your UI.

Ready for product UI

Return OpenAI Image results that can be displayed, stored, or passed into downstream workflows.

Pricing

Per-action, in quota

Usage is metered in quota by model, action, and output settings.

Official image generationOfficial pricing
ModelTTAPI billingUnit
dall-e-220% off official pricing/ image
API request

Headers and submit parameters

Use the endpoint below with your TTAPI key and the request fields shown.

POSThttps://api.ttapi.io/v1/images/generations

Headers

TT-API-KEYstringrequired

Your TTAPI API key.

Content-Typestringrequired

Use application/json.

Body

promptstringrequired

Image description, up to 1,000 characters.

modelenumrequired

Use dall-e-2.

nintegeroptional

Number of images to generate, from 1 to 10. Defaults to 1.

qualityenumoptional

DALL·E 2 supports standard quality.

response_formatenumoptional

Return url or b64_json. Generated URLs remain valid for 60 minutes.

sizeenumoptional

256x256, 512x512, or 1024x1024.

userstringoptional

A unique identifier for the end user, used for abuse monitoring.

Open the official TTAPI documentation
Integrate

From key to first result

Copy the resolved endpoint, authentication headers, and request body for this model.

curl --request POST \
  --url https://api.ttapi.io/v1/images/generations \
  --header 'TT-API-KEY: $TTAPI_KEY' \
  --header 'Content-Type: application/json' \
  --data '{"prompt":"Teddy bears working on new AI research underwater with 1990s technology","model":"dall-e-2","n":1,"quality":"standard","response_format":"url","size":"1024x1024","user":"ttapi-demo"}'