Overview
This endpoint provides imagegenerate functionality.
Authentication
This endpoint requires authentication using a Bearer token.
Your API key in the format: Bearer YOUR_API_KEY
Request Body
The model to use for the request
Number of completions to generate
Request Example
curl -X POST "https://gptproto.com/v1/images/generations" \
-H "Authorization: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"prompt": "cat with a red hat https://xxx.png",
"model": "flux-kontext-pro",
"size": "16:9",
"n": 1
}'
Response
Error Responses
{
"error": {
"message": "Invalid request parameters",
"type": "invalid_request_error",
"code": "invalid_parameters"
}
}