Skip to content

RateLimitError

Base classes

Name Children Inherits
APIError
clawd_code_sdk._errors
Base exception for Anthropic API errors.

⋔ Inheritance diagram

graph TD
  2380621038["_errors.RateLimitError"]
  3485684694["_errors.APIError"]
  2055642102["_errors.ClaudeSDKError"]
  1615621424["builtins.Exception"]
  3224121899["builtins.BaseException"]
  2751680898["builtins.object"]
  3485684694 --> 2380621038
  2055642102 --> 3485684694
  1615621424 --> 2055642102
  3224121899 --> 1615621424
  2751680898 --> 3224121899

🛈 DocStrings

Bases: APIError

Raised when API rate limits are exceeded (429).

Applications should implement retry logic with exponential backoff when handling this exception.

Source code in src/clawd_code_sdk/_errors.py
class RateLimitError(APIError):
    """Raised when API rate limits are exceeded (429).

    Applications should implement retry logic with exponential backoff
    when handling this exception.
    """

    def __init__(self, message: str, model: Model | None = None) -> None:
        super().__init__(message, "rate_limit", model)

:fa-brands-github: Show source on GitHub