You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello.
In my Angular app I have a login page and some states.
My objective is:
When I go to some state (e.g. /inicio) and I am not logged in, there are a AuthGuard, It redirect to /login state with a param "returnUrl" (https://localhost:4200/login/?returnUrl=/inicio).
Login state try to login with instagram with this url: "https://api.instagram.com/oauth/authorize/?client_id=<myclientid>&scope=public_content&hl=en&response_type=code&redirect_uri=" + window.location.origin + "/login/?returnUrl=" + this.returnUrl;"
It works. But I need a variable returnUrl, becouse I need to redirect to /state/<some_id>
I try with this: REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/?returnUrl' REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/?returnUrl=' REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/' REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login'
but it didn't work, always the same error: Authentication process canceled; ; {'error_type': 'OAuthException', 'code': 400, 'error_message': "Redirect URI doesn't match original redirect URI"}
Some idea?
Thanks.
The text was updated successfully, but these errors were encountered:
@Martin317
You can include the redirect_url param when you are calling backend API. In that case backend will use it in API request. From readme:
At input there is also non-required field redirect_uri. If given, server will use this redirect uri in requests, instead of uri got from settings. This redirect_uri must be equal in front-end request and in back-end request. Back-end will not do any redirect in fact.
Hello.
In my Angular app I have a login page and some states.
My objective is:
When I go to some state (e.g. /inicio) and I am not logged in, there are a AuthGuard, It redirect to /login state with a param "returnUrl"
(https://localhost:4200/login/?returnUrl=/inicio)
.Login state try to login with instagram with this url:
"https://api.instagram.com/oauth/authorize/?client_id=<myclientid>&scope=public_content&hl=en&response_type=code&redirect_uri=" + window.location.origin + "/login/?returnUrl=" + this.returnUrl;"
In this example:
https://api.instagram.com/oauth/authorize/?client_id=<myclientid>&scope=public_content&hl=en&response_type=code&redirect_uri=https://localhost:4200/login/?returnUrl=/inicio
On instagram API I have this url:
https://localhost:4200/login/
On my server I have this:
REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/?returnUrl=/inicio'
It works. But I need a variable returnUrl, becouse I need to redirect to
/state/<some_id>
I try with this:
REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/?returnUrl'
REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/?returnUrl='
REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login/'
REST_SOCIAL_OAUTH_ABSOLUTE_REDIRECT_URI = 'https://localhost:4200/login'
but it didn't work, always the same error:
Authentication process canceled; ; {'error_type': 'OAuthException', 'code': 400, 'error_message': "Redirect URI doesn't match original redirect URI"}
Some idea?
Thanks.
The text was updated successfully, but these errors were encountered: