Music Search
curl --request POST \
--url http://localhost:9000/api/v1/musicsearch \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"song": "<string>",
"limit": "<string>",
"proxy": "<string>"
}
'import requests
url = "http://localhost:9000/api/v1/musicsearch"
payload = {
"song": "<string>",
"limit": "<string>",
"proxy": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({song: '<string>', limit: '<string>', proxy: '<string>'})
};
fetch('http://localhost:9000/api/v1/musicsearch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "9000",
CURLOPT_URL => "http://localhost:9000/api/v1/musicsearch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'song' => '<string>',
'limit' => '<string>',
'proxy' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:9000/api/v1/musicsearch"
payload := strings.NewReader("{\n \"song\": \"<string>\",\n \"limit\": \"<string>\",\n \"proxy\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://localhost:9000/api/v1/musicsearch")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"song\": \"<string>\",\n \"limit\": \"<string>\",\n \"proxy\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:9000/api/v1/musicsearch")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"song\": \"<string>\",\n \"limit\": \"<string>\",\n \"proxy\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body[{"song_name":"All of You - Davido","shazam_url":"https://www.shazam.com/track/91360961/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music114/v4/38/6d/51/386d51f3-4a55-1930-59ae-743c403556fe/3487.jpg/400x400cc.jpg"},{"song_name":"All Of You - Stephanie Beatriz, Olga Merediz, John Leguizamo, Adassa, Maluma \u0026 Encanto - Cast","shazam_url":"https://www.shazam.com/track/591769919/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music126/v4/94/4d/9a/944d9a8d-0549-f537-5706-5b083bd84a7d/21UM1IM38949.rgb.jpg/400x400cc.jpg"},{"song_name":"All of You - Sebastian Sternal","shazam_url":"https://www.shazam.com/track/340743865/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music122/v4/85/09/bd/8509bd27-f393-0c3d-e957-c20407e2943c/705304464625_cover.jpg/400x400cc.jpg"},{"song_name":"All of You - Diana Ross","shazam_url":"https://www.shazam.com/track/2938180/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music4/v4/e1/b7/d4/e1b7d4d5-741f-fab7-f913-ca96e10788a9/5099968897758_1460x1460_300dpi.jpg/400x400cc.jpg"},{"song_name":"All of You - Duran Duran","shazam_url":"https://www.shazam.com/track/569197814/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music126/v4/04/31/94/043194e2-01c8-e7f6-4870-817101ca6b73/4050538778960.jpg/400x400cc.jpg"}]
Endpoint Examples
Music Search
music search
POST
v1
/
musicsearch
Music Search
curl --request POST \
--url http://localhost:9000/api/v1/musicsearch \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"song": "<string>",
"limit": "<string>",
"proxy": "<string>"
}
'import requests
url = "http://localhost:9000/api/v1/musicsearch"
payload = {
"song": "<string>",
"limit": "<string>",
"proxy": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({song: '<string>', limit: '<string>', proxy: '<string>'})
};
fetch('http://localhost:9000/api/v1/musicsearch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "9000",
CURLOPT_URL => "http://localhost:9000/api/v1/musicsearch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'song' => '<string>',
'limit' => '<string>',
'proxy' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:9000/api/v1/musicsearch"
payload := strings.NewReader("{\n \"song\": \"<string>\",\n \"limit\": \"<string>\",\n \"proxy\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://localhost:9000/api/v1/musicsearch")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"song\": \"<string>\",\n \"limit\": \"<string>\",\n \"proxy\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:9000/api/v1/musicsearch")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"song\": \"<string>\",\n \"limit\": \"<string>\",\n \"proxy\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body[{"song_name":"All of You - Davido","shazam_url":"https://www.shazam.com/track/91360961/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music114/v4/38/6d/51/386d51f3-4a55-1930-59ae-743c403556fe/3487.jpg/400x400cc.jpg"},{"song_name":"All Of You - Stephanie Beatriz, Olga Merediz, John Leguizamo, Adassa, Maluma \u0026 Encanto - Cast","shazam_url":"https://www.shazam.com/track/591769919/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music126/v4/94/4d/9a/944d9a8d-0549-f537-5706-5b083bd84a7d/21UM1IM38949.rgb.jpg/400x400cc.jpg"},{"song_name":"All of You - Sebastian Sternal","shazam_url":"https://www.shazam.com/track/340743865/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music122/v4/85/09/bd/8509bd27-f393-0c3d-e957-c20407e2943c/705304464625_cover.jpg/400x400cc.jpg"},{"song_name":"All of You - Diana Ross","shazam_url":"https://www.shazam.com/track/2938180/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music4/v4/e1/b7/d4/e1b7d4d5-741f-fab7-f913-ca96e10788a9/5099968897758_1460x1460_300dpi.jpg/400x400cc.jpg"},{"song_name":"All of You - Duran Duran","shazam_url":"https://www.shazam.com/track/569197814/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music126/v4/04/31/94/043194e2-01c8-e7f6-4870-817101ca6b73/4050538778960.jpg/400x400cc.jpg"}]
Request Body
Song you want to search for
Search Limit
Proxy
Response
Name of the song recognized.
Url to the song on shazam
Song cover image
[{"song_name":"All of You - Davido","shazam_url":"https://www.shazam.com/track/91360961/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music114/v4/38/6d/51/386d51f3-4a55-1930-59ae-743c403556fe/3487.jpg/400x400cc.jpg"},{"song_name":"All Of You - Stephanie Beatriz, Olga Merediz, John Leguizamo, Adassa, Maluma \u0026 Encanto - Cast","shazam_url":"https://www.shazam.com/track/591769919/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music126/v4/94/4d/9a/944d9a8d-0549-f537-5706-5b083bd84a7d/21UM1IM38949.rgb.jpg/400x400cc.jpg"},{"song_name":"All of You - Sebastian Sternal","shazam_url":"https://www.shazam.com/track/340743865/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music122/v4/85/09/bd/8509bd27-f393-0c3d-e957-c20407e2943c/705304464625_cover.jpg/400x400cc.jpg"},{"song_name":"All of You - Diana Ross","shazam_url":"https://www.shazam.com/track/2938180/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music4/v4/e1/b7/d4/e1b7d4d5-741f-fab7-f913-ca96e10788a9/5099968897758_1460x1460_300dpi.jpg/400x400cc.jpg"},{"song_name":"All of You - Duran Duran","shazam_url":"https://www.shazam.com/track/569197814/all-of-you","song_image":"https://is1-ssl.mzstatic.com/image/thumb/Music126/v4/04/31/94/043194e2-01c8-e7f6-4870-817101ca6b73/4050538778960.jpg/400x400cc.jpg"}]
Was this page helpful?
⌘I