Documentation Index
Fetch the complete documentation index at: https://docs.windsurf.com/llms.txt
Use this file to discover all available pages before exploring further.
組織に対して、アドオンクレジットのユーザーごとの利用上限を設定したり、解除したりできます。上限は常にユーザー単位で適用されます。チームまたはグループのスコープを指定した場合、そのチームまたはグループ内の各ユーザーに個別の上限が適用されます。チーム全体やグループ全体で共有の上限が設定されるわけではありません。
「Billing Write」権限を持つサービスキー
既存のアドオン用クレジット上限をクリアするには true を設定します
新しいアドオン用クレジット上限(整数値)を設定します
clear_add_on_credit_cap または set_add_on_credit_cap のいずれか一方を必ず指定し、両方を同時に指定しないでください。
チーム内のすべてのユーザーにユーザー単位の上限を適用するには true を指定します
対象のグループ ID を指定して、そのグループ内のすべてのユーザーにユーザー単位の上限を適用します
対象ユーザーのメールアドレスを指定して、そのユーザーに適用します
スコープを定義するには、team_level、group_id、または user_email のいずれかを必ず指定してください。
リクエスト例 - チーム内の全ユーザー向けのユーザー別クレジット上限を設定する
curl -X POST --header "Content-Type: application/json" \
--data '{
"service_key": "your_service_key_here",
"set_add_on_credit_cap": 10000,
"team_level": true
}' \
https://server.codeium.com/api/v1/UsageConfig
リクエスト例 - グループ内の全ユーザーにユーザーごとのクレジット上限を設定する
curl -X POST --header "Content-Type: application/json" \
--data '{
"service_key": "your_service_key_here",
"set_add_on_credit_cap": 5000,
"group_id": "engineering_team"
}' \
https://server.codeium.com/api/v1/UsageConfig
リクエスト例 - ユーザーのクレジット上限を設定する
curl -X POST --header "Content-Type: application/json" \
--data '{
"service_key": "your_service_key_here",
"set_add_on_credit_cap": 1000,
"user_email": "user@example.com"
}' \
https://server.codeium.com/api/v1/UsageConfig
curl -X POST --header "Content-Type: application/json" \
--data '{
"service_key": "your_service_key_here",
"clear_add_on_credit_cap": true,
"team_level": true
}' \
https://server.codeium.com/api/v1/UsageConfig
レスポンスボディはありません。200 ステータスコードは、処理が正常に完了したことを示します。
一般的なエラー例:
- 無効なサービスキー、または権限不足
clear_add_on_credit_cap と set_add_on_credit_cap の両方が指定されている
clear_add_on_credit_cap も set_add_on_credit_cap も指定されていない
- scope パラメータが複数指定されている
- scope パラメータが指定されていない
- 無効なグループ ID またはユーザーのメールアドレス
- レート制限を超過