Apple Music search API
  1. Docs
  2. Apple Music
  3. Apple Music search API

Apple Music search API

Public results for artists, albums, songs, playlists, stations and music videos.

GET /v1/apple-music/search

GET /v1/apple-music/search

Public results for artists, albums, songs, playlists, stations and music videos. Without type every section is returned, 8 of each; with type, 25 of that kind. Music videos come back as songs with extra.type "music_video", playlists and stations as collections. radio_episode is not offered by Apple's public catalog search and answers invalid_params.

  • Cost: 1 credit
  • Cache: Results are kept up to 30 days; send max_age_days to reuse them for free.
  • Timeout: A request still running after about 25 seconds answers 202 with a job to poll (Batch and jobs).

Parameters#

NameTypeRequiredDescription
querystringyesSearch terms. Also accepted as keyword, q.
typestringnoKind of result; all returns every section. One of all, song, album, artist, playlist, station, music_video, radio_episode.

Every request also accepts:

  • cursor: the cursor from the previous page (Pagination).
  • region: two-letter country code for results that vary by country. Changing it restarts the cursor chain.
  • trim: true for a smaller response without null fields and extra.
  • raw: true to also get the platform's original object as raw.
  • max_age_days: accept a cached result up to this many days old, for 0 credits (Caching).

Example request#

Set your key in the environment first (see Authentication).

1curl -G "https://api.socialscrape.dev/v1/apple-music/search" \2  -H "x-api-key: $SOCIALSCRAPE_API_KEY" \3  --data-urlencode "query=taylor swift"

Example response#

This is a sample from a recorded response, lists and long text are shortened. Status 200.

200 OKSample response
1{2  "ok": true,3  "credits_charged": 1,4  "credits_remaining": 4999,5  "cached": false,6  "cached_at": null,7  "request_id": "req_f3f43a799c553e6ac0c4b212",8  "data": {9    "object": "list",10    "items": [11      {12        "object": "profile",13        "platform": "apple_music",14        "id": "159260351",15        "handle": null,16        "name": "Taylor Swift",17        "headline": null,18        "url": "https://music.apple.com/us/artist/taylor-swift/159260351",19        "kind": "artist",20        "bio": null,21        "avatar_url": "https://is1-ssl.mzstatic.com/image/thumb/AMCArtistImages221/v4/6d/67/88/6d67888b-9e7f-53af-7853-0f91d6fd2332/ami_U003aidentity_U003a994af5c375f4c3aa96cd6ced4a700799-2026-09-25T04-00-05.358Z_cropped.png/1200x1200bb.jpg",22        "banner_url": null,23        "verified": null,24        "is_private": null,25        "external_url": null,26        "links": null,27        "location": null,28        "category": "Pop",29        "created_at": null,30        "stats": {31          "followers": null,32          "following": null,33          "posts": null,34          "likes": null,35          "views": null36        },37        "extra": {38          "editorial_notes": {39            "short": "Favorite Taylor’s artist page for updates on The Life of a Showgirl."40          },41          "genres": [42            "Pop"43          ]44        }45      },46      {47        "object": "album",48        "platform": "apple_music",49        "id": "6814997249",50        "url": "https://music.apple.com/us/album/the-life-of-a-showgirl-the-encore/6814997249",51        "title": "The Life of a Showgirl: The Encore",52        "artists": [53          "Taylor Swift"54        ],55        "released_at": "2026-09-24",56        "track_count": 16,57        "cover_url": "https://is1-ssl.mzstatic.com/image/thumb/Music221/v4/a0/dd/fd/a0ddfd72-ee9e-f046-6466-a5dbefc696fa/26UM1IM21436.rgb.jpg/1200x1200bb.jpg",58        "label": "Taylor Swift",59        "tracks": null,60        "extra": {61          "content_rating": "explicit",62          "genres": [63            "Pop",64            "Music"65          ],66          "is_single": false,67          "upc": "00881061651819"68        }69      }70    ],71    "cursor": "eyJvIjo4fQ",72    "has_more": true,73    "parent": null74  },75  "cursor": "eyJvIjo4fQ",76  "has_more": true77}

Response#

A list of Song or Album or Profile or Collection objects in data.items, with data.cursor and data.has_more.

See Data models for every field. The envelope around data is described in Responses.

Errors#

Failures are free: credits_charged is 0. Branch on error.code, never on the message.

CodeHTTPRetryMeaning
invalid_params400noA parameter is missing, unknown or has the wrong type.
not_found404noThe platform says this profile, post or item does not exist.

Every request can also fail with the account and platform errors listed on the Errors page.

Example error:

1{2  "ok": false,3  "error": {4    "code": "invalid_params",5    "message": "A parameter is missing, unknown or has the wrong type.",6    "retryable": false7  },8  "credits_charged": 0,9  "request_id": "req_21e71a697946aeb5d33eb46f"10}