Get Spend Capture Rate
Compare the spend LiteLLM captured for a provider against that provider's own bill, per UTC day.
Admin only. Reads the provider's billing API with the billing credential set on the proxy (OpenAI: OPENAI_ADMIN_KEY) and sums LiteLLM_DailyUserSpend for the same days.
Example:
curl -H "Authorization: Bearer $LITELLM_MASTER_KEY" "http://localhost:4000/spend/capture_rate?provider=openai&start_date=2026-09-17&end_date=2026-09-23"
Request
- Base URL: https://docs.litellm.com.cn (the document declares no server; this is the origin it was published from)
- URL: https://docs.litellm.com.cn/spend/capture_rate
- Auth: API key in header x-litellm-api-key
Query parameters
First UTC day of the range, YYYY-MM-DD
Last UTC day of the range, YYYY-MM-DD, inclusive
Provider whose bill to compare against; needs OPENAI_ADMIN_KEY set on the proxy
Ratio under which the report flags below_threshold
Scope the OpenAI bill to these project ids; omit to compare against the whole organization. Captured spend is never scoped, so pass every project LiteLLM's OpenAI keys belong to
Response
Successful Response
Changes
No recorded changes to this operation across all 1 revision of this API.