Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to utilize OAuth authentication with custom react frontend due to internal URL #911

Open
mikkelgthang opened this issue Apr 15, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@mikkelgthang
Copy link

When using @cl.oauth_callback as described in the docs, CHAINLIT_URL can be set to define the backend's URL - which works as expected. However, the RedirectResponse defined in oauth_callback simply calls url=f"/login?{params}", which means that the callback url wrongly uses the CHAINLIT_URL, and not the frontend's URL that made the request. I can see that it includes a FIXME comment, but in case other matters are more pressing, is there potentially any way to overwrite the implementation? I tried to define the same endpoint in my app.py file, but it still uses the internal function. Currently, I have no way of returning the token to my custom frontend url detached from CHAINLIT_URL. 😃

Thank you in advance 👏

@mikkelgthang mikkelgthang added the bug Something isn't working label Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Development

No branches or pull requests

1 participant