BerriAI/litellm · error · HTTPException
You do not have org_admin access to the requested organizati
Error message
You do not have org_admin access to the requested organization(s).
What it means
Error "You do not have org_admin access to the requested organization(s)." thrown in BerriAI/litellm.
Source
Thrown at litellm/proxy/management_endpoints/internal_user_endpoints.py:2001
)
allowed_org_ids = [
m.organization_id
for m in (caller_user.organization_memberships or [])
if m.user_role == LitellmUserRoles.ORG_ADMIN.value
]
if not allowed_org_ids:
raise HTTPException(
status_code=403,
detail={"error": "Only proxy admins and organization admins can list users."},
)
# If client also sent organization_ids, intersect with allowed orgs
if organization_ids:
requested: Final = set(oid.strip() for oid in organization_ids.split(",") if oid.strip())
intersection: Final = list(requested & set(allowed_org_ids))
if not intersection:
raise HTTPException(
status_code=403,
detail={"error": "You do not have org_admin access to the requested organization(s)."},
)
allowed_org_ids = intersection
return ",".join(allowed_org_ids)
@router.get(
"/user/list",
tags=["Internal User management"],
dependencies=[Depends(user_api_key_auth)],
response_model=UserListResponse,
)
async def get_users(
role: str | None = fastapi.Query(default=None, description="Filter users by role"),
user_ids: str | None = fastapi.Query(default=None, description="Get list of users by user_ids"),
sso_user_ids: str | None = fastapi.Query(default=None, description="Get list of users by sso_user_id"),View on GitHub (pinned to 77b7c6c40c)
Solutions
- Request org_admin access to the organization(s) from your proxy admin.
- Query only organizations for which your key has org_admin rights.
When it happens
Trigger: Thrown at litellm/proxy/management_endpoints/internal_user_endpoints.py:2001 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of BerriAI/litellm@77b7c6c40c (2026-08-18).
Data as JSON: /api/errors/aa5371573e6fd2dc.
Report an issue: GitHub.