Skip to main content
POST
/
images
/
generations
Create an image
curl --request POST \
  --url https://api.orcarouter.ai/v1/images/generations \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "gpt-image-1",
  "prompt": "<string>",
  "n": 1,
  "size": "<string>",
  "quality": "auto",
  "style": "vivid",
  "response_format": "url",
  "user": "<string>"
}
'
{
  "created": 123,
  "data": [
    {
      "url": "<string>",
      "b64_json": "<string>",
      "revised_prompt": "<string>"
    }
  ]
}

Authorizations

Authorization
string
header
required

OrcaRouter API keys look like sk-orca-.... Pass them in the Authorization: Bearer sk-orca-... header.

Body

application/json
model
string
required
Example:

"gpt-image-1"

prompt
string
required
n
integer
default:1
Required range: 1 <= x <= 10
size
string

OpenAI-style size like 1024x1024. For models that use aspect-ratio instead (Gemini Imagen), OrcaRouter maps 1024x10241:1, 1792x102416:9, etc.

Examples:

"1024x1024"

"1792x1024"

"1024x1792"

quality
enum<string>
Available options:
auto,
standard,
hd,
high,
medium,
low
style
enum<string>
Available options:
vivid,
natural
response_format
enum<string>
default:url
Available options:
url,
b64_json
user
string

Response

200 - application/json

OK

created
integer
data
object[]