POST
/
deecho
Python
import requests

url = "https://api.musicgpt.com/api/public/v1/deecho"
headers = {
    "Authorization": "<<<api key>>>"
}

# Option 1: URL
payload = {
    "audio_url": "https://example.com/audio.m4a",
    "webhook_url": ""
}
response = requests.post(url, headers=headers, data=payload)
print(response.json())

# Option 2: File Upload
# payload = {
#     "webhook_url": "https://www.test.requestcatcher.com/test"
# }
# with open("audio.m4a", "rb") as f:
#     files = {"audio_file": f}
#     response = requests.post(url, headers=headers, data=payload, files=files)
# print(response.json())
{
  "success": true,
  "task_id": "deecho789",
  "conversion_id": "conv456",
  "eta": -1,
  "credit_estimate": 100.1
}

Remove echo from input audio with optional webhook support for async updates.

Endpoint

POST /deecho

This endpoint processes an audio file to reduce or eliminate echo effects. You can specify a webhook_url to receive a callback when processing completes.


Request Parameters

ParameterTypeRequiredDescription
audio_urlStringOptionalThe URL of an audio file to remove echo from. Either audio_url or audio_file must be provided.
audio_fileUploadFileOptionalUpload the audio file directly. Either audio_url or audio_file must be provided.
webhook_urlStringOptionalCallback URL for async response.

šŸ’” Note: You must provide either audio_url or audio_file — not both as None.


Sample Output

Listen to a real sample output:

Download Audio

Try it Yourself

Visit the Deecho Endpoint Explorer to try your own text samples.

šŸ’” Tip: Set a webhook_url to receive results automatically when your audio is ready.


Sample Request

cURL

curl -X POST "https://api.musicgpt.com/api/public/v1/Deecho" \
-H "accept: application/json" \
-H "Authorization: <api_key>" \
-F "audio_url=https://www.youtube.com/watch?v=jGflUbPQfW8" \
-F "webhook_url=http://webhook.musicgpt.com"

Python

import requests

url = "https://api.musicgpt.com/api/public/v1/deecho"
headers = {
    "Authorization": "<<<api key>>>"
}

# Option 1: URL
payload = {
    "audio_url": "https://example.com/audio.m4a",
    "webhook_url": ""
}
response = requests.post(url, headers=headers, data=payload)
print(response.json())

# Option 2: File Upload
# payload = {
#     "webhook_url": "https://www.test.requestcatcher.com/test"
# }
# with open("audio.m4a", "rb") as f:
#     files = {"audio_file": f}
#     response = requests.post(url, headers=headers, data=payload, files=files)
# print(response.json())

šŸ” Replace {path_to_your_audio_file}, api_key, and webhook_url before executing.


Sample Response

Success (200 OK)

{
  "success":true,
  "task_id":"938a071a-a5f5-40df-8eeb-972edcff26c4",
  "conversion_id":"e53b1bb5-381c-4e6f-844d-6a604002483c",
  "eta":59,
  "credit_estimate":0.48,
  "message":"Message published to queue",
  "status":"IN_QUEUE"
}

Webhook Response

Success (200 OK)

{
  "success": true, 
  "conversion_type": "Deecho", 
  "task_id": "938a071a-a5f5-40df-8eeb-972edcff26c4", 
  "conversion_id": "e53b1bb5-381c-4e6f-844d-6a604002483c", 
  "audio_path": "files/8fd19e25-88c2-49e9-9641-7214cbe99a4f.wav", 
  "no_echo": "https://lalals.s3.amazonaws.com/conversions/938a071a-a5f5-40df-8eeb-972edcff26c4_noecho.mp3", 
  "no_echo_wav": "https://lalals.s3.amazonaws.com/conversions/938a071a-a5f5-40df-8eeb-972edcff26c4_noecho.wav", 
  "echo": "https://lalals.s3.amazonaws.com/conversions/938a071a-a5f5-40df-8eeb-972edcff26c4_echo.mp3", 
  "echo_wav": "https://lalals.s3.amazonaws.com/conversions/938a071a-a5f5-40df-8eeb-972edcff26c4_echo.wav", 
  "message": "de_echo conversion Completed", 
  "conversion_duration": 136.82721088435375, 
  "conversion_cost": "0.48"
}

Common Errors

  • 422 Unprocessable Entity: Both audio_url and audio_file cannot be None.
  • 500 Internal Server Error: An error occurred on the server.

Payload and Request Formation

Authorizations

Authorization
string
header
required

Body

multipart/form-data

Response

200
application/json

Successfully initiated echo removal

The response is of type object.