1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
const axios = require('axios');
const api_key = "YOUR API-KEY";
const url = "https://api.segmind.com/v1/video-audio-merge";
const data = {
"input_video": "https://segmind-sd-models.s3.amazonaws.com/display_images/video-audio-merge-input.mp4",
"input_audio": "https://segmind-sd-models.s3.amazonaws.com/display_images/audio-merge-input-aud.mp3",
"video_start": 0,
"video_end": -1,
"audio_start": 0,
"audio_end": -1,
"audio_fade_in": 0,
"audio_fade_out": 0,
"override_audio": false,
"merge_intensity": 0.5
};
(async function() {
try {
const response = await axios.post(url, data, { headers: { 'x-api-key': api_key } });
console.log(response.data);
} catch (error) {
console.error('Error:', error.response.data);
}
})();
URL of the input video to be merged
URL of the input audio to be merged with the video
Start time of the video in seconds
End time of the video in seconds (-1 for full duration)
min : -1,
max : 3600
Start time of the audio in seconds
min : 0,
max : 3600
End time of the audio in seconds (-1 for full duration)
min : -1,
max : 3600
Duration of audio fade-in effect in seconds
min : 0,
max : 10
Duration of audio fade-out effect in seconds
min : 0,
max : 10
Whether to completely replace the original video audio
Intensity of audio merging (0.0 to 1.0)
min : 0,
max : 1
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Optimize your multimedia projects with our cutting-edge Video Audio Merge model. Effortlessly combine audio tracks with video files to create a cohesive and engaging viewer experience. Perfect for content creators, filmmakers, and marketing professionals.
Drag-and-Drop Functionality: Easily upload video and audio files with a simple drag-and-drop feature.
URL Uploads: Seamlessly integrate files via URL for fast processing.
Video and Audio Timing: Set precise video and audio start and end times to ensure perfect synchronization.
Fade Effects: Customize audio fade-in and fade-out durations for smooth transitions.
Override Original Audio: Option to completely replace the original video audio with the new track.
Merge Intensity: Adjust merge intensity levels for balanced audio-video integration.
Enhanced Production Quality: Create professional-grade videos with precisely synchronized audio.
Time-Efficient: Save time with an easy-to-navigate interface and fast processing.
Versatile Usability: Ideal for social media posts, advertisements, vlogs, and more.