Hello all, I am trying to switch from Github OAuth...
# talk-kratos
d
Hello all, I am trying to switch from Github OAuth App to GitHub app. Though the process is same but I am facing issues with
callbackurl
for Kratos the URL should be of form
/kratos/self-service/methods/oidc/callback/github.
Since with GitHub app we can specify upto 10 callback URLs, when using GitHub as SSO with Kratos, how I can use
redirect_uri
param as mentioned in GitHub docs, to control which callback URL is used.
You can specify up to 10 callback URLs. If you specify multiple callback URLs, you can use the
redirect_uri
parameter when you prompt the user to authorize your GitHub App, to indicate which callback URL the user should be redirected to. If you do not specify
redirect_uri
, the first callback URL will be used. For more information about using the
redirect_uri
parameter, see ā€œGenerating a user access token for a GitHub Appā€.
https://docs.github.com/en/apps/creating-github-apps/registering-a-github-app/about-the-user-authorization-callback-url
@magnificent-energy-493 @swift-chef-97535
m
Hey @dazzling-honey-93005 It should work the same with GitHub OAUth App as with the normal GitHub app šŸ¤” Or do you need multiple callback URLs? What about using the redirect_uri in your frontend like the docs you mention say?
d
My GitHub app has multiple callback URLs, so how can I define which callbackURL to use with Kratos SSO.
The docs mention you can use
redirect_uri
param to distinguish when you redirect user to Github, but this control lies with Kratos. So I was thinking a
redirect_uri
or a similar config option can be added to Kratos config.