BerriAI/litellm · error · HTTPException

Available-team self-join cannot set per-member budget or mod

Error message

Available-team self-join cannot set per-member budget or model controls (max_budget_in_team, budget_duration, allowed_models); these are admin-only.

What it means

Error "Available-team self-join cannot set per-member budget or model controls (max_budget_in_team, budget_duration, allowed_models); these are admin-only." thrown in BerriAI/litellm.

Source

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

        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": (
                    "Available-team self-join cannot set per-member budget or "
                    "model controls (max_budget_in_team, budget_duration, "
                    "allowed_models); these are admin-only."
                )
            },
        )

    # Available-team self-join: caller may add only themselves, only as a
    # standard user.  Enforce that here so the bypass cannot be used as a
    # privilege-escalation or cross-user-injection primitive.
    members: Final = data.member if isinstance(data.member, list) else [data.member]
    caller_user_id: Final = getattr(user_api_key_dict, "user_id", None)
    for member in members:
        if getattr(member, "role", "user") != "user":
            raise HTTPException(

View on GitHub (pinned to 77b7c6c40c)

Solutions

  1. Omit max_budget_in_team, budget_duration, and allowed_models when self-joining; ask a team admin to set them.

When it happens

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