您的重定向URI应该是:“ IG” +“您的客户端” +“://授权”
我正在构建具有Instagram集成的iOS应用程序。重定向URL应该包含什么?
题
我想它应该是一个index.php文件,但是我找不到要实现的代码...我想做的是在WebView中打开Instagram登录页面,因此我可以接收访问令牌。
#define scope @"basic+likes+comments+relationships"
#define callbackURL @"http://test.com"
#define clientID @"c32e8dcf2482xxxxx"
#define clientSecret @"a9dxxxxxxxxx"
NSURL *url = [[NSURL alloc]initWithString:[NSString stringWithFormat:@"https://api.instagram.com/oauth/authorize/?client_id=%@&display=touch&scope=%@&redirect_uri=%@&response_type=code",clientID,scope,callbackURL]];
NSURLRequest *req = [[NSURLRequest alloc]initWithURL:url];
[webView loadRequest:req];
谢谢
解决方案
不隶属于 StackOverflow