Delete song
February 17, 2025
Table of contents
This endpoint will return an empty HTTP 200 response if the song was deleted successfully.
https://api.useapi.net/v1/riffusion/music/?…
Request Headers
Authorization: Bearer {API token}
Content-Type: application/json
API token
is required, see Setup useapi.net for details.
Query Parameters
-
user_id
is optional when only one account configured. However, if you have multiple accounts configured, this parameter becomes required. -
id
is required, specify the musicid
to delete. See GET music.
Responses
-
This endpoint will return an empty HTTP 200 response if the song was deleted successfully.
-
{ "error": "<Error message>", "code": 400 }
-
{ "error": "Unauthorized", "code": 401 }
-
596 Pending error
API was unable to refresh your cookie. Please resolve this issue by using the POST accounts endpoint before making any new API calls.
{ "error": "Your Riffusion account has pending error. Please address this issue at https://useapi.net/docs/api-riffusion-v1/post-riffusion-accounts before making any new API calls." }
Examples
-
curl -H "Authorization: Bearer …" \ -X DELETE "https://api.useapi.net/v1/riffusion/music/?id=<id>"
-
const token = "API token"; const user_id = "Previously configured account"; const apiUrl = `https://api.useapi.net/v1/riffusion/music/?user_id=${user_id}`; const response = await fetch(apiUrl, { headers: { "Authorization": `Bearer ${token}`, }, }); const result = await response.json(); console.log("response", {response, result});
-
import requests token = "API token" user_id = "Previously configured account" apiUrl = f"https://api.useapi.net/v1/riffusion/music/?user_id={user_id}" headers = { "Content-Type": "application/json", "Authorization" : f"Bearer {token}" } response = requests.get(apiUrl, headers=headers) print(response, response.json())