# OpenAI and Anthropic add spending limit features to their SDKs

Digest AI · Agents & Tools · published 2026-10-17T00:49:00Z

Canonical: https://digestai.news/story/openai-and-anthropic-add-spending-limit-features-to-their-sdks

## Summary

OpenAI released a new **SpendControl** type in the *openai‑python* SDK version **v3.30.0** on **October 14 2026**. The type lets developers set a per‑session spending cap expressed in USD cents, with a minimum of 1 and a maximum of 4,503,599,627,370,495 cents. The default is unlimited, and removing the limit does not reset the amount already recorded.

Anthropic introduced a read‑only **BetaSpendLimitUsageTierScope** in *anthropic‑sdk‑python* version **v1.15.0** on **October 15 2026**. It reports the monthly spend cap that the organization’s usage tier or a manually raised cap provides, expressed as a decimal string of cents (e.g., "50000" for $500). Only Claude Enterprise organizations can write limits; Console users can only read them.

Both SDKs note that the limits are **best‑effort** or informational and do not guarantee that a session will stop when the cap is hit. Developers are advised to treat the values as guidelines and implement their own monitoring if they need hard stop behavior.

## Key points

- OpenAI added SpendControl to openai‑python v3.30.0 (Oct 14 2026) for per‑session USD‑cent limits
- Anthropic added read‑only BetaSpendLimitUsageTierScope to anthropic‑sdk‑python v1.15.0 (Oct 15 2026) exposing monthly caps
- Neither SDK guarantees a session will stop when the configured limit is reached

## Why it matters

Spending limits give developers a tool to curb unexpected AI agent costs, but the lack of guaranteed enforcement means teams must add their own safeguards to avoid budget overruns.

## Sources

1. [Limits to stop AI overspending were added to OpenAI and Claude SDKs in the same week](https://note.com/ai_arai_ally/n/neb17bb67bf77?hl=en) (note.com, 2026-10-17)

## Cite

Digest AI, "OpenAI and Anthropic add spending limit features to their SDKs", 17 October 2026, https://digestai.news/story/openai-and-anthropic-add-spending-limit-features-to-their-sdks

---

Written by Digest AI's editorial model from the linked sources; the sources are the record. Headlines, digests and key points are written by Digest AI and may be quoted with a link to the story page. Linked articles belong to their publishers. Terms: https://digestai.news/terms#reuse
JSON: https://digestai.news/story/openai-and-anthropic-add-spending-limit-features-to-their-sdks.json
