跳至內容

Bria Product Shot

整合

模型 id bria/product-shot
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/bria/product-shot?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

此請求: $0.04 40 API 點數 在此頁面執行

取得 API 金鑰
Bria AI · 圖像

您的第一個結果會顯示在這裡

在下方建立請求,並使用您的 API 金鑰執行。輸出會複製到我們的儲存空間,可永久保留或免費保留 7 天。

建立請求

控制項是根據模型結構描述生成的。變更設定時,程式碼和價格會同步更新。

•必填 image_url
拖放檔案,或

用於放置於生活場景中的產品照片 URL;圖像必須是 jpeg、jpg、png、webp,且不得大於 12 MB。若同時提供 `image_file`,則以 `image_url` 優先。

預設 1

每個放置位置的生活風格產品圖像數量(`num_results`)。總數為所需放置位置數 × `num_results`(`placement_type=manual_placement`),或 `num_results` × 10(`placement_type=automatic`)。

進階 ref_image_url · placement_type · scene_description · manual_placement_selection · optimize_description · fast · original_quality · shot_size · padding_values
預設
拖放檔案,或

用於生成產品圖新背景或場景的參考圖像 URL,支援 jpeg、jpg、png 和 webp。請在 `scene_description` 或 `ref_image_url` 中正好提供一個;空 URL 會寫成 ""。若同時提供 `ref_image_file`,則以 `ref_image_url` 優先。

placement_type 預設 manual_placement

產品定位模式,包含兩種手動選項:'manual_placement' 會使用透過 'manual_placement_selection' 選取的預定義位置;'manual_padding' 會透過產品周圍的像素邊距調整圖像位置與大小。若要保留來源位置,請選擇 'original';若要在 10 個建議的產品位置中生成結果,請選擇 'automatic'。

僅限英文且不含特殊字元的提示詞,用於描述要為所提供產品照片建立的場景或背景。

預設 bottom_center

選取 placement_type=manual_placement 時要使用的預設位置。請從清單中選擇;可同時要求多個位置。

預設 [1000,1000]

最終產品圖像的目標尺寸,僅適用於 placement_type=automatic 或 placement_type=manual_placement。為獲得最佳結果,總像素數建議約為 1,000,000。

`placement_type=manual_padding` 的像素邊距,依 [left, right, top, bottom] 提供。若要選擇這些值,請先使用產品裁切 API 取得產品裁切圖並檢查其尺寸,再將該裁切圖與所需邊距傳給此 API。為獲得最佳結果,加上邊距後的總像素數建議約為 1,000,000。

POST /run/bria/product-shot?wait=20 報價 → $0.04
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/bria/product-shot?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

執行此請求

您的金鑰會保留在此瀏覽器中:只會傳送至 Doitong API,且只有在勾選「記住」時才會儲存至 localStorage。 取得 API 金鑰

關於 Bria Product Shot

將 `image_url` 中的產品放入由 `scene_description` 描述或由 `ref_image_url` 顯示的場景,但兩者不可同時使用。`placement_type` 可為 original、automatic、manual_placement 或 manual_padding,`manual_placement_selection` 提供十個位置,`shot_size` 約為 1,000,000 像素。`num_results` 範圍為 1 至 4,並提供 `fast` 模式。

參數

請傳送標準名稱或原生名稱其中之一,不要同時傳送兩者。 標準名稱

名稱類型 預設值允許值 說明
image_url必填 image
類型url · image
用於放置於生活場景中的產品照片 URL;圖像必須是 jpeg、jpg、png、webp,且不得大於 12 MB。若同時提供 `image_file`,則以 `image_url` 優先。
scene_description選填
類型string | null
僅限英文且不含特殊字元的提示詞,用於描述要為所提供產品照片建立的場景或背景。
ref_image_url選填
類型url · image
預設值
用於生成產品圖新背景或場景的參考圖像 URL,支援 jpeg、jpg、png 和 webp。請在 `scene_description` 或 `ref_image_url` 中正好提供一個;空 URL 會寫成 ""。若同時提供 `ref_image_file`,則以 `ref_image_url` 優先。
optimize_description選填
類型boolean
預設值true
是否啟用場景描述最佳化。
num_results選填
類型integer
預設值1
1 – 4
每個放置位置的生活風格產品圖像數量(`num_results`)。總數為所需放置位置數 × `num_results`(`placement_type=manual_placement`),或 `num_results` × 10(`placement_type=automatic`)。
fast選填
類型boolean
預設值true
控制是否選取快速模型。
placement_type選填
類型enum
預設值manual_placement
originalautomaticmanual_placementmanual_padding
產品定位模式,包含兩種手動選項:'manual_placement' 會使用透過 'manual_placement_selection' 選取的預定義位置;'manual_padding' 會透過產品周圍的像素邊距調整圖像位置與大小。若要保留來源位置,請選擇 'original';若要在 10 個建議的產品位置中生成結果,請選擇 'automatic'。
original_quality選填
類型boolean
預設值false
僅搭配 `placement_type=original` 使用的輸出尺寸選項:false 會在不改變長寬比的情況下將圖像縮放至 1 百萬像素 (1MP),true 則保留輸入尺寸。
shot_size選填
類型integer[]
預設值[1000,1000]
最終產品圖像的目標尺寸,僅適用於 placement_type=automatic 或 placement_type=manual_placement。為獲得最佳結果,總像素數建議約為 1,000,000。
manual_placement_selection選填
類型enum
預設值bottom_center
upper_leftupper_rightbottom_leftbottom_rightright_centerleft_centerupper_centerbottom_centercenter_verticalcenter_horizontal
選取 placement_type=manual_placement 時要使用的預設位置。請從清單中選擇;可同時要求多個位置。
padding_values選填
類型integer[]
`placement_type=manual_padding` 的像素邊距,依 [left, right, top, bottom] 提供。若要選擇這些值,請先使用產品裁切 API 取得產品裁切圖並檢查其尺寸,再將該裁切圖與所需邊距傳給此 API。為獲得最佳結果,加上邊距後的總像素數建議約為 1,000,000。
必填 標準名稱,也可使用

檔案參數接受公開的 https:// URL、最大 10 MB 的 data: URI,或上傳檔案的 file_url。 檔案

輸出

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "bria/product-shot",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 40,
    "usd": "0.04",
    "charged": 40,
    "refunded": 0
  },
  "input": {
    "image_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  },
  "output": {
    "images": [
      {
        "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
        "content_type": "image/jpeg",
        "file_name": "0-output.jpeg",
        "file_size": 1843200,
        "width": 1024,
        "height": 768
      }
    ]
  },
  "outputs": [
    {
      "type": "image",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_size": 1843200,
      "width": 1024,
      "height": 768,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
您的檔案,由您選擇每個 outputs[].url 都是儲存空間中的副本:可永久保留(按 GB-月計費),或免費保留 7 天;可透過帳戶設定或 ?storage= 設定。
所有模型使用相同結構圖片、影片和音訊皆包含 type、url、content_type、width、height 和 duration。output 是模型自己的結果物件。
輸出欄位
images
array of object {url, content_type, file_name, file_size, width, height}模型生成的圖像。

更多模型:圖像編輯

給 AI 代理程式:此頁面的 Markdown 位於 https://doitong.com/zh-TW/developers/models/bria/product-shot.md. 所有模型與指南: https://doitong.com/developers/llms.txt