Skip to main content
TokModel exposes three image endpoints that follow the OpenAI Images API shape: generate a new image from a text prompt, edit an existing image using a mask, or produce variations of an image. All three endpoints accept a model parameter so you can route requests to different image providers without changing your client code.

Authentication

Include your API key in every request:

Generate an image from a prompt

POST /v1/images/generations accepts a text prompt and returns one or more image URLs. Use the n parameter to request multiple images and size to control resolution.
curl

Key parameters

Example response

The url field contains a temporary link to the generated image. Download and store it if you need it beyond the expiry window.