add-team
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAdd Team
创建团队
Create a new team on a live LiteLLM proxy.
在运行中的LiteLLM代理上创建新团队。
Setup
准备工作
Ask for these if not already known:
LITELLM_BASE_URL — e.g. https://my-proxy.example.com
LITELLM_API_KEY — proxy admin keyAPI reference: https://litellm.vercel.app/docs/proxy/team_based_routing
如果尚未知晓以下信息,请向用户询问:
LITELLM_BASE_URL — 示例:https://my-proxy.example.com
LITELLM_API_KEY — 代理管理员密钥Ask the user
向用户询问的信息
- Team name (required, becomes )
team_alias - Max budget (optional, e.g. )
100.00 - Allowed models (optional, e.g. ) — leave empty to allow all
gpt-4o, gpt-4o-mini - TPM / RPM limits (optional)
- 团队名称(必填,将作为)
team_alias - 最高预算(可选,例如)
100.00 - 允许使用的模型(可选,例如)——留空则允许所有模型
gpt-4o, gpt-4o-mini - TPM / RPM限制(可选)
Run
执行步骤
bash
BASE="$LITELLM_BASE_URL"
KEY="$LITELLM_API_KEY"
curl -s -X POST "$BASE/team/new" \
-H "Authorization: Bearer $KEY" \
-H "Content-Type: application/json" \
-d '{
"team_alias": "<name>",
"max_budget": <budget_or_null>,
"models": [<models_or_empty>],
"tpm_limit": <tpm_or_null>,
"rpm_limit": <rpm_or_null>
}'bash
BASE="$LITELLM_BASE_URL"
KEY="$LITELLM_API_KEY"
curl -s -X POST "$BASE/team/new" \
-H "Authorization: Bearer $KEY" \
-H "Content-Type: application/json" \
-d '{
"team_alias": "<name>",
"max_budget": <budget_or_null>,
"models": [<models_or_empty>],
"tpm_limit": <tpm_or_null>,
"rpm_limit": <rpm_or_null>
}'Verify
验证
Confirm the team was created:
bash
curl -s "$BASE/team/info?team_id=<team_id>" \
-H "Authorization: Bearer $KEY"确认团队已创建:
bash
curl -s "$BASE/team/info?team_id=<team_id>" \
-H "Authorization: Bearer $KEY"Output
输出内容
Show the user:
- — they'll need this to generate keys for the team
team_id - ,
team_alias,max_budgetmodels
On error:
- 401 — check that is a valid admin key
LITELLM_API_KEY - 400 — check required fields (team_alias is required)
- Other errors — show and the likely fix
detail
向用户展示:
- — 用户需要此ID来为团队生成密钥
team_id - ,
team_alias,max_budgetmodels
出现错误时:
- 401 — 检查是否为有效的管理员密钥
LITELLM_API_KEY - 400 — 检查必填字段(team_alias为必填项)
- 其他错误 — 展示字段内容及可能的修复方案
detail