curl https://api.apipod.ai/v1/images/generations \
-H "Authorization: Bearer $APIPOD_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}'import os
import requests
payload = {
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}
response = requests.post(
"https://api.apipod.ai/v1/images/generations",
headers={
"Authorization": f"Bearer {os.environ['APIPOD_API_KEY']}",
"Content-Type": "application/json",
},
json=payload,
timeout=60,
)
response.raise_for_status()
print(response.json())package main
import (
"bytes"
"encoding/json"
"fmt"
"net/http"
"os"
)
func main() {
payload := map[string]any{}
if err := json.Unmarshal([]byte(`{
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}`), &payload); err != nil {
panic(err)
}
body, err := json.Marshal(payload)
if err != nil {
panic(err)
}
req, err := http.NewRequest(http.MethodPost, "https://api.apipod.ai/v1/images/generations", bytes.NewReader(body))
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("APIPOD_API_KEY"))
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println(resp.Status)
}use reqwest::Client;
use serde_json::json;
use std::env;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let payload = json!({
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
});
let response = Client::new()
.post("https://api.apipod.ai/v1/images/generations")
.bearer_auth(env::var("APIPOD_API_KEY")?)
.json(&payload)
.send()
.await?
.error_for_status()?;
println!("{}", response.text().await?);
Ok(())
}const response = await fetch("https://api.apipod.ai/v1/images/generations", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.APIPOD_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify(
{
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}
),
});
if (!response.ok) {
throw new Error(`APIPod request failed: ${response.status} ${await response.text()}`);
}
console.log(await response.json());{
"code": 200,
"message": "success",
"data": {
"task_id": "img_task_01JEXAMPLE"
}
}GPT Image 2.6 Sunburst
GPT Image 2.6 Sunburst 是 OpenAI GPT Image 2.6 图片系列中注重精度的档位。它在 Flare 之上强化多轮编辑中的细节保留,并同样支持 GIF 动画、SVG 矢量与 complexity 能力,适合成品级营销主视觉与精修商品图。在 APIPod 中,公开模型 ID 为 gpt-image-2.6-sunburst,支持文生图与参考图编辑,GIF 与 SVG 结果以转存后的产物地址返回。
curl https://api.apipod.ai/v1/images/generations \
-H "Authorization: Bearer $APIPOD_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}'import os
import requests
payload = {
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}
response = requests.post(
"https://api.apipod.ai/v1/images/generations",
headers={
"Authorization": f"Bearer {os.environ['APIPOD_API_KEY']}",
"Content-Type": "application/json",
},
json=payload,
timeout=60,
)
response.raise_for_status()
print(response.json())package main
import (
"bytes"
"encoding/json"
"fmt"
"net/http"
"os"
)
func main() {
payload := map[string]any{}
if err := json.Unmarshal([]byte(`{
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}`), &payload); err != nil {
panic(err)
}
body, err := json.Marshal(payload)
if err != nil {
panic(err)
}
req, err := http.NewRequest(http.MethodPost, "https://api.apipod.ai/v1/images/generations", bytes.NewReader(body))
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("APIPOD_API_KEY"))
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println(resp.Status)
}use reqwest::Client;
use serde_json::json;
use std::env;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let payload = json!({
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
});
let response = Client::new()
.post("https://api.apipod.ai/v1/images/generations")
.bearer_auth(env::var("APIPOD_API_KEY")?)
.json(&payload)
.send()
.await?
.error_for_status()?;
println!("{}", response.text().await?);
Ok(())
}const response = await fetch("https://api.apipod.ai/v1/images/generations", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.APIPOD_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify(
{
"model": "gpt-image-2.6-sunburst",
"prompt": "A premium product photograph on a dark studio set, precise typography, soft rim lighting, highly detailed.",
"quality": "auto",
"aspect_ratio": "auto",
"resolution": "1K"
}
),
});
if (!response.ok) {
throw new Error(`APIPod request failed: ${response.status} ${await response.text()}`);
}
console.log(await response.json());{
"code": 200,
"message": "success",
"data": {
"task_id": "img_task_01JEXAMPLE"
}
}授权
在 Authorization 请求头中使用 Bearer APIPod_API_KEY。
请求体
APIPod 公开模型 ID。
"gpt-image-2.6-sunburst"生成或编辑指令。输出 GIF 时需写明主体、运动方式与循环目标。
32000可公开访问的源图或参考图 URL。与 gif、svg 输出不能同时使用。
16输出格式。gif 与 svg 是 GPT Image 2.6 新增能力,仅支持文生图;svg 一次只返回一个结果,两者都不支持 output_compression 与透明背景。
png, jpeg, webp, gif, svg 渲染前的规划复杂度。low 适合改背景这类聚焦型编辑,high 适合密集文字与复杂版式;缺省为 high,不额外收费。
low, medium, high 保真档位。background 为 transparent 时不得低于 medium。
auto, low, medium, high, xhigh, max 背景模式。transparent 返回带 alpha 通道的图片,并要求 quality 不低于 medium。
auto, opaque, transparent 生成图片的宽高比。
auto, 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:9 生成图片的分辨率档位。
1K, 2K, 4K 精确像素尺寸,格式为 宽x高,例如 1024x1536。宽高必须是 16 的倍数且不超过 3840;优先于 resolution 与 aspect_ratio,同时决定 GIF 的单帧尺寸。
GIF 总帧数,取值 2-64。仅当 output_format 为 gif 时生效,缺省为 9。
2 <= x <= 64GIF 每帧时长(毫秒),取值 20-2000。仅当 output_format 为 gif 时生效,缺省为 200。
20 <= x <= 2000jpeg 与 webp 的输出压缩率,取值 0-100。gif 与 svg 不支持该参数。
0 <= x <= 100此页面对您有帮助吗?