/api/orgs/{org_id}/provider-connections/{provider}/plans/{setup_alias}/refresh-usageプランアカウントの使用量を更新
プランのローリング使用量ウィンドウを今すぐ読み取り(期限切れ間近ならログインを更新します)、アカウントに反映します。使い切ったウィンドウはアカウントをquota_exhaustedにし、トラフィックは次のアカウントに切り替わります。Proは不要です。プロバイダーからの読み取りに失敗した場合は502です。
認証: AuthorizationヘッダーにBearer形式のAPIキー
パスパラメーター
org_idstring必須お客様の組織ID(uuid)。
GET /api/whoamiで取得できます。providerenum必須ChatGPTプランは
openai、Claudeプランはanthropic。その他のプロバイダーは404です。setup_aliasstring必須プランアカウントのハンドル。
クエリパラメーター
automaticbooleanライブポーリングです。45秒以内の読み取り値を再利用し、判定が変わった場合のみ監査記録を残します。
レスポンス
200読み取り後のプランアカウント。
レスポンス
setup_aliasstring必須planobject必須プランアカウントがキーの代わりに保持するもの。
plan
labelstring必須plan_typestring | null必須例:plus、pro、team、max。
primaryobject | null必須いずれか
object
used_percentinteger必須reset_atstring | null必須window_minutesinteger | null必須
secondaryobject | null必須いずれか
object
used_percentinteger必須reset_atstring | null必須window_minutesinteger | null必須
derivedobject | nullいずれか
object
five_hourobject | null必須いずれか
object
requestsinteger必須input_tokensinteger必須cached_input_tokensinteger必須output_tokensinteger必須first_activitystring | null必須last_activitystring | null必須
seven_dayobject | null必須いずれか
object
requestsinteger必須input_tokensinteger必須cached_input_tokensinteger必須output_tokensinteger必須first_activitystring | null必須last_activitystring | null必須
checked_atstring | null必須scopeenumorg:共有プール。account:owner_user_idが作成したAPIキーのみ。owner_user_idstring | nullrotation_pausedboolean一時停止中のプランはリクエストを処理しません。
refreshes_atstring | null使い切ったウィンドウにより一時停止したプランが更新される時刻。
statusenum必須プロバイダーが確認したキーの状態で、接続チェックと実際のトラフィックによって書き込まれます。
provider_errorはチェック時にプロバイダーに到達できなかったことを示し、キーが不正であることを意味しません。scopeenum必須owner_user_idstring | null必須rotation_pausedboolean必須
401APIキーがない、不明、または失効しています。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
403キーは有効ですが、この操作は許可されていません(例:プロビジョニングキー用エンドポイントでの推論キー、プラン対象外の機能)。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
404このハンドルのプランアカウントはありません。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
409保存されたログインを読み取れません。再度ログインしてください。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
502プロバイダーの使用量の読み取りまたはトークンの更新に失敗しました。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
リクエスト
curl -X POST 'https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/provider-connections/openai/plans/chatgpt-team/refresh-usage?automatic=false' \
-H "Authorization: Bearer <YOUR_API_KEY>"レスポンス
{
"setup_alias": "chatgpt-team",
"plan": {
"label": "dev@acme.example",
"plan_type": "team",
"primary": {
"used_percent": 12,
"reset_at": "2026-11-19T18:40:00Z",
"window_minutes": 300
},
"secondary": {
"used_percent": 41,
"reset_at": "2026-11-23T09:00:00Z",
"window_minutes": 10080
},
"derived": null,
"checked_at": "2026-11-19T14:21:07.330Z",
"scope": "org",
"owner_user_id": null,
"rotation_paused": false,
"refreshes_at": null
},
"status": "valid",
"scope": "org",
"owner_user_id": null,
"rotation_paused": false
}https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/provider-connections/openai/plans/chatgpt-team/refresh-usage?automatic=false