Image Generation API | Documentation | Geodd
Image Generation API
DocsServerless InferenceImage Generation API

Image Generation API

Our Image Generation API allows you to create high-quality images from text prompts, edit existing images, and blend multiple reference images together. The API is fully compatible with the standard OpenAI SDK, making it incredibly easy to integrate into your existing applications.

Base URL & Authentication

All API requests require your API key to be included in the Authorization header as a Bearer token.

Base URLs

Global (US)
https://api.geodd.io/inference/v1
Europe (EU)
https://eu.api.geodd.io/inference/v1

Include your API key in the Authorization header:

Authorization: Bearer <token>

Available Models

We support a range of powerful image generation models. Specify one of the following in the model parameter:

  • dola-seedream-5-0-pro-260628 — Designed for high-precision scenarios with precise control over positions and elements.
  • seedream-5-0-260128 — A balanced, high-performance model for general text-to-image and image-to-image tasks.

1. Text-to-Image

Generate a completely new image by providing a clear descriptive prompt.

Python (OpenAI SDK)

import os
from openai import OpenAI

# 1. Initialize the client pointing to our API
client = OpenAI(
    base_url="https://api.geodd.io/inference/v1",
    api_key="your_api_key_here"
)

# 2. Generate the image
response = client.images.generate(
    model="dola-seedream-5-0-pro-260628",
    prompt="Vibrant close-up editorial portrait, model with piercing gaze, wearing a sculptural hat, rich color blocking, dramatic studio lighting.",
    size="2K"
)

# 3. Get your image URL
print(response.data[0].url)

cURL

curl https://api.geodd.io/inference/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer your_api_key_here" \
  -d '{
    "model": "dola-seedream-5-0-pro-260628",
    "prompt": "Vibrant close-up editorial portrait, model with piercing gaze, wearing a sculptural hat, rich color blocking, dramatic studio lighting.",
    "size": "2K"
  }'

2. Image-to-Image (Editing & Blending)

You can use existing images as references. Provide a single image URL to modify an image, or an array of image URLs to blend elements (for example, putting a specific outfit on a specific character).

Python (OpenAI SDK)

response = client.images.generate(
    model="dola-seedream-5-0-pro-260628",
    prompt="Keep the model's pose unchanged. Change the clothing material to completely transparent clear water.",
    size="2K",
    extra_body={
        # Pass a single URL for image-to-image, or a list of URLs for multi-image blending
        "image": "https://example.com/path/to/reference_image.png",
        "watermark": False
    }
)

print(response.data[0].url)

cURL

curl https://api.geodd.io/inference/v1/images/generations \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer your_api_key_here" \
  -d '{
    "model": "dola-seedream-5-0-pro-260628",
    "prompt": "Replace the clothing in image 1 with the outfit from image 2.",
    "image": [
        "https://example.com/person.png",
        "https://example.com/outfit.png"
    ],
    "size": "2K",
    "watermark": false
  }'

Supported Parameters

Parameter Type Required Description
model string Yes The ID of the model to use (e.g., dola-seedream-5-0-pro-260628).
prompt string Yes A detailed description of the image you want to generate.
image string / array No A URL (or array of URLs) pointing to reference images for image-to-image editing or multi-image blending.
size string No The resolution level of the output. Supported values include 1K, 2K, 3K, 4K (availability depends on the model).
output_format string No The file format of the generated image. Options: png, jpeg.
watermark boolean No Set to true to include an "AI generated" watermark, or false to omit it.