Invalid combination of search filters and/or restrictions for Youtube data api v3 search

旧时模样 提交于 2019-12-11 07:27:35

问题


Getting 400 error while exploring YoutubeData API V3 for search. It accepts parameters like:

part = snippet

location = 12.9667,77.5667

locationRadius = 50km

But it gives me the response below :

400 Bad Request


{
"error": {
 "errors": [
{
 "domain": "youtube.search",
 "reason": "invalidSearchFilter",
 "message": "Invalid combination of search filters and/or restrictions.",
"locationType": "parameter",
"location": ""
}
],
"code": 400,
"message": "Invalid combination of search filters and/or restrictions."
}
}

回答1:


I've faced the same problem. Documentation says

Note that you must set the type parameter to video if you set a value for the eventType, videoCaption, videoCategoryId, videoDefinition, videoDimension, videoDuration, videoEmbeddable, videoLicense, videoSyndicated, or videoType parameters.

Though nothing mentioned about location parameter, adding type = "video" to parameter list has solved my problem.



来源:https://stackoverflow.com/questions/30436458/invalid-combination-of-search-filters-and-or-restrictions-for-youtube-data-api-v

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!