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` を設定します
既存のアドオンのクレジット上限を消去するには 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 またはユーザーのメールアドレス
- レート制限を超過