Seedream 5.0 Pro
curl --request POST \
--url https://api.snapgen.org/v1/images/generations \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.snapgen.org/v1/images/generations"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.snapgen.org/v1/images/generations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.snapgen.org/v1/images/generations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.snapgen.org/v1/images/generations"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.snapgen.org/v1/images/generations")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.snapgen.org/v1/images/generations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyImage Series
Seedream 5.0 Pro
Generate one 1K or 2K Seedream image, with optional image references.
POST
/
v1
/
images
/
generations
Seedream 5.0 Pro
curl --request POST \
--url https://api.snapgen.org/v1/images/generations \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.snapgen.org/v1/images/generations"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.snapgen.org/v1/images/generations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.snapgen.org/v1/images/generations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.snapgen.org/v1/images/generations"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.snapgen.org/v1/images/generations")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.snapgen.org/v1/images/generations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyUse
For an edit, add
seedream-5.0-pro for text-to-image or editing with up to ten public image
references. A request accepts a prompt up to 7,000 characters and produces one
image (n: 1). Choose 1K or 2K; the launch contract does not enable layer
decomposition or arbitrary pixel dimensions.
size can be auto, 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 5:4,
4:5 or 21:9. Output is PNG.
{
"model": "seedream-5.0-pro",
"prompt": "An original watercolor illustration of a seed growing in a pot.",
"resolution": "1K",
"size": "1:1",
"n": 1
}
image_urls, for example
["https://your-cdn.example/seed.png"], and describe what to preserve and change.
Send a stable Idempotency-Key and Prefer: respond-async. Poll the returned
Task ID to obtain result.urls.
Launch prices are $0.10 for 1K and $0.15 for 2K, including all permitted reference
images. Check the live Catalog for the current
availability and resolution price; submit separate requests for variants.