A simple question about the gitter redirect URL
erguotou520 opened this issue · comments
When create a new app in gitter, what the value of Redirect URL
should be in native development? It shouldn't be started with http(s)
.
Hey @erguotou520, sorry for the delay.
Redirect URL
is the URL on which gitter will redirect you after success authorization with the callback, so if I remember correctly from gitter's API chat it should starts with http(s).
I know the authorization flow, but my doubt is that we should redirect to our native app page but not web page. So I was confused about how to redirect to the native page.
@Erguotou I see. Ok. You have to google about deep linking.
tl;dr:
You can specify the URL for your app like myawesome://app
.
When you open this URL in web-view (browser, web-view in your app), OS will ask you which app you want to use to open this link.
You can also pass some params to request like myawesome://app?param1=1¶m2=2
.
And then you need to use Linking module to catch opening via the link.
Hope this helped you.
Could you show me your redirect url
?
@erguotou520 I don't use it because of the bug in Gitter OAuth flow (I can't login via web-view way for some reasons).
What platform do you use? Android? If so, you need to specify your deep linking schemes in the manifest file. Details: https://developer.android.com/training/app-indexing/deep-linking.html
I disconnected the network connection and found your login page redirect to a web page and your redirect_uri
in the url is not shown in API doc. I was so confused about your way to realize the login logic.
By the way, client_id
is the name when gitter app creation?
Oh, I'm sorry, my gitter app is not your's. It seems like the official.