Bria Ad Delayer API Documentation

Bria Ad Delayer API Documentation

Playground

Try it on WaveSpeedAI!

Bria Ad Delayer splits flat advertisement images into editable image, text, and vector layers, returning a complete structured layer document as JSON for ad editing, localization, redesign, marketing creatives, and production workflows. Ready-to-use REST inference API, best performance, no coldstarts, affordable pricing.

Features

Bria Ad Delayer converts a flat advertisement image into editable layer data. It separates the source ad into components such as background, product cutouts, logo cutouts, text, and vector shapes, then returns the complete layer document as JSON.


Why Choose This?

  • Ad layer decomposition
    Convert a flat advertisement into structured editable layers.

  • Text and vector extraction
    Extract text and vector-style elements as structured layer data.

  • Product and logo cutouts
    Separate key visual assets such as products and logos from the original ad.

  • Editable text modes
    Use svg to preserve traced letterforms or font for editable text with the nearest matching font.

  • JSON workflow output
    Receive the upstream layer document for custom editors, rendering pipelines, and design workflows.


Parameters

ParameterRequiredDescription
imageYesPublic URL of the source advertisement image, supplied directly or through the image uploader.
text_modeNoText layer mode: svg or font. Default: svg. svg preserves traced letterforms, while font uses editable text with the nearest matching font.

Use a flat advertisement image rather than an ordinary photograph.


How to Use

  1. Upload an advertisement image — Provide a flat ad image through the uploader or a public URL.
  2. Choose text mode optional — Use svg for traced letterforms or font for editable text.
  3. Submit — Generate the layer document.
  4. Use the JSON output — Read the layer data from json.

Pricing

Pricing is fixed at $0.30 per successful request.

OutputCost
One layer document$0.30

Both svg and font modes use the same fixed price. The number of returned layers does not add separate charges.


Best Use Cases

  • Ad creative editing — Break flat ad images into editable components.
  • Design reconstruction — Recover layout elements from existing ad creatives.
  • Text and logo workflows — Extract text, logos, and vector-like elements for editing.
  • Custom rendering pipelines — Use JSON layer data to rebuild ads in your own editor.
  • Marketing asset reuse — Separate products, backgrounds, and text for downstream creative work.

Pro Tips

  • Use flat advertisement images for better layer separation.
  • Use svg when preserving original letter shapes matters.
  • Use font when editable text is more important than exact traced appearance.
  • Check whether each layer has asset_path before treating it as a downloadable asset.
  • Download the layer document and required linked assets promptly.

Authentication

For authentication details, please refer to the Authentication Guide.

API Endpoints

Submit Task & Query Result

set -euo pipefail

export WAVESPEED_API_KEY="your-api-key"

REQUEST_BODY=$(cat <<'JSON'
{
  "image": "https://interactive-examples.mdn.mozilla.net/media/cc0-images/painted-hand-298-332.jpg",
  "text_mode": "svg"
}
JSON
)

# 1. Submit the prediction.
SUBMIT_RESPONSE=$(curl --silent --show-error --fail-with-body \
  -X POST "https://api.wavespeed.ai/api/v3/bria/ad-delayer" \
  -H "Authorization: Bearer ${WAVESPEED_API_KEY}" \
  -H "Content-Type: application/json" \
  -d "${REQUEST_BODY}")

TASK=$(printf '%s' "${SUBMIT_RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
PREDICTION_ID=$(printf '%s' "${TASK}" | jq -r '.id // empty')
if [ -z "${PREDICTION_ID}" ]; then
  printf 'Submission response did not contain a prediction id
' >&2
  exit 1
fi
RESULT_URL="https://api.wavespeed.ai/api/v3/predictions/${PREDICTION_ID}/result"

# 2. Poll until the prediction finishes.
while true; do
  RESPONSE=$(curl --silent --show-error --fail-with-body \
    "${RESULT_URL}" \
    -H "Authorization: Bearer ${WAVESPEED_API_KEY}")
  RESULT=$(printf '%s' "${RESPONSE}" | jq 'if type == "object" and has("data") then .data else . end')
  STATUS=$(printf '%s' "${RESULT}" | jq -r '.status // empty')

  case "${STATUS}" in
    completed) printf '%s\n' "${RESULT}" | jq '.outputs'; break ;;
    failed|cancelled|timeout|deleted) printf '%s\n' "${RESULT}" | jq . >&2; exit 1 ;;
    *) sleep 2 ;;
  esac
done

Parameters

Task Submission Parameters

Request Parameters

ParameterTypeRequiredDefaultRangeDescription
imagestringYes-Public URL of the flat advertisement image to split into editable layers.
text_modestringNosvgsvg, fontUse svg to preserve traced letterforms, or font for editable text in the nearest matching font.

Response Parameters

ParameterTypeDescription
codeintegerHTTP status code (e.g., 200 for success)
messagestringStatus message (e.g., “success”)
data.idstringUnique identifier for the prediction, Task Id
data.modelstringModel ID used for the prediction
data.outputsarrayOutput values, usually URL strings; some models return text strings or structured result objects (empty when status is not completed)
data.urlsobjectObject containing related API endpoints
data.statusstringTask status. completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses.
data.created_atstringISO timestamp of when the request was created (e.g., “2023-04-01T12:34:56.789Z”)
data.errorstringError message (empty if no error occurred)
data.timingsobjectObject containing timing details
data.timings.inferenceintegerInference time in milliseconds

Result Request Parameters

ParameterTypeRequiredDefaultDescription
idstringYes-Task ID

Result Response Parameters

ParameterTypeDescription
codeintegerHTTP status code (e.g., 200 for success)
messagestringStatus message (e.g., “success”)
dataobjectThe prediction data object containing all details
data.idstringUnique identifier for the prediction
data.modelstringModel ID used for the prediction
data.outputsarray<string | object>Array of generated outputs (empty when status is not completed). Items are usually URL strings, but may be text strings or structured result objects, depending on the model.
data.urlsobjectObject containing related API endpoints
data.statusstringStatus: completed is successful; failed, cancelled, timeout, and deleted are failure terminal statuses
data.created_atstringISO timestamp of when the request was created
data.errorstringError message (empty if no error occurred)
data.timingsobjectObject containing timing details
data.timings.inferenceintegerInference time in milliseconds
© 2026 WaveSpeedAI. All rights reserved.