DALL-E 2 - Image Variator
Create variations of existing images using OpenAI's DALL-E 2 model.
Endpoint
Request Body
The request must include the following parameters:
Parameter | Type | Required | Description |
---|---|---|---|
type | string | Yes | Feature type identifier. Must be IMAGE_VARIATOR |
model | string | Yes | AI model identifier. Must be dall-e-2 |
promptObject | object | Yes | Feature-specific parameters |
Prompt Object Parameters
Parameter | Type | Required | Description |
---|---|---|---|
imageUrl | string | Yes | Path to the image for variation |
n | number | Yes | Number of variations to generate |
size | string | Yes | Generated image size. Options: 1024x1024 , 512x512 , 256x256 |
Example Request
- JavaScript
- cURL
- Python
fetch('https://api.1min.ai/api/features', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'API-KEY': 'YOUR_API_KEY'
},
body: JSON.stringify({
type: 'IMAGE_VARIATOR',
model: 'dall-e-2',
promptObject: {
imageUrl: 'development/images/2025_02_14_17_41_01_211_images.jpeg',
n: 1,
size: '1024x1024'
}
})
})
curl --location 'https://api.1min.ai/api/features' \
--header 'API-KEY: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"type": "IMAGE_VARIATOR",
"model": "dall-e-2",
"promptObject": {
"imageUrl": "development/images/2025_02_14_17_41_01_211_images.jpeg",
"n": 1,
"size": "1024x1024"
}
}'
import requests
url = "https://api.1min.ai/api/features"
headers = {
"Content-Type": "application/json",
"API-KEY": "YOUR_API_KEY"
}
data = {
"type": "IMAGE_VARIATOR",
"model": "dall-e-2",
"promptObject": {
"imageUrl": "development/images/2025_02_14_17_41_01_211_images.jpeg",
"n": 1,
"size": "1024x1024"
}
}
response = requests.post(url, headers=headers, json=data)
Responses
Success Response (200)
Successful response contains the generated image variation data.
{}