Spaces:
Sleeping
Sleeping
| class SecurityError(Exception): | |
| """Base class for deliberately generic authentication failures.""" | |
| class UnauthorizedError(SecurityError): | |
| pass | |
| class ForbiddenError(SecurityError): | |
| pass | |
| class RateLimitError(SecurityError): | |
| def __init__(self, retry_after: int) -> None: | |
| super().__init__("Rate limit exceeded") | |
| self.retry_after = max(1, retry_after) | |
| class APIKeyNotFoundError(SecurityError): | |
| pass | |
| class APIKeyConflictError(SecurityError): | |
| pass | |