Audio

Edit Audio

Comprehensive audio editing with one operation — the audio counterpart of Edit Video. Trim the audio, apply fades, adjust loudness, and change the format, bitrate and sample rate of the input audio. Send the audio source together with an export object describing the output you want. For example, {"audio_url": "https://example.com/input.wav", "export": {"format": "mp3", "bitrate": 192, "sample_rate": 44100}} produces a 192 kb/s, 44.1 kHz MP3. Leave bitrate empty to let the service pick an optimal value, and omit sample_rate unless you need a specific one. Trim with start / end (both in milliseconds), and shape the edges with fade_in / fade_out or trim_silence. Set loudness with either volume (a dB offset) or normalize (a -16 LUFS broadcast target). Two pairs are mutually exclusive: trim_silence cannot be combined with fade_out, and normalize cannot be combined with volume.

post/audio/edit

Request

  • Base URL
    https://video-api.picsart.io/v1
  • URL
    https://video-api.picsart.io/v1/audio/edit
  • Auth
    API key in header X-Picsart-API-Key

Request body

audio_urlstring uri

Source audio URL.

startinteger

The point in time of the audio from where the trimming (in milliseconds) begins.

endinteger

The point in time of the audio where the trimming (in milliseconds) ends. It must be greater than start. Leave empty to trim to the end of the audio.

fade_ininteger

Fade-in duration in milliseconds, applied from the beginning of the output.

fade_outinteger

Fade-out duration in milliseconds, applied to the end of the output. Cannot be combined with trim_silence.

trim_silenceboolean

Remove silence from the beginning and the end of the audio. Cannot be combined with fade_out.

volumenumber

Volume adjustment in dB. Negative values make the audio quieter, positive values louder. Cannot be combined with normalize.

normalizeboolean

Normalize loudness to a broadcast target of -16 LUFS. Cannot be combined with volume.

Response

Request successfully accepted for an asynchronous transformation.

transaction_idstring nullable
status'success' | 'error' | 'processing' | 'queued'

Changes

No recorded changes to this operation across all 1 revision of this API.