anthropic: Classify exhausted credits as payment required (#63988)

Anthropic reports exhausted credits as `invalid_request_error` rather
than the documented `billing_error`. Recognize the specific
credit-balance message when converting Anthropic API errors to
`PaymentRequired`.

This preserves the original status, code, and message, handles errors
with or without an HTTP status, and leaves other invalid requests
unchanged. The comment links to Anthropic's error documentation.

Closes DELTA-77

Validation: the existing Anthropic billing-error test and package
formatting check pass. A temporary classification test also passed for
exhausted credits and malformed requests, with and without HTTP status;
it is not included in this PR.

Release Notes:

- Fixed Anthropic credit exhaustion being classified as a malformed
request instead of a payment issue.
7e0b34bad6Conrad Irwin committed on 9/10/2026, 2:33:24 PM· committed by GitHubparent595d628
1 file changedLine totals unavailable