Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 77050

Xamarin.Auth for Instagram "riderect URI" problem

$
0
0

I smashed my head over it to make it work with no success:

Using this tutorial as a base.

    new OAuthSettings (
            clientId: "4777d948cd5***********",  // OAuth2 client id 
            scope: "likes",                      // The scopes for the particular API you're accessing. The format for this will vary by API.
            authorizeUrl: "https://instagram.com/oauth/authorize/",     // the auth URL for the service
            redirectUrl: "MyTestApp://auth");  

redirectUrl on instagram is the same: MyTestApp://auth
Url scheme for the app as follows on info.plist:

    <key>CFBundleURLTypes</key>
      <array>
        <dict>
          <key>CFBundleURLSchemes</key>
          <array>
            <string>MyTestApp</string>
          </array>
              <key>CFBundleURLName</key>
              <string>com.myCompany.MyTestApp</string>
            <key> CFBundleURLTypes</key>
            <string>Viewer</string>
        </dict>
      </array>

I also noticed that hitting url from safari :

        https://instagram.com/oauth/authorize/client_id=4777d948**************&redirect_uri=MyTestApp://auth&response_type=token

Opens the app with token returned from instagram via oppened app: override OpenUrl in Delegate!

Am I missing something to make it work within the app?
Any advice ?

Thank you!


Viewing all articles
Browse latest Browse all 77050

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>