Bik*_*ire 16 ruby-on-rails oauth-2.0 omniauth instagram
我正在开发一个处于开发模式的Rails应用程序,它可以注册omniauth.
主持人是
http://localhost:3000/
Run Code Online (Sandbox Code Playgroud)
我正在使用宝石:
gem 'omniauth'
gem 'omniauth-foursquare'
gem 'omniauth-instagram'
Run Code Online (Sandbox Code Playgroud)
当我通过Foursquare注册omniauth时,根本没有问题.所有设置都是正确的,我在Foursquare开发人员设置中的redirect_uri等于主机(localhost:3000)
但是,如果我在Instagram客户端管理器*中填写完全相同的redirect_uri(localhost:3000).Instagram给了我这个:
{
"code": 400,
"error_type": "OAuthException",
"error_message": "Redirect URI does not match registered redirect URI"
}
Run Code Online (Sandbox Code Playgroud)
基于此URL:
https://instagram.com/oauth/authorize?response_type=code&client_id=<ID>&redirect_uri=http%3A%2F%2Flocalhost%3A3000%2Fauth%2Finstagram%2Fcallback&state=18415adf24dd97873e61094f67c0fb7a94857fedf93e9d2e&scope=basic
Run Code Online (Sandbox Code Playgroud)
*

根据Instagram,我做错了什么,应该如何解决?
小智 8
我需要补充一下
http://localhost:3000/users/auth/instagram/callback
Run Code Online (Sandbox Code Playgroud)
作为我的回调URI,因为我正在使用Devise.
| 归档时间: |
|
| 查看次数: |
59162 次 |
| 最近记录: |