使用苹果的搜索API按流派来搜索? [英] Use the Apple Search API to search by genre?
问题描述
是否可以使用Apple搜索API按流派来搜索?我想在App Store专门的游戏。使用的OBJ-C。
正如已经指出在这个问题的评论...
<一个href=\"http://stackoverflow.com/questions/13833521/search-apple-app-store-by-genre-with-ios-obj-c/13877257#13877257\">Search Apple App Store的体裁的iOS /对象 -
有似乎是试图通过流派来搜索一个问题,所以我在寻找答案,其中实际工作,不只是链接到的文档。这样的例子
它实际上不是记录在Search API文档,但你可以在 genreId
参数添加到搜索URL,它限制搜索到一个特定的流派。
如果你看一下JSON从为Yelp的搜索,有4个有趣的事情:
genreIds:6005,6001]
流派:社交网络,天气]
primaryGenreName:社交网络
primaryGenreId:6005
添加&安培; genreId = 6001
来一个网址会发现,在天气类别在美国的应用程序。我使用的URL搜索词检查。
由于它没有记录,你不能依靠它永远工作。您还可以使用 primaryGenreName
作为参数,我没有尝试。你必须弄清楚什么编号对应哪些类别了。
Is it possible to use the Apple Search API to search by genre ? I'm thinking specifically games in the app store. Using Obj-c.
As has been pointed out in the comments of this question...
Search Apple App store by genre with iOS/Obj-c
There seems to be a problem with trying to search by genre, so I'm looking for answers which of examples of that actually working, not just links to the docs.
It's not actually documented on the Search API documentation, but you can add a genreId
parameter to the search URL and it restricts the search to a particular genre.
If you look at the JSON returned from a search for "Yelp", there are 4 interesting things:
"genreIds":["6005", "6001"]
"genres":["Social Networking", "Weather"]
"primaryGenreName":"Social Networking"
"primaryGenreId":6005
Adding &genreId=6001
to a URL will find apps in the US in the "Weather" category. I'm using the search term "Check" in the URL.
https://itunes.apple.com/search?term=Check&country=us&entity=software&genreId=6001
Because it's not documented, you can't rely on it working forever. You may also be able to use the primaryGenreName
as a parameter, I didn't try that. You'll have to figure out what numbers correspond to what categories too.
这篇关于使用苹果的搜索API按流派来搜索?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!