OGeek|极客世界-中国程序员成长平台

标题: iOS ShareKit 在 YouTube 上共享视频时出现错误 invalid_client [打印本页]

作者: 菜鸟教程小白    时间: 2022-12-12 18:33
标题: iOS ShareKit 在 YouTube 上共享视频时出现错误 invalid_client

我们正在使用 ShareKit对于 youtube 上的视频共享,代码运行良好,但现在出现错误

<__35-[SHKYouTube authorizationFormShow]_block_invoke SHKYouTube.m148)> YouTube authentication finished with error:Error Domain=com.google.HTTPStatus Code=401 "The operation couldn’t be completed. (com.google.HTTPStatus error 401.)" UserInfo=0x19452960 {data=<7b0a2020 22657272 6f722220 3a202269 6e76616c 69645f63 6c69656e 74220a7d>, json={
error = "invalid_client";
 }}

我从 GoogleConsole 创建了新的测试 key 但仍然出现此错误。

enter image description here

使用如下代码:

enter image description here



Best Answer-推荐答案


已发布 #fixed,实际上是 API key 错误。我在 Google 开发者控制台上发现了一个奇怪的问题,当我创建应用类型 iOS 时,它给了我错误,但是当我使用 Others 类型创建应用时,键工作正常。

screen shot 2016-02-26 at 9 24 19 pm

步骤 - 创建凭据 -then- oAuth 客户端 ID -then- 其他 enter image description here enter image description here

关于iOS ShareKit 在 YouTube 上共享视频时出现错误 invalid_client,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35412637/






欢迎光临 OGeek|极客世界-中国程序员成长平台 (http://sqlite.in/) Powered by Discuz! X3.4