BerriAI/litellm · error · HTTPException

Call not allowed. User not proxy admin OR team admin. route=

Error message

Call not allowed. User not proxy admin OR team admin. route={}, team_id={}

What it means

Error "Call not allowed. User not proxy admin OR team admin. route={}, team_id={}" thrown in BerriAI/litellm.

Source

Thrown at litellm/proxy/management_endpoints/team_endpoints.py:2502

    Standard users can self-join an *available team*, but the bypass
    must not be allowed to escalate them to ``role=admin`` or to add
    other users into the team.  When access is granted via the
    available-team bypass we therefore enforce that every member in
    the request matches the caller's own ``user_id`` and is being
    added with ``role="user"``.
    """
    if getattr(user_api_key_dict, "user_role", None) == LitellmUserRoles.PROXY_ADMIN.value:
        return
    if _is_user_team_admin(user_api_key_dict=user_api_key_dict, team_obj=complete_team_data):
        return
    if await _is_user_org_admin_for_team(user_api_key_dict=user_api_key_dict, team_obj=complete_team_data):
        return

    if not _is_available_team(
        team_id=complete_team_data.team_id,
        user_api_key_dict=user_api_key_dict,
    ):
        raise HTTPException(
            status_code=403,
            detail={
                "error": "Call not allowed. User not proxy admin OR team admin. route={}, team_id={}".format(
                    "/team/member_add",
                    complete_team_data.team_id,
                )
            },
        )

    # Available-team self-join grants only the ability to join; per-member
    # budget and model controls stay admin-only.  Reject them here so a
    # self-joining non-admin cannot set their own cap, reset window, or model
    # scope via the bypass.
    if data.max_budget_in_team is not None or data.budget_duration is not None or data.allowed_models is not None:
        raise HTTPException(
            status_code=403,
            detail={
                "error": (

View on GitHub (pinned to 77b7c6c40c)

Solutions

  1. Call this route with a proxy admin key or a team admin key for the given team_id.

When it happens

Trigger: Thrown at litellm/proxy/management_endpoints/team_endpoints.py:2502 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/6b4bf9c8bef15907. Report an issue: GitHub.