ios - iTunes 搜索 api 从结果中获取所有曲目
问题描述
我正在使用 iTunes api 进行非常简单的搜索以尝试检索某个用户的播客列表,结果仅显示 1 但曲目列表为 25。有没有办法查看所有“曲目”?
解决方案
我能够使用您下面评论中的 URL 重现以下结果:
{
"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"
]
}
]
}
根据juhariis 的这个答案,您需要在结果中点击feedURL
(在本例中为“ http://feeds.feedburner.com/TheWestHamWayOnPhoenixFm ”)才能访问实际剧集。
可能有特定于语言或框架的包可以帮助您解决这个问题。
我希望这有帮助!
旧答案
您确定您的搜索 URL 看起来不像这样:https://itunes.apple.com/search?term=firstname+lastname&limit=1
?
根据iTunes Web Service Search API 文档,请求 URL 中不需要限制参数,因此您可以简单地删除查询字符串的“&limit=1”部分:
要搜索所有 Jack Johnson 音频和视频内容(电影、播客、音乐、音乐视频、有声读物、短片和电视节目),您的 URL 应如下所示: https://itunes.apple.com/search?术语=杰克+约翰逊
推荐阅读
- javascript - 给定 X 次掷骰子输入,生成特定数字
- python - 从 mongo 获取数据时对函数应用限制
- wordpress - 如何在 BBPRESS 论坛页面上添加分页?
- javascript - 当 Ruby on Rails 中的 date_select 值更改时调用 javascript
- angular - Angular 7 和 Angular Material 表在为每一行生成下拉列表表单控件时出现数据源错误
- angular - 在功能模块中使用redux store
- angular - 将组件动态添加到导入库的子路由
- unit-testing - 对需要从 dynamodb 查询的节点 js 进行 mocha 和 chai 单元测试
- sapui5 - SAPUI5 获取日历子元素并添加样式类
- reactjs - 在 antd Form + ReactJs 中使用 antd Tooltip