/api/orgs/{org_id}/spend/builds/{build_id}/export完了したビルドをCSVでエクスポート
ビルドのクエリに対する、POST /spend/exportと同じCSV形式です。APIキーにはプロビジョニング権限が必要です。
認証: AuthorizationヘッダーにBearer形式のAPIキー
パスパラメーター
org_idstring必須お客様の組織ID(uuid)。
GET /api/whoamiで取得できます。build_idstring必須POST /spend/buildsが返したビルドID。
レスポンス
200グループ化された完全なCSV(リクエスト単位の行ではありません)。小数点以下9桁の正確なドル列、受け付けたクエリ、カットオフ、指標の定義を含みます。
spend.csvという添付ファイルとしてCache-Control: private, no-storeで返されます。401APIキーがない、不明、または失効しています。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
403キーがプロビジョニングキーではない(推論キーは読み取りを含むすべての支出エンドポイントで拒否されます)か、顧客プランキーです。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
404不明なハンドルか、組織がキー自身の組織ではありません。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
409ビルドはまだ完了していません。
GET /builds/{build_id}をポーリングしてください。レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
410ビルドの有効期限が切れました(発行から24時間)。更新してください。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
422ボディがスキーマ検証に失敗した、またはエクスポートが10,000グループか16MiBを超えました。
503レポート機能が利用できない、初期化中、または上限付きの読み取りがタイムアウトしました。データが空という意味ではありません。再試行するか範囲を狭めてください。
レスポンス
errorstring必須人が読めるメッセージ。
codestringエンドポイントが定義している場合の、安定した機械可読の理由(例:
pro_required)。actionstringエンドポイントが定義している場合の、安定した対処アクション。
detailsobject呼び出し元が対処するために必要な、顧客に提示して安全な文字列情報(推奨される識別子など)。
リクエスト
curl 'https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/spend/builds/8d2f1c6a-3e4b-4a7d-b9e0-5c1f2a7d8e30/export' \
-H "Authorization: Bearer <YOUR_API_KEY>"レスポンス
"group","label","basis","count","rejected_count","errors","input_tokens","output_tokens","cached_input_tokens","reasoning_tokens","spend_usd","paid_usd","byok_estimated_usd","free_list_value_usd","unknown_usage_count","from","to_exclusive","time_zone","as_of","query","row_kind","group_by","tag_key","projected_through","count_definition","errors_definition","rejected_count_definition","prompt_group_definition","spend_definition"
"gpt-6-luna","gpt-6-luna","requests","11030","20","101","61200000","5102000","38100000","1840000","29.880000000","29.880000000","0.000000000","0.000000000","0","2026-11-01T00:00:00+00:00","2026-11-08T00:00:00+00:00","UTC","2026-11-19T14:02:11.418000+00:00","{...}","aggregate_group","model","","2026-11-08T00:00:00+00:00","Settled customer requests; not a successful-completion count","Non-completed requests: status != completed; rejections are included","Subset with zero attempts and status failed or expired_before_dispatch; cancellations are not rejections","SHA-256 of system/developer content and tool declarations; not full payload, request or session; label shows 12 characters","paid_usd + byok_estimated_usd + free_list_value_usd; only paid_usd is charged credits; excludes pending holds"
https://api.experientiallabs.ai/api/orgs/3f6c2a1e-8b7d-4c2a-9e51-6a0d4b2f7c10/spend/builds/8d2f1c6a-3e4b-4a7d-b9e0-5c1f2a7d8e30/export