mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 03:04:13 +00:00
fix(proxy_server.py): check if team scope in jwt
This commit is contained in:
parent
4d7f4550e2
commit
d90f44fe8e
2 changed files with 11 additions and 0 deletions
|
@ -85,6 +85,11 @@ class JWTHandler:
|
|||
return True
|
||||
return False
|
||||
|
||||
def is_team(self, scopes: list) -> bool:
|
||||
if self.litellm_proxy_roles.team_jwt_scope in scopes:
|
||||
return True
|
||||
return False
|
||||
|
||||
def get_end_user_id(self, token: dict, default_value: Optional[str]) -> str:
|
||||
try:
|
||||
if self.litellm_proxy_roles.team_id_jwt_field is not None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue