AI API receipt · BerriAI/litellm
BerriAI/litellm#45586 · upstream bug reproduced by running the issue's own reproduction
Badgr cannot tell this response is wrong
A reply with no usage block, usage: null and an explicit zero all came back as prompt_tokens=0, completion_tokens=0 and completion_cost 0 (reproduced on 1.104.2).
the answer is non-empty and well formed; a missing usage block is indistinguishable from a real zero, so Badgr cannot tell that cost evidence is missing. The receipt therefore records success. This is a limit of what the contract can prove, shown here so it is not mistaken for protection.
The output the bug produces, taken from the issue’s reproduction and fed to Badgr’s validators. Not a live provider call.
text: "Hi there" tool_calls: none
Written by Badgr’s receipt ledger and read back from GET /v1/receipts/replay-litellm-45586-missing-usage-reads-zero.
{
"request_id": "replay-litellm-45586-missing-usage-reads-zero",
"status": "success",
"endpoint": "/v1/chat/completions",
"stream": false,
"failure_stage": null,
"error_code": null,
"error_message": null,
"retryable": null,
"provider_mode": "replay",
"routing_decision": "replayed_upstream_output",
"created_at": "1791679612.9865658"
}Recorded 2026-10-11 in Badgr’s local development environment. Replay cases and verdicts are pinned by backend/test_ai_api_replay_cases.py.
← All AI API receipts