Browse docs and collections
Overview
songs / #795
Component variants
Medium
Empire State Of Mind
· 3 min
Small
Empire State Of Mind Related
Request
curl example
curl -sS \ "https://example-data.com/api/v1/songs/795" \ -H "Accept: application/json"
JavaScript example
const res = await fetch( "https://example-data.com/api/v1/songs/795" ); const song = await res.json();
TypeScript example
// Download once: mkdir -p types && curl -o types/songs.d.ts https://example-data.com/types/songs.d.ts
import type { Song } from "./types/songs";
const res = await fetch(
"https://example-data.com/api/v1/songs/795"
);
const song = (await res.json()) as Song; Python example
import requests
res = requests.get(
"https://example-data.com/api/v1/songs/795"
)
song = res.json() Response
{
"id": 795,
"albumId": 74,
"artistId": 30,
"title": "Empire State Of Mind",
"slug": "empire-state-of-mind-795",
"trackNumber": 6,
"durationSeconds": 190,
"isExplicit": false,
"playCount": 12657876,
"createdAt": "2024-08-10T19:34:27.819Z"
}