Generate an image into the media library
POST
http://localhost:4000/api/v1 /media/generate/image Answers the new file like GET /media/{id}. 503 AI_NOT_CONFIGURED when the server has no image generator.
Request body
application/json
promptstring
required
aspectstring
stylestring
generatorstring
clientIdstring
{
"prompt": "string",
"aspect": "1:1",
"style": "string",
"generator": "string",
"clientId": "string"
}Code samples
cURL
curl -X POST "http://localhost:4000/api/v1/media/generate/image" \
-H "Authorization: Bearer $API_KEY" \
-H "Content-Type: application/json" \
-d '{"prompt":"string","aspect":"1:1","style":"string","generator":"string","clientId":"string"}'TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 OK
Example
{}Option 1
{}Option 2
{}Updated