Instagram API在400次错误的请求错误成功login后阻止redirect到iOS应用

我试图将Instagramlogin集成到我的应用程序中以获取login用户的详细信息,我已经在Instagram上注册了我的应用程序并获得了我的客户ID,然后在项目设置中添加了一个新的URL Type,其标识符为: igxxxx (其中xxxx是我的客户端ID),我也设置redirectURI为( xxxx://authorize ),一旦我成功login(使用web视图),Instagram显示一个白色的空白页面( 400 Bad Request )但是,当我将redirectURI更改为其他任何内容时,在成功login后它将打开而不会出现问题。
如何在Instagram上login后将用户redirect到应用程序。

ps我使用这个库来缓解事情。

提前致谢。

这是我迄今为止发现的。 我已经能够解决这个问题,让应用程序在iPhone上工作。 但是,这种解决scheme不允许我在app store提交应用程序,因为您会提前阅读。 我已经提交了一个错误与instagram,不知道他们将花多长时间。

我build议大家去这个链接和“报告问题”:

https://www.instagram.com/developer/clients/manage/

我已经有一个应用程序商店几个月没有问题。 然而,自从6月19日以来,所有试图进行身份validation的用户在用他们的IG帐户login后,都会收到一个带有“400错误请求”的白页。

这个问题很常见,你会在这个堆栈溢出页面上看到:

Instagram API在400次错误的请求错误成功login后阻止redirect到iOS应用程序

而谷歌自6月19日以来,也向许多用户展示了同样的问题。

我发现我们使用的旧的redirectURI:

 myappname:// 

是问题。

如果我们将此redirectURI更改为:

 http://myappname 

要么

 https://myappname 

这一切开始工作正常,我们得到访问令牌。

但是按照RFC1738,这不是在iOS开发中使用的URLscheme的有效格式。

所以,当我们的应用程序提交到应用程序商店时,

 ERROR ITMS-90158: "The following URL schemes found in your app are not in the correct format: [https: //myappname]. URL schemes need to begin with an alphabetic character, and be comprised of alphanumeric characters, the period, the hyphen or the plus sign only. Please see RFC1738 for more detail." ERROR ITMS-90158: "The following URL schemes found in your app are not in the correct format: [https: //myappname]. URL schemes need to begin with an alphabetic character, and be comprised of alphanumeric characters, the period, the hyphen or the plus sign only. Please see RFC1738 for more detail." 

所以我们不能用这个解决scheme提交给app store。

所以,除非Instagram做了一些事情来解决这个问题,否则我们会卡住:(