Pulsarman325
Pulsarman325

Reputation: 224

iTunes search api getting all tracks from result

I am doing a very simple search using iTunes api to try to retrieve a list of podcast of a certain user, the result only shows 1 but the track list is 25. Is there any way to view all “tracks”?

Upvotes: 3

Views: 1936

Answers (1)

Sol
Sol

Reputation: 344

I was able to reproduce the following result using the URL in your comment below:

{
  "resultCount": 1,
  "results": [
    {
      "wrapperType": "track",
      "kind": "podcast",
      "collectionId": 1157898727,
      "trackId": 1157898727,
      "artistName": "Phoenix FM",
      "collectionName": "The West Ham Way on Phoenix FM",
      "trackName": "The West Ham Way on Phoenix FM",
      "collectionCensoredName": "The West Ham Way on Phoenix FM",
      "trackCensoredName": "The West Ham Way on Phoenix FM",
      "collectionViewUrl": "https://itunes.apple.com/us/podcast/the-west-ham-way-on-phoenix-fm/id1157898727?mt=2&uo=4",
      "feedUrl": "http://feeds.feedburner.com/TheWestHamWayOnPhoenixFm",
      "trackViewUrl": "https://itunes.apple.com/us/podcast/the-west-ham-way-on-phoenix-fm/id1157898727?mt=2&uo=4",
      "artworkUrl30": "https://is1-ssl.mzstatic.com/image/thumb/Music42/v4/b1/c0/76/b1c076ed-e555-af3b-3f09-5dfc379da0cb/source/30x30bb.jpg",
      "artworkUrl60": "https://is1-ssl.mzstatic.com/image/thumb/Music42/v4/b1/c0/76/b1c076ed-e555-af3b-3f09-5dfc379da0cb/source/60x60bb.jpg",
      "artworkUrl100": "https://is1-ssl.mzstatic.com/image/thumb/Music42/v4/b1/c0/76/b1c076ed-e555-af3b-3f09-5dfc379da0cb/source/100x100bb.jpg",
      "collectionPrice": 0,
      "trackPrice": 0,
      "trackRentalPrice": 0,
      "collectionHdPrice": 0,
      "trackHdPrice": 0,
      "trackHdRentalPrice": 0,
      "releaseDate": "2019-01-23T22:03:00Z",
      "collectionExplicitness": "cleaned",
      "trackExplicitness": "cleaned",
      "trackCount": 25,
      "country": "USA",
      "currency": "USD",
      "primaryGenreName": "Professional",
      "contentAdvisoryRating": "Clean",
      "artworkUrl600": "https://is1-ssl.mzstatic.com/image/thumb/Music42/v4/b1/c0/76/b1c076ed-e555-af3b-3f09-5dfc379da0cb/source/600x600bb.jpg",
      "genreIds": [
        "1465",
        "26",
        "1316"
      ],
      "genres": [
        "Professional",
        "Podcasts",
        "Sports & Recreation"
      ]
    }
  ]
}

According to this answer by juhariis, you'll need to hit the feedURL (in this case, "http://feeds.feedburner.com/TheWestHamWayOnPhoenixFm") in the result to get access to the actual episodes.

There are probably language or framework-specific packages you to help you out with this.

I hope this helps!

Old Answer

Are you sure your search URL doesn't look like this: https://itunes.apple.com/search?term=firstname+lastname&limit=1?

According to the iTunes Web Service Search API documentation, the limit parameter isn't required in the request URL, so you can simply remove the "&limit=1" part of the query string:

To search for all Jack Johnson audio and video content (movies, podcasts, music, music videos, audiobooks, short films, and tv shows), your URL would look like the following: https://itunes.apple.com/search?term=jack+johnson

Upvotes: 3

Related Questions