Delete track

December 13, 2024

Table of contents

  1. Request Headers
  2. Query Parameters
  3. Responses
  4. Examples
  5. Try It

Delete track which was uploaded using POST /files.

https://api.useapi.net/v1/mureka/files/?…

Request Headers
Authorization: Bearer {API token}
Content-Type: application/json
Query Parameters
  • account is optional when only one account configured. However, if you have multiple accounts configured, this parameter becomes required.

  • id is required, to see full list of uploaded tracks use GET /files.

Responses
Examples
  • curl -H "Accept: application/json" \
         -H "Content-Type: application/json" \
         -H "Authorization: Bearer …" \
         -X DELETE https://api.useapi.net/v1/mureka/files/?account=<accound>&id=<id>
    
  • const account = 123456789; 
    const id = 98765432; 
    const apiUrl = `https://api.useapi.net/v1/mureka/files/?account=${account}&id=${id}`; 
    const token = "API token";
    const data = { 
      method: 'DELETE',
      headers: {
        'Authorization': `Bearer ${token}`,
        'Content-Type': 'application/json' }
    };
    const response = await fetch(apiUrl, data);
    const result = await response.json();
    console.log("response", {response, result});
    
  • import requests
    account = 123456789
    id = 98765432
    apiUrl = f"https://api.useapi.net/v1/mureka/files/?account={account}&id={id}" 
    token = "API token"
    headers = {
        "Content-Type": "application/json", 
        "Authorization" : f"Bearer {token}"
    }
    response = requests.delete(apiUrl, headers=headers)
    print(response, response.json())
    
Try It