Seedream 画像生成 4.5
curl --request POST \
--url https://api.highwayapi.ai/v3/seedream-4.5 \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"size": "<string>",
"image": [
"<string>"
],
"prompt": "<string>",
"watermark": true,
"optimize_prompt_options": {
"mode": "<string>"
},
"sequential_image_generation": "<string>",
"sequential_image_generation_options": {
"max_images": 123
}
}
'import requests
url = "https://api.highwayapi.ai/v3/seedream-4.5"
payload = {
"size": "<string>",
"image": ["<string>"],
"prompt": "<string>",
"watermark": True,
"optimize_prompt_options": { "mode": "<string>" },
"sequential_image_generation": "<string>",
"sequential_image_generation_options": { "max_images": 123 }
}
headers = {
"Content-Type": "<content-type>",
"Authorization": "<authorization>"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': '<content-type>', Authorization: '<authorization>'},
body: JSON.stringify({
size: '<string>',
image: ['<string>'],
prompt: '<string>',
watermark: true,
optimize_prompt_options: {mode: '<string>'},
sequential_image_generation: '<string>',
sequential_image_generation_options: {max_images: 123}
})
};
fetch('https://api.highwayapi.ai/v3/seedream-4.5', 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.highwayapi.ai/v3/seedream-4.5",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'size' => '<string>',
'image' => [
'<string>'
],
'prompt' => '<string>',
'watermark' => true,
'optimize_prompt_options' => [
'mode' => '<string>'
],
'sequential_image_generation' => '<string>',
'sequential_image_generation_options' => [
'max_images' => 123
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.highwayapi.ai/v3/seedream-4.5"
payload := strings.NewReader("{\n \"size\": \"<string>\",\n \"image\": [\n \"<string>\"\n ],\n \"prompt\": \"<string>\",\n \"watermark\": true,\n \"optimize_prompt_options\": {\n \"mode\": \"<string>\"\n },\n \"sequential_image_generation\": \"<string>\",\n \"sequential_image_generation_options\": {\n \"max_images\": 123\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "<authorization>")
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.highwayapi.ai/v3/seedream-4.5")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.body("{\n \"size\": \"<string>\",\n \"image\": [\n \"<string>\"\n ],\n \"prompt\": \"<string>\",\n \"watermark\": true,\n \"optimize_prompt_options\": {\n \"mode\": \"<string>\"\n },\n \"sequential_image_generation\": \"<string>\",\n \"sequential_image_generation_options\": {\n \"max_images\": 123\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.highwayapi.ai/v3/seedream-4.5")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = '<authorization>'
request.body = "{\n \"size\": \"<string>\",\n \"image\": [\n \"<string>\"\n ],\n \"prompt\": \"<string>\",\n \"watermark\": true,\n \"optimize_prompt_options\": {\n \"mode\": \"<string>\"\n },\n \"sequential_image_generation\": \"<string>\",\n \"sequential_image_generation_options\": {\n \"max_images\": 123\n }\n}"
response = http.request(request)
puts response.read_body{
"images": [
"<string>"
]
}画像
Seedream 画像生成 4.5
POST
/
v3
/
seedream-4.5
Seedream 画像生成 4.5
curl --request POST \
--url https://api.highwayapi.ai/v3/seedream-4.5 \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"size": "<string>",
"image": [
"<string>"
],
"prompt": "<string>",
"watermark": true,
"optimize_prompt_options": {
"mode": "<string>"
},
"sequential_image_generation": "<string>",
"sequential_image_generation_options": {
"max_images": 123
}
}
'import requests
url = "https://api.highwayapi.ai/v3/seedream-4.5"
payload = {
"size": "<string>",
"image": ["<string>"],
"prompt": "<string>",
"watermark": True,
"optimize_prompt_options": { "mode": "<string>" },
"sequential_image_generation": "<string>",
"sequential_image_generation_options": { "max_images": 123 }
}
headers = {
"Content-Type": "<content-type>",
"Authorization": "<authorization>"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': '<content-type>', Authorization: '<authorization>'},
body: JSON.stringify({
size: '<string>',
image: ['<string>'],
prompt: '<string>',
watermark: true,
optimize_prompt_options: {mode: '<string>'},
sequential_image_generation: '<string>',
sequential_image_generation_options: {max_images: 123}
})
};
fetch('https://api.highwayapi.ai/v3/seedream-4.5', 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.highwayapi.ai/v3/seedream-4.5",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'size' => '<string>',
'image' => [
'<string>'
],
'prompt' => '<string>',
'watermark' => true,
'optimize_prompt_options' => [
'mode' => '<string>'
],
'sequential_image_generation' => '<string>',
'sequential_image_generation_options' => [
'max_images' => 123
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.highwayapi.ai/v3/seedream-4.5"
payload := strings.NewReader("{\n \"size\": \"<string>\",\n \"image\": [\n \"<string>\"\n ],\n \"prompt\": \"<string>\",\n \"watermark\": true,\n \"optimize_prompt_options\": {\n \"mode\": \"<string>\"\n },\n \"sequential_image_generation\": \"<string>\",\n \"sequential_image_generation_options\": {\n \"max_images\": 123\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "<authorization>")
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.highwayapi.ai/v3/seedream-4.5")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.body("{\n \"size\": \"<string>\",\n \"image\": [\n \"<string>\"\n ],\n \"prompt\": \"<string>\",\n \"watermark\": true,\n \"optimize_prompt_options\": {\n \"mode\": \"<string>\"\n },\n \"sequential_image_generation\": \"<string>\",\n \"sequential_image_generation_options\": {\n \"max_images\": 123\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.highwayapi.ai/v3/seedream-4.5")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = '<authorization>'
request.body = "{\n \"size\": \"<string>\",\n \"image\": [\n \"<string>\"\n ],\n \"prompt\": \"<string>\",\n \"watermark\": true,\n \"optimize_prompt_options\": {\n \"mode\": \"<string>\"\n },\n \"sequential_image_generation\": \"<string>\",\n \"sequential_image_generation_options\": {\n \"max_images\": 123\n }\n}"
response = http.request(request)
puts response.read_body{
"images": [
"<string>"
]
}入力されたテキストプロンプトおよび/または参照画像に基づいて画像を生成します。単一画像または組画像(一連の関連する画像)の生成に対応しています。
リクエストヘッダー
string
必須
列挙値:
application/jsonstring
必須
Bearer 認証形式: Bearer {{API キー}}。
リクエストボディ
string
デフォルト:"2048x2048"
生成する画像のサイズ情報を指定します。方法1:解像度(2K、4K)を指定します。方法2:幅と高さのピクセル値(例:2048x2048)を指定します。総ピクセル数の範囲:[3686400, 16777216]、アスペクト比の範囲:[1/16, 16]。
string[]
入力画像情報の配列です。URL または Base64 エンコードに対応しています。最大 14 枚の参照画像を渡すことができます。画像形式は jpeg、png、webp、bmp、tiff、gif に対応しています。配列の長さ:1 - 14
string
必須
画像生成に使用するプロンプトです。中国語と英語に対応しています。中国語は300文字以内、英語は600単語以内を推奨します。
boolean
デフォルト:true
生成された画像にウォーターマークを追加するかどうか。
object
プロンプト最適化機能の設定です。
非表示 properties
非表示 properties
string
デフォルト:"standard"
プロンプト最適化機能で使用するモードを設定します。standard:標準モード。品質が高く、処理時間が長くなります。fast:高速モード。処理時間が短く、品質は標準的です。現在は standard モードのみ対応しています。選択可能な値:
standardstring
デフォルト:"disabled"
組画像機能を無効にするかどうかを制御します。auto:自動判定モード。モデルがプロンプトに基づいて組画像を返すかどうかを自律的に判断します。disabled:組画像機能を無効にし、1枚の画像のみを生成します。選択可能な値:
auto, disabledobject
組画像機能の設定です。sequential_image_generation が auto の場合にのみ有効です。
非表示 properties
非表示 properties
integer
デフォルト:15
このリクエストで生成可能な画像の最大数を指定します。入力された参照画像の数 + 最終的に生成される画像の数 ≤ 15枚。値の範囲:[1, 15]
レスポンス情報
string[]
生成された画像情報の配列です。
⌘I