For more details, go to: https://platform.openai.com/docs/api-reference/images/create Given a prompt and/or an input image, the model will generate new images.1792x1024 (Dalle3 only)1024 × 1792 (Dalle3 only)1024x1024 (Dalle2, Dalle3)512x512 (Dalle2 only)256x256 (Dalle2 only)Related Guide: Image Generation Create an image according to the prompts.
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Header Params
Authorization
string
required
Example:
Bearer sk-xxxxxxxxxxxxxxxxxxxxxxxxx
Body Params application/json
model
string
required
Model name.
Example:
dall-e-3
prompt
string
required
A text description of the desired image. Maximum length is 1000 characters.
Example:
cat
n
string
required
The number of images to generate. Must be between 1 and 10.
Example:
1
size
string
required
The size of the generated image. Must be one of 256x256, 512x512 or 1024x1024.
{"created":1699693501,"data":[{"revised_prompt":"An adorable anime-style depiction of a girl. She has bright, expressive eyes, and long, flowing hair. Her outfit is a traditional seifuku school uniform with a sailor collar, pleated skirt, and knee-high socks. She is emanating positivity, with a wide smile on her face and cheerful, sparkling eyes. The color palette is soft and pastel, with a blend of soothing blues, gentle pinks, and calming whites. The background is filled with cherry blossom petals gently floating in the wind, adding a serene, peaceful atmosphere to the overall scene.","url":"https://oaidalleapiprodscus.blob.core.windows.net/private/org-EDfhgsr4pmhirnnOUk3lXiHM/user-GSu4YoazFbISNTWmskEcrxQ5/img-lR4i8UJMvYeODOOebmRupWgO.png?st=2023-11-11T08%3A05%3A01Z&se=2023-11-11T10%3A05%3A01Z&sp=r&sv=2021-08-06&sr=b&rscd=inline&rsct=image/png&skoid=6aaadede-4fb3-4698-a8f6-684d7786b067&sktid=a48cca56-e6da-484e-a814-9c849652bcb3&skt=2023-11-10T21%3A40%3A03Z&ske=2023-11-11T21%3A40%3A03Z&sks=b&skv=2021-08-06&sig=Xwu5fpx7c0067pEZzT2ZxQYzahYdofmb0VCyoXVlzH8%3D"}]}