Model API

Omnigen V2

OmniGen is a unified image generation model that can generate a wide range of images from multi-modal prompts. It can be used for various tasks such as Image Editing, Personalized Image Generation, Virtual Try-On, Multi Person Generation and more!

Model id

Use this in every request
omnigen-v2

Run it

Quote the input, start the generation with the quote, then poll the job. Set RAYWAKE_API_KEY first; see Authentication.

# 1. Price the exact input (quotes are valid for up to 10 minutes)
curl -s https://api.raywake.com/v1/quotes \
  -H "Authorization: Bearer $RAYWAKE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "omnigen-v2",
  "input": {
    "prompt": "A red ceramic cup on a wooden table, soft morning light"
  }
}'

# 2. Start the generation with the quote_id from step 1
curl -s https://api.raywake.com/v1/generate \
  -H "Authorization: Bearer $RAYWAKE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"model": "omnigen-v2", "quote_id": "QUOTE_ID", "input": {"prompt":"A red ceramic cup on a wooden table, soft morning light"}}'

# 3. Poll until the status is terminal
curl -s https://api.raywake.com/v1/jobs/JOB_ID \
  -H "Authorization: Bearer $RAYWAKE_API_KEY"

Input

Input fields for omnigen-v2
NameTypeDescription
promptrequiredstring
The prompt to generate or edit an image. Use specific language like 'Add the bird from image 1 to the desk in image 2' for better results.
input_image_urlsarray of image URLs
URLs of input images to use for image editing or multi-image generation. Support up to 3 images.

Default: []

image_sizestring (enum)
The size of the generated image.

Default: square_hd

One of: square_hd, square, portrait_4_3, portrait_16_9, landscape_4_3, landscape_16_9

num_inference_stepsinteger
The number of inference steps to perform.

Default: 50

seedinteger
The same seed and the same prompt given to the same version of the model will output the same image every time.
text_guidance_scalenumber
The Text Guidance scale controls how closely the model follows the text prompt. Higher values make the model stick more closely to the prompt.

Default: 5

image_guidance_scalenumber
The Image Guidance scale controls how closely the model follows the input images. For image editing: 1.3-2.0, for in-context generation: 2.0-3.0

Default: 2

negative_promptstring
Negative prompt to guide what should not be in the image.

Default: (((deformed))), blurry, over saturation, bad anatomy, disfigured, poorly drawn face, mutation, mutated, (extra_limb), (ugly), (poorly drawn hands), fused fingers, messy drawing, broken legs censor, censored, censor_bar

cfg_range_startnumber
CFG range start value.

Default: 0

cfg_range_endnumber
CFG range end value.

Default: 1

schedulerstring (enum)
The scheduler to use for the diffusion process.

Default: euler

One of: euler, dpmsolver

sync_modeboolean
If `True`, the media will be returned as a data URI and the output data won't be available in the request history.

Default: false

num_imagesinteger
The number of images to generate.

Default: 1

output_formatstring (enum)
The format of the generated image.

Default: jpeg

One of: jpeg, png

Output

A succeeded job lists its results under outputs, stored on our side. See Jobs for every field.

Job excerpt
"outputs": [
  { "type": "image", "url": "https://…", "mime_type": "image/png", "thumbnail_url": "https://…" }
]

Pricing

  • 1 megapixel$0.24/ megapixel

The exact charge for your input comes from a quote. How charges settle