Skip to content

Commit d5e0dc0

Browse files
gjtorikianclaude
andcommitted
feat: regenerate SDK with PEP 8 error naming and design fixes
Regenerated from oagen-emitters with: - Error classes renamed *Exception → *Error (PEP 8) - Two-tier error hierarchy: WorkOSError → APIError → specific errors - Client class WorkOS is canonical (was WorkOSClient) - Typed ListMetadata dataclass replaces Dict[str, Any] - _parse_datetime helper with Python 3.10 version gating - Clean __init__.py exports (only core public API) - Remove exceptions.py compat re-export module - Remove all backwards-compat aliases (greenfield project) - Update hand-written tests to use canonical *Error names Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent c5c613e commit d5e0dc0

File tree

272 files changed

+18059
-3245
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

272 files changed

+18059
-3245
lines changed

src/workos/__init__.py

Lines changed: 7 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,45 +2,17 @@
22

33
"""WorkOS Python SDK."""
44

5-
from ._client import AsyncWorkOSClient, WorkOSClient
6-
from ._errors import (
7-
BaseRequestException,
8-
AuthenticationException,
9-
BadRequestException,
10-
ConflictException,
11-
ConfigurationException,
12-
AuthorizationException,
13-
NotFoundException,
14-
RateLimitExceededException,
15-
ServerException,
16-
UnprocessableEntityException,
17-
WorkOSConnectionException,
18-
WorkOSTimeoutException,
19-
)
20-
from ._pagination import AsyncPage, SyncPage
5+
from ._client import AsyncWorkOS, WorkOS
6+
from ._errors import WorkOSError
7+
from ._pagination import AsyncPage, ListMetadata, SyncPage
218
from ._types import RequestOptions
229

23-
WorkOS = WorkOSClient
24-
AsyncWorkOS = AsyncWorkOSClient
25-
2610
__all__ = [
27-
"WorkOSClient",
28-
"AsyncWorkOSClient",
2911
"WorkOS",
3012
"AsyncWorkOS",
31-
"RequestOptions",
32-
"BaseRequestException",
33-
"AuthenticationException",
34-
"BadRequestException",
35-
"ConflictException",
36-
"ConfigurationException",
37-
"AuthorizationException",
38-
"NotFoundException",
39-
"RateLimitExceededException",
40-
"ServerException",
41-
"UnprocessableEntityException",
42-
"WorkOSConnectionException",
43-
"WorkOSTimeoutException",
44-
"AsyncPage",
13+
"WorkOSError",
4514
"SyncPage",
15+
"AsyncPage",
16+
"ListMetadata",
17+
"RequestOptions",
4618
]

0 commit comments

Comments
 (0)