mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 03:04:13 +00:00
docs oauh 2.0 enterprise feature
This commit is contained in:
parent
0d41e2972b
commit
ac833f415d
3 changed files with 22 additions and 0 deletions
|
@ -21,6 +21,14 @@ async def check_oauth2_token(token: str) -> UserAPIKeyAuth:
|
|||
|
||||
from litellm._logging import verbose_proxy_logger
|
||||
from litellm.llms.custom_httpx.http_handler import _get_async_httpx_client
|
||||
from litellm.proxy._types import CommonProxyErrors
|
||||
from litellm.proxy.proxy_server import premium_user
|
||||
|
||||
if premium_user is not True:
|
||||
raise ValueError(
|
||||
"Oauth2 token validation is only available for premium users"
|
||||
+ CommonProxyErrors.not_premium_user.value
|
||||
)
|
||||
|
||||
verbose_proxy_logger.debug("Oauth2 token validation for token=%s", token)
|
||||
# Get the token info endpoint from environment variable
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue