POST
/
VoiceChanger
import requests

url = "https://api.musicgpt.com/api/public/v1/VoiceChanger"

payload = {
    "audio_url": "<string>",
    "voice_id": "<string>",
    "remove_background": "<int>",
    "pitch": "<int>",
    "webhook_url": "<string>"
}

# For file upload instead of URL:
# files = {'audio_file': open('filepath', 'rb')}

headers = {
    "Authorization": "<API Key>"
}

response = requests.post(url, data=payload, headers=headers)
# For file upload:
# response = requests.post(url, data=payload, files=files, headers=headers)

print(response.text)
{
  "success": true,
  "task_id": "84038e1e-3687-4f7a-9c55-692754b125ee",
  "conversion_id": "e3631817-165d-4f17-a7e2-7008d200ff3e",
  "eta": 22
}

Authorizations

Authorization
string
header
required

Body

multipart/form-data

Response

200
application/json

Successful response

The response is of type object.