example-data.com
Menu
Browse docs and collections

songs

songs

Page 93 of 125.

Overview

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/songs?limit=25"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/songs?limit=25"
);
const { data, meta } = 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, ListEnvelope } from "./types/songs";

const res = await fetch(
  "https://example-data.com/api/v1/songs?limit=25"
);
const { data, meta } = (await res.json()) as ListEnvelope<Song>;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/songs",
    params={"limit": 25},
)
data = res.json()

Response

{
  "data": [
    {
      "id": 2209,
      "albumId": 208,
      "artistId": 73,
      "title": "Don't You (Forget About Me)",
      "slug": "dont-you-forget-about-me-2209",
      "trackNumber": 2,
      "durationSeconds": 254,
      "isExplicit": false,
      "playCount": 6430998,
      "createdAt": "2021-10-03T21:43:53.347Z"
    },
    {
      "id": 2210,
      "albumId": 208,
      "artistId": 73,
      "title": "My Boyfriend's Back",
      "slug": "my-boyfriends-back-2210",
      "trackNumber": 3,
      "durationSeconds": 353,
      "isExplicit": false,
      "playCount": 16721098,
      "createdAt": "2021-10-14T14:10:34.112Z"
    },
    {
      "id": 2211,
      "albumId": 208,
      "artistId": 73,
      "title": "You Don't Have to Be a Star (To Be in My Show)",
      "slug": "you-dont-have-to-be-a-star-to-be-in-my-show-2211",
      "trackNumber": 4,
      "durationSeconds": 306,
      "isExplicit": false,
      "playCount": 49355533,
      "createdAt": "2024-11-27T11:32:25.967Z"
    }
  ],
  "meta": {
    "page": 93,
    "limit": 24,
    "total": 2978,
    "totalPages": 125
  },
  "links": {
    "self": "/api/v1/songs?page=93&limit=24",
    "first": "/api/v1/songs?page=1&limit=24",
    "last": "/api/v1/songs?page=125&limit=24",
    "next": "/api/v1/songs?page=94&limit=24",
    "prev": "/api/v1/songs?page=92&limit=24"
  }
}