Remove Video Background
remove_video_backgroundRemove the background from a video given by public URL or attached to the chat. Returns a job; when wait is true (default) the tool polls for up to 50 seconds and returns the finished job with result_url (a direct download link valid for 24 hours). For longer videos call get_job with the returned job id until status is completed. Costs 5 credits per second of video, rounded up (10 per second above 30 fps; animated GIFs are always 5 per second), charged when the job is accepted and refunded if it fails.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "remove_video_background"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | No | A video the user attached to the chat, as a file object with a download_url. Only use it when the client provides one for an attachment (ChatGPT does); never construct it. For a video at a public URL use video_url | |
| size | No | Output size preset. The longest side is capped at 640 (preview), 1280 (medium) or 1920 (hd) pixels; full keeps the source resolution up to 4096 pixels (4K) | full |
| wait | No | Poll until the job finishes (up to 50 seconds) before returning. Set to false to get the job id back immediately | |
| format | No | Output container. 'webm' (VP9) and 'mov' (ProRes 4444) keep transparency unless bg_color is set; 'mp4' (H.264) has no alpha and is composited onto bg_color; 'gif' is a looping GIF with 1-bit transparency (opaque when bg_color is set) and no audio, capped at 1280 px on the longest side (720p for widescreen) and 50 fps (large files, soft edges are hard-cut) for stickers, chat and email: use size 'preview' for sticker-sized output | webm |
| bg_color | No | Background color (hex, rgb, or color name). Setting it fills the background, so the result is opaque in every format (webm, mov and gif included); with channels 'rgb' or format 'mp4' and no bg_color the background is white. Omit it for a transparent video. Ignored with channels 'alpha'. Example: '#00ff00' for green screen | |
| channels | No | 'rgba' for a transparent video (opaque on bg_color if one is set), 'rgb' for an opaque video on bg_color, 'alpha' for a grayscale matte video (no audio) | rgba |
| video_url | No | Public https URL of the video (mp4, mov, webm, m4v, mkv or animated gif; up to 500 MB and 5 minutes). Set this or file |