Wikipedia as Authorization server (Authsession)


I’m building a RN Android app for . Users can login/signup ONLY with their sign-on credentials. Right now, I’m using the example from Expo’s Authsession and have used my ClientID from OKTA (I have one from Auth0 as well) When ‘registering’ my app at mediawiki . org/wiki/MediaWiki I received a Consumer Token and a Secret Token. I’m not sure what I need to replace the AuthURL in the example code with. Also, not sure what I can do with the Consumer Token and a Secret Token. This is the endpoint FROM WikiEDU that redirects TO Wikipedia: /users/auth/mediawiki. I’ve used a Chrome generated URL in the Expo example and it works where it take me to Wikipedia, but once I authenticate at Wikipedia, I don’t get redirected back to WikiEDU. Any advice what I need to change/create for the redirect / token handling to work?

Here is my code for the button press:

_handlePressAsync = async () => {
let redirectUrl = AuthSession.getRedirectUrl();
let result = await AuthSession.startAsync({
authUrl: +
&client_id=${FB_APP_ID} +
this.setState({ result });

The FB_APP_ID is one generated from OKTA (I’ve tried the one from Auth0 too with no success)

closed #2

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.