Skip to content

Seedream 5.0 Lite ​

Request parameters and examples for Seedream 5.0 Lite.

POST /v1/images/generations · POST /v1/async/images/generations

POST /v1/images/edits · POST /v1/async/images/edits

Send JSON with Authorization: Bearer <PIXAPI_KEY> and Content-Type: application/json.

Request fields ​

Send the common fields at the top level. Put the model-specific controls listed below inside providerOptions.

FieldTypeRequiredDescription
modelstringYesseedream-5-0-lite. Case-sensitive model ID.
promptstringYesDescribe the subject, composition, style, and requested edits. Pixapi keeps the first 2,000 characters; provide a non-empty prompt for both generation and editing.
nintegerNoDefault 1; Pixapi accepts 1–9 (up to 15). Values above 1 enable sequential generation.
sizestringNoUse pixel dimensions WIDTHxHEIGHT, for example 1024x1024.
imagestring / string[]For editsPublic HTTP(S) image URL or URL array; required on /images/edits. JPEG/PNG, ≤ 10 MB each, ≤ 6000×6000 pixels; ratio 1:3–3:1. Pixapi currently accepts at most 4 reference images.
providerOptionsobjectNoModel-specific options; see the table below.

providerOptions ​

All fields in this table are nested inside providerOptions, not alongside model.

FieldTypeDescription
nsfw_checkbooleanOptional prompt/image moderation; default false.
output_formatstringOutput image format: jpeg (default) or png.
watermarkbooleanAdd a visible AI watermark. Default false.
sequential_image_generationstringdisabled (default) or auto; n>1 enables auto.
sequential_image_generation_optionsobject{"max_images":N} when sequential mode is enabled; keep N equal to top-level n.

Input rules ​

Output dimensions are selected with size.

Example ​

bash
curl https://api.pixapi.ai/v1/images/generations \
  -H "Authorization: Bearer $PIXAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "seedream-5-0-lite",
  "prompt": "A ceramic coffee cup in soft studio light",
  "n": 1,
  "size": "2048x2048",
  "providerOptions": {
    "output_format": "png",
    "watermark": false
  }
}'
py
import os
import requests

response = requests.post(
    "https://api.pixapi.ai/v1/images/generations",
    headers={"Authorization": f"Bearer {os.environ['PIXAPI_KEY']}"},
    json={
  "model": "seedream-5-0-lite",
  "prompt": "A ceramic coffee cup in soft studio light",
  "n": 1,
  "size": "2048x2048",
  "providerOptions": {
    "output_format": "png",
    "watermark": False
  }
},
)
response.raise_for_status()
print(response.json())
js
const response = await fetch('https://api.pixapi.ai/v1/images/generations', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.PIXAPI_KEY}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
  "model": "seedream-5-0-lite",
  "prompt": "A ceramic coffee cup in soft studio light",
  "n": 1,
  "size": "2048x2048",
  "providerOptions": {
    "output_format": "png",
    "watermark": false
  }
}),
});
if (!response.ok) throw new Error(await response.text());
console.log(await response.json());
go
package main

import (
  "bytes"
  "fmt"
  "io"
  "net/http"
  "os"
)

func main() {
  body := []byte(`{
  "model": "seedream-5-0-lite",
  "prompt": "A ceramic coffee cup in soft studio light",
  "n": 1,
  "size": "2048x2048",
  "providerOptions": {
    "output_format": "png",
    "watermark": false
  }
}`)
  req, err := http.NewRequest("POST", "https://api.pixapi.ai/v1/images/generations", bytes.NewBuffer(body))
  if err != nil { panic(err) }
  req.Header.Set("Authorization", "Bearer " + os.Getenv("PIXAPI_KEY"))
  req.Header.Set("Content-Type", "application/json")
  resp, err := http.DefaultClient.Do(req)
  if err != nil { panic(err) }
  defer resp.Body.Close()
  result, err := io.ReadAll(resp.Body)
  if err != nil { panic(err) }
  if resp.StatusCode >= 400 { panic(string(result)) }
  fmt.Println(string(result))
}

For asynchronous requests, save the returned id and poll GET /v1/tasks/{id} until completed or failed. See task results and billing.