Eranol LogoEranol
BlogCommunityDocumentationPricingSign In

General

OverviewGet Started

Universal

Add IntroAdd OutroAudio to VideoBackground AudioCaptions ApiComposeConcatConvert a video file to MP4Convert Audio to Mp3Convert Audio to wavConvert to JPGConvert to WebMConvert to WebPDenoiseEnhanceExtract audio track from a videoExtract images from a videoGenerate a GIF from a videoHighlightsImage TestMergeNotifyOverlayProgress BarReframeRemove SilenceThumbnailTikTokTrimVerifyWatermarkZoom

General

DeleteImage StatusStatusTikTok StatusFFmpeg Results

Need help?

Contact Support

Trim

POST

Trim a video by start and end time. Cuts the video between start_sec and end_sec using stream copy (no re-encoding) for fast, lossless trimming. Example: {"url": "https://cdn.example.com/video.mp4", "start_sec": 10, "end_sec": 30}

Overview

Trim a video by start and end time.

Cuts the video between start_sec and end_sec using stream copy (no re-encoding) for fast, lossless trimming.

Endpoint

POST https://eranol.com/api/v1/ffmpeg/video/trim

Request Body

{
  "url": "https://example.com/",
  "end_sec": 0,
  "start_sec": 0
}

Response Example

{
  "job_id": "f595b9ad-1e15-4452-b7c2-8f8ff09c0a34",
  "status": "pending",
  "message": "Job created. Poll status_url for progress.",
  "job_type": "caption",
  "result_url": "https://eranol.com/api/v1/ffmpeg/result/f595b9ad-1e15-4452-b7c2-8f8ff09c0a34",
  "status_url": "https://eranol.com/api/v1/ffmpeg/status/f595b9ad-1e15-4452-b7c2-8f8ff09c0a34"
}

Use Cases

1. Cut a highlight from a long video

Trim out a specific 30-second segment from a long conference recording to share as a standalone clip.

Request Body

{
  "url": "https://cdn.example.com/conference-keynote.mp4",
  "end_sec": 210,
  "start_sec": 180
}

Response

{
  "job_id": "1406c589-a1f4-45d5-8745-aae07bc4de38",
  "status": "pending",
  "message": "Job created. Poll status_url for progress.",
  "result_url": "https://eranol.com/api/v1/ffmpeg/result/1406c589-a1f4-45d5-8745-aae07bc4de38",
  "status_url": "https://eranol.com/api/v1/ffmpeg/status/1406c589-a1f4-45d5-8745-aae07bc4de38"
}

2. Remove intro and outro

Cut off the first 10 seconds (branded intro) and the last 20 seconds (outro) from a video to keep only the core content.

Request Body

{
  "url": "https://cdn.example.com/episode-with-intro.mp4",
  "end_sec": 340,
  "start_sec": 10
}

Response

{
  "job_id": "1406c589-a1f4-45d5-8745-aae07bc4de38",
  "status": "pending",
  "message": "Job created. Poll status_url for progress.",
  "result_url": "https://eranol.com/api/v1/ffmpeg/result/1406c589-a1f4-45d5-8745-aae07bc4de38",
  "status_url": "https://eranol.com/api/v1/ffmpeg/status/1406c589-a1f4-45d5-8745-aae07bc4de38"
}

3. Clip a short social media post

Extract the best 15-second moment from a longer video for a TikTok or Reels upload.

Request Body

{
  "url": "https://cdn.example.com/full-video.mp4",
  "end_sec": 60,
  "start_sec": 45
}

Response

{
  "job_id": "1406c589-a1f4-45d5-8745-aae07bc4de38",
  "status": "pending",
  "message": "Job created. Poll status_url for progress.",
  "result_url": "https://eranol.com/api/v1/ffmpeg/result/1406c589-a1f4-45d5-8745-aae07bc4de38",
  "status_url": "https://eranol.com/api/v1/ffmpeg/status/1406c589-a1f4-45d5-8745-aae07bc4de38"
}

Error Codes

CodeMeaning
401Missing or invalid API key
402Insufficient credits
422Validation error — check your request body
429Rate limit exceeded — slow down requests
500Internal server error — try again or contact support