Skip to content

Extracting Audio from Video

The Arc XP Audio API can accept MP4 video files as input and automatically extract the audio track. This is useful when you have video content and need to produce a standalone audio version — for example, publishing a video interview as a podcast episode or creating an audio clip from a recorded presentation.

How It Works

When you upload an MP4 file to any upload endpoint, the API automatically:

  1. Detects the video container format.
  2. Extracts the audio track, discarding the video stream.
  3. Encodes the extracted audio according to your organization’s configured encoding profile (see the developer guide for details).
  4. Follows the same processing lifecycle as a regular audio upload.

No special parameters or headers are needed — the API handles video-to-audio extraction transparently.

Supported Input Formats

FormatExtensionNotes
WAV.wavRecommended for highest quality source audio
MP3.mp3Recommended bitrate of at least 128kbps
FLAC.flacLossless compressed audio
M4A.m4aAAC audio in MP4 container
MP4.mp4Video container — audio track is extracted automatically

Example: Audio Clip from Video

1. Create an Audio Clip Record

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/clips/ \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"title": "Conference Keynote (Audio)",
"description": "Audio extracted from the recorded keynote presentation.",
"tags": ["conference", "keynote"]
}'

Save the content_id from the response. In the following examples, use that same value anywhere the URL shows {audio_id}.

2. Upload the MP4 File

Upload the video file exactly as you would an audio file:

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/clips/{audio_id}/upload \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-F "file=@/path/to/keynote.mp4"

The API extracts the audio track and begins processing. The video data is discarded.

3. Monitor Processing

To receive real-time updates on extraction and encoding progress, include the Accept: text/event-stream header:

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/clips/{audio_id}/upload \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Accept: text/event-stream" \
-F "file=@/path/to/keynote.mp4"

The SSE stream emits progress notifications such as encoding_started, encoding_analyzing, and encoding_complete (or encoding_failed).

4. Publish

Once processing completes and the clip is in READY state:

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/clips/{audio_id}/publish \
-H "Authorization: Bearer YOUR_API_TOKEN"

Example: Podcast Episode from Video

You can also upload MP4 files directly as podcast episode audio. This is common when repurposing video interviews or recorded sessions as podcast episodes.

1. Create the Episode

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/podcasts/{podcast_id}/episodes \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"title": "Interview with Jane Doe",
"description": "Audio from our recorded video interview."
}'

2. Upload the MP4

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/podcasts/{podcast_id}/episodes/{episode_guid}/upload \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-F "file=@/path/to/interview.mp4"

3. Publish the Episode

Terminal window
curl -X POST https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/podcasts/{podcast_id}/episodes/{episode_guid}/publish \
-H "Authorization: Bearer YOUR_API_TOKEN"

Using Presigned URLs

For browser-based uploads of large video files, use the presigned URL flow to upload directly to S3:

Terminal window
# Get a presigned upload URL
curl -X POST "https://api.[org].arcpublishing.com/audiocenter/api/editorial/v1/clips/{audio_id}/upload/presigned?file_name=keynote.mp4" \
-H "Authorization: Bearer YOUR_API_TOKEN"

The response includes an upload_url for direct upload and a notification_url for subscribing to processing updates. This avoids routing large video files through the API server.

Tips

  • File size: Video files are typically much larger than audio files. Consider using the presigned URL upload flow for files over 100 MB.
  • Audio quality: The quality of the extracted audio depends on the audio track in the source video. If the source video has a low-bitrate audio track, the extracted audio will reflect that.
  • No video output: The API only produces audio renditions. The video stream is discarded during processing and is not stored.