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
Is your feature request related to a problem? Please describe.
Currently, the GithubOAuthProvider in the Chainlit repository only supports the standard GitHub URL for authorization and token retrieval. This limitation prevents users from utilizing custom GitHub instances, which require a different base URL for OAuth operations.
Describe the solution you'd like
I propose extending the GithubOAuthProvider class to support custom GitHub URLs by allowing the URL to be specified as an environment variable, similar to how OAUTH_GITHUB_CLIENT_ID and OAUTH_GITHUB_CLIENT_SECRET are handled. This change would involve modifying the oauth_providers.py file to include a new environment variables, OAUTH_GITHUB_CUSTOM_URL and OAUTH_GITHUB_CUSTOM_API_URL, and updating the authorization and token URLs accordingly.
Here is the code that needs to be changed in oauth_providers.py:
An alternative could be to manually modify the URLs in the code for each custom GitHub instance, but this approach is not scalable or user-friendly.
Additional context
By implementing this change, users will be able to configure the OAuth provider to work with their GitHub instances by setting the OAUTH_GITHUB_CUSTOM_URL and OAUTH_GITHUB_CUSTOM_API_URL environment variables.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Currently, the
GithubOAuthProvider
in the Chainlit repository only supports the standard GitHub URL for authorization and token retrieval. This limitation prevents users from utilizing custom GitHub instances, which require a different base URL for OAuth operations.Describe the solution you'd like
I propose extending the
GithubOAuthProvider
class to support custom GitHub URLs by allowing the URL to be specified as an environment variable, similar to howOAUTH_GITHUB_CLIENT_ID
andOAUTH_GITHUB_CLIENT_SECRET
are handled. This change would involve modifying theoauth_providers.py
file to include a new environment variables,OAUTH_GITHUB_CUSTOM_URL
andOAUTH_GITHUB_CUSTOM_API_URL
, and updating the authorization and token URLs accordingly.Here is the code that needs to be changed in
oauth_providers.py
:Describe alternatives you've considered
An alternative could be to manually modify the URLs in the code for each custom GitHub instance, but this approach is not scalable or user-friendly.
Additional context
By implementing this change, users will be able to configure the OAuth provider to work with their GitHub instances by setting the
OAUTH_GITHUB_CUSTOM_URL
andOAUTH_GITHUB_CUSTOM_API_URL
environment variables.The text was updated successfully, but these errors were encountered: