Introduction
Video Background Remover isolates the foreground of an existing video for compositing or for placement on a solid background. Send video_url and choose the background and export format. The default request asks for transparent WebM VP9 and retains the original audio. Source clips from 1 to 60 seconds are accepted by this endpoint; it does not generate a new scene from a prompt.
Key features & highlights
Transparency is a background and format choice
Set background to transparent and use a format with alpha support. WebM VP9, MOV ProRes 4444, MKV VP9 and GIF are documented alpha options. The MP4 presets and MKV H.264 or H.265 presets do not carry alpha here; incompatible transparent requests may be rejected. MOV H.265 has only partial documented support, so use WebM VP9 for the default transparent workflow and check the actual output before compositing.
Solid colors and original sound
You can instead choose black, white, gray, red, green, blue, yellow, cyan, magenta or orange. keep_original_audio controls whether the source audio is requested in the result. GIF cannot carry an audio track; turn audio preservation off when choosing it. Container, codec and background choices do not change the duration-based billing rule. Billing uses input seconds rounded upward, and there is no crop or output-resolution control on this endpoint.
Request parameters
| Parameter | Required | Description |
|---|---|---|
video_url | Yes | Source clip from 1 to 60 seconds. The output isolates the detected foreground; there is no crop control. at least 1 characters |
background | No | Choose transparent or one of ten solid colors. Transparent output requires an alpha-capable format. |
output_format | No | Container and codec preset. WebM VP9 is the default. |
keep_original_audio | No | Request the original audio in the output; enabled by default. Turn it off for a silent clip. Default: |
Pricing
$0.06 / second
Billed per second of input video, rounded up to the whole second. This endpoint accepts clips from 1 to 60 seconds. Background, format and audio choices do not change this duration rule.
Use cases
Put a presenter over a presentation
Start with a short clip in which the presenter is clearly separated from the background. Request transparent WebM VP9, then place the result above the slide or scene in an editor that supports that format. Inspect hair and motion-blurred edges against both dark and light backgrounds before publishing the composite.
Prepare a product clip for a new layout
Separate a product from the original setting to reuse the footage in a catalog layout or social edit. A solid color export can be useful when transparency is unnecessary. Reflective surfaces and fine edges need close review: the result is a processed mask, and it should be evaluated against the intended background rather than only a checkerboard preview.
Prompt guide & pro tips
Choose the delivery format deliberately
Keep background=transparent, output_format=webm_vp9 and keep_original_audio=true for the default video workflow. Choose a different preset only after checking that your editor can import it. Web playback support varies by browser and codec; a successful download does not prove that an inline preview or subsequent edit will work. Preserve the transparent master when creating a separate flattened preview for sharing.
Verify transparency and the complete clip
Inspect the actual alpha channel and composite the result over black, white and a saturated color. A file showing a checkerboard or black rectangle is not proof of working transparency. Review the full movement for edge changes, and compare duration, frame dimensions and audio synchronization with the original. Do not infer alpha from the filename or selected options. This integration has no completed media-quality or browser-compatibility trial yet; validate the result with your intended workflow.
API quick start
# Generate the idempotency key once; reuse it when retrying after a lost response.
export SPICY_IDEMPOTENCY_KEY="${SPICY_IDEMPOTENCY_KEY:-$(uuidgen)}"
curl -X POST https://api.spicyapi.ai/api/v1/jobs/createTask \
-H "Authorization: Bearer $SPICY_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $SPICY_IDEMPOTENCY_KEY" \
-d '{
"model": "spicyapi/background-remover-video-v1/video-edit",
"input": {
"background": "transparent",
"output_format": "webm_vp9",
"video_url": "https://example.com/reference.mp4"
}
}'
# Copy data.taskId from the response into TASK_ID, then poll the status.
TASK_ID="TASK_ID_FROM_RESPONSE"
curl "https://api.spicyapi.ai/api/v1/jobs/recordInfo?taskId=$TASK_ID" \
-H "Authorization: Bearer $SPICY_API_KEY"
See the API reference for authentication, the complete schema, polling, and error handling.
