Remove hardcoded subtitles, on-screen text, watermarks and corner logos from a video, rebuilding a clean background where they were. High-frame-rate detection plus AIGC inpainting with multi-frame consistency, so the patch does not shimmer. Two ways to say what should go: automatic mode finds the text for you, and region mode works on rectangles you supply — the route for watermarks, station bugs and signatures, which detection would never classify as text. Output resolution matches the input (up to 1080p), billed $0.015 per second of video, charged only on success.
In region mode, make the rectangle about 30-50% larger than the mark itself. A box cropped tight to the mark very often returns the video unchanged, while the same mark with margin around it is removed cleanly. For a corner logo, run the box out to the frame edges — there is nothing there to protect.
This is by far the most common reason a region erase appears to do nothing — and we learned it the hard way: our own first tests boxed the mark exactly and we nearly concluded the feature was broken.
| eraseMode | Use it for | What the boxes do |
|---|---|---|
| auto (default) | Hardcoded subtitles, any on-screen text | Optional. They only NARROW detection — just the text found inside them is erased |
| manual | Watermarks, corner logos, station bugs, signatures | Required. The boxes ARE the target — no reliance on text detection |
The same eraseRatioLocation means two different things depending on the mode, and this is the easy mistake: box a text-free logo in auto mode and nothing changes at all, because there is no text inside the box to find. To erase something that is not text, switch to manual.
POST /api/v1/video/generations — async: create, then poll the same endpoint for the result.
# ── Region mode — remove a watermark / corner logo ──────────────────────
# Box the mark with normalized 0-1 coordinates (fractions of width/height).
curl -X POST https://apimodels.app/api/v1/video/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "subtitle-erase",
"video_url": "https://example.com/clip-with-watermark.mp4",
"eraseMode": "manual",
"eraseRatioLocation": [
{ "topLeftX": 0.70, "topLeftY": 0.02, "bottomRightX": 1.0, "bottomRightY": 0.20 }
]
}'
# ⚠️ Draw the box GENEROUSLY — about 30-50% larger than the mark itself.
# A box cropped tight to the mark very often returns the video unchanged.
# For a corner logo, run the box out to the frame edges as above.
# ── Automatic mode — remove hardcoded subtitles (no box needed) ─────────
curl -X POST https://apimodels.app/api/v1/video/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "subtitle-erase",
"video_url": "https://example.com/clip-with-subtitles.mp4",
"eraseType": "subtitle"
}'
# Poll until state == "completed" — data.resultUrls[0] is the cleaned video.
# Result files are kept 7 days.
curl "https://apimodels.app/api/v1/video/generations?task_id=TASK_ID" \
-H "Authorization: Bearer YOUR_API_KEY"| Field | Required | Type | Description |
|---|---|---|---|
| model | Yes | string | Always subtitle-erase |
| video_url | Yes | string | Public URL of the video to clean (MP4 / MOV) |
| eraseMode | No | string | "auto" (default — detects text for you) or "manual" (works on your boxes; eraseRatioLocation then required) |
| eraseType | No | string | "subtitle" (default, caption-style only) or "text" (any on-screen text). Auto mode only |
| eraseRatioLocation | No | array | Normalized (0-1) boxes [{ topLeftX, topLeftY, bottomRightX, bottomRightY }]. Required in manual mode. ⚠️ Draw them 30-50% larger than the mark |
| clipFilter | No | object | { mode: "Selected" | "Skip", clips: [{ start, end }] } — in seconds, clean only ("Selected") or skip ("Skip") these ranges. Works in both modes |
| callback_url | No | string | Called when the task finishes, so you can skip polling |
Yes. POST the video URL plus a normalized 0-1 rectangle around the mark to /api/v1/video/generations with model "subtitle-erase" and eraseMode "manual", then poll the task id. You get back a video with the background rebuilt where the mark was, at the input resolution up to 1080p, for $0.015 per second.
Almost always the box was too tight. Draw it roughly 30-50% larger than the mark — a rectangle cropped to the visible edge frequently returns the video unchanged, while the same mark with margin is removed cleanly. Also check that eraseMode is "manual": in the default auto mode your boxes only narrow where text detection may look, so a box around a text-free logo changes nothing. Coordinates are fractions of width and height between 0 and 1, not pixels.
$0.015 per second of the input video, charged only on success — 30 seconds is $0.45 and 3 minutes is $2.70. Subtitles, on-screen text and watermarks are all the same price. Restricting the job to part of the timeline with clipFilter does not lower it, because the whole file is still decoded and re-encoded.
No. Leave eraseMode out and it runs automatically: eraseType "subtitle" (the default) removes caption-style subtitles wherever they appear, and eraseType "text" removes any on-screen text. Boxes are optional there and only narrow where detection looks, which helps when you want the lower third cleaned but a title card kept.
MP4 and MOV input via a public URL. Output resolution matches the input and is capped at 1080p by the upstream. It is an async create-then-poll job; result files are hosted for 7 days, so download or re-host anything you need to keep.