example-data.com
Menu
Browse docs and collections

Overview

playlists / #195

I Heard it Through the Grapevine Mix

I Heard it Through the Grapevine Mix

Voluptatibus abstergo caterva depromo aegrotatio eaque culpa bibo.

Component variants

Related

Request

curl example

curl -sS \
  "https://example-data.com/api/v1/playlists/195" \
  -H "Accept: application/json"

JavaScript example

const res = await fetch(
  "https://example-data.com/api/v1/playlists/195"
);
const playlist = await res.json();

TypeScript example

// Download once: mkdir -p types && curl -o types/playlists.d.ts https://example-data.com/types/playlists.d.ts
import type { Playlist } from "./types/playlists";

const res = await fetch(
  "https://example-data.com/api/v1/playlists/195"
);
const playlist = (await res.json()) as Playlist;

Python example

import requests

res = requests.get(
    "https://example-data.com/api/v1/playlists/195"
)
playlist = res.json()

Response

{
  "id": 195,
  "userId": 94,
  "name": "I Heard it Through the Grapevine Mix",
  "slug": "i-heard-it-through-the-grapevine-mix-195",
  "description": "Voluptatibus abstergo caterva depromo aegrotatio eaque culpa bibo.",
  "songIds": [
    780,
    2841,
    557,
    1745,
    2617,
    2018,
    860,
    501,
    572,
    410,
    1780,
    1638,
    1259
  ],
  "isPublic": true,
  "coverUrl": "https://picsum.photos/seed/playlist-195/500/500",
  "createdAt": "2024-07-26T12:51:45.048Z",
  "updatedAt": "2024-08-12T16:54:36.448Z"
}