-
Notifications
You must be signed in to change notification settings - Fork 182
Comparing changes
Open a pull request
base repository: auth0/auth0-python
base: v4
head repository: auth0/auth0-python
compare: master
- 9 commits
- 2,965 files changed
- 2 contributors
Commits on Jan 27, 2026
-
Merge v5 branch into master – Auth0 Python SDK v5.0.0 (#768)
This pull request merges the `v5` branch into `master`, introducing **version 5.0.0** of the Auth0 Python SDK. This marks a **major, breaking rewrite** of the SDK, fully generated from Auth0's OpenAPI specifications using Fern. The Management API code is now **auto-generated**, featuring a new hierarchical package structure, improved type safety with Pydantic models, and updated usage patterns. The Authentication API remains manually maintained and is **not affected** by these changes. Additionally, documentation, workflows, and contribution guidelines have been updated to align with the new structure. --- ## Major Breaking Changes and Improvements ### SDK Rewrite and Breaking Changes - Complete rewrite of the **Management SDK**, generated from OpenAPI specs using Fern, introducing: - Hierarchical package structure with improved organization - Strongly typed interfaces using Pydantic models - Automatic token management with client credentials - Improved pagination with `SyncPager` and `AsyncPager` - Enhanced error handling with structured exceptions - All Management API usage patterns have changed, including **client initialization** and **method signatures**. Refer to the [v5 Migration Guide](v5_MIGRATION_GUIDE.md) for detailed upgrade steps. - **Package structure** has changed from dictionary-based responses to Pydantic models. All imports and response handling must be updated. - Only the **Authentication API** is manually maintained. Contribution and code generation instructions have been updated accordingly. ### Documentation and Examples - `README.md` and badges updated for v5 - Installation instructions revised; new usage examples provided for both Authentication and Management APIs - Clarified Python version requirement: **Python 3.8+** (Python 3.7 support dropped) - Contribution guidelines updated to reflect the new code generation process and testing instructions ### Build, Linting, and Workflows - CI workflows updated to use the `master` branch (will be finalized in this PR) - v5-specific workflow files (`v5-ci.yml`, `v5-publish.yml`) to be removed or consolidated - Linting configuration adjusted for the new structure - Poetry and dependency management updated ### Changelog - Added detailed changelog entries describing the rewrite, breaking changes, migration steps, and beta release notice --- Please review the [v5 Migration Guide](v5_MIGRATION_GUIDE.md) and updated documentation to transition your codebase to the new SDK structure. --- **Note:** The `v4` branch has been preserved at the pre-v5 state for reference and potential maintenance releases. --------- Signed-off-by: Snehil Kishore <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for f966475 - Browse repository at this point
Copy the full SHA f966475View commit details -
chore: update Fern configuration and fix GitHub templates (#770)
### Changes - Remove .fern/ directory from repository (added to .fernignore) - Update .fernignore to exclude configuration files and .github folder - Remove references to non-existent EXAMPLES.md from issue templates - Ensure all GitHub workflows point to correct branches and documentation
Configuration menu - View commit details
-
Copy full SHA for 81cdca7 - Browse repository at this point
Copy the full SHA 81cdca7View commit details
Commits on Feb 4, 2026
-
🌿 Fern Regeneration -- February 3, 2026 (#772)
This PR regenerates code to match the latest API Definition. Co-authored-by: fern-api[bot] <115122769+fern-api[bot]@users.noreply.github.com>
Configuration menu - View commit details
-
Copy full SHA for 69c1a9e - Browse repository at this point
Copy the full SHA 69c1a9eView commit details -
chore: update telemetry to Auth0 format with dynamic versioning (#773)
## Changes - Replace Fern telemetry headers (X-Fern-*) with Auth0 standard format - Use Auth0-Client header with base64-encoded JSON telemetry - Implement dynamic version reading from package metadata - Add cryptography unknown license exception to .snyk - Add client_wrapper.py to .fernignore to prevent Fern regeneration
Configuration menu - View commit details
-
Copy full SHA for 02ccb63 - Browse repository at this point
Copy the full SHA 02ccb63View commit details -
# Release v5.0.0 🎉 ## Overview This PR prepares the **stable v5.0.0 release** of the Auth0 Python SDK - a complete rewrite with significant improvements and breaking changes from v4.x. ## Changes in this PR - Updated `.version` file from `5.0.0b0` to `5.0.0` - Updated `pyproject.toml` package version to `5.0.0` - Added comprehensive v5.0.0 release notes to `CHANGELOG.md` - Updated `README.md` with v5.0.0 installation instructions ## What's New in v5.0.0 ###
⚠️ BREAKING CHANGES - Major Rewrite This is a complete rewrite of the Auth0 Python SDK with significant breaking changes from v4.x. Users will need to update their code when migrating from v4.x to v5.0.0. ### Added Features - **New Fern-generated SDK**: Complete Management API rewrite generated from Auth0's OpenAPI specifications - **Hierarchical package structure**: Organized Management APIs into logical sub-clients for better discoverability - **Strongly typed interfaces**: Pydantic models provide specific request/response types replacing generic dictionaries - **Automatic token management**: Built-in client credentials handling with automatic token refresh - **Enhanced pagination**: New `SyncPager` and `AsyncPager` classes for easy iteration over paginated results - **First-class async support**: Full async/await support with `AsyncManagementClient` - **Better IDE support**: Improved code completion, type hints, and inline documentation ### Key Breaking Changes - **Import paths** changed from `from auth0.management import Auth0` to `from auth0.management import ManagementClient` - **Client initialization** changed from `Auth0(domain, management_token)` to `ManagementClient(domain, client_id, client_secret)` with automatic token management - **Response types** changed from dictionaries to Pydantic models (use `.model_dump()` to convert back to dict) - **Method organization** changed from flat (`client.users.list()`) to hierarchical where applicable - **Pagination parameters** changed - some endpoints use `per_page`, others use `take` - **Python version** requirement increased from ≥3.7 to ≥3.8 - **Error handling** changed from `Auth0Error` to `ApiError` base class ## Migration Example ### Before (v4): ```python from auth0.management import Auth0 # Initialize with management token mgmt = Auth0( domain='your-tenant.auth0.com', token='YOUR_MGMT_API_TOKEN' ) # List clients - returns list of dicts clients = mgmt.clients.all() for client in clients: print(client['name']) # Dictionary access ``` ### After (v5): ```python from auth0.management import ManagementClient # Initialize with client credentials (automatic token management) client = ManagementClient( domain='your-tenant.auth0.com', client_id='YOUR_CLIENT_ID', client_secret='YOUR_CLIENT_SECRET' ) # List clients - returns SyncPager of Pydantic models clients = client.clients.list(per_page=50) for client_obj in clients: print(client_obj.name) # Pydantic model attribute access # Convert to dict if needed client_dict = client_obj.model_dump() ``` ## Important Notes - ✅ The `authentication` package is **NOT affected** by these changes. Authentication APIs remain the same between v4 and v5. - 📚 Complete migration guide available at [v5_MIGRATION_GUIDE.md](https://github.com/auth0/auth0-python/blob/master/v5_MIGRATION_GUIDE.md) - 🎯 This is the stable GA release following v5.0.0-beta.0 - 🔧 Auth0 telemetry headers implemented with dynamic versioning (no manual updates needed) - 📖 Full API reference available at [reference.md](https://github.com/auth0/auth0-python/blob/master/reference.md) ## Testing - ✅ All 389 wire tests passing - ✅ Integration tests verified with live Auth0 tenant - ✅ Both Authentication and Management APIs tested successfully - ✅ Async clients tested and verifiedConfiguration menu - View commit details
-
Copy full SHA for ae22a65 - Browse repository at this point
Copy the full SHA ae22a65View commit details
Commits on Feb 10, 2026
-
🌿 Fern Regeneration -- February 10, 2026 (#778)
This PR regenerates code to match the latest API Definition. Co-authored-by: fern-api[bot] <115122769+fern-api[bot]@users.noreply.github.com>
Configuration menu - View commit details
-
Copy full SHA for a47fda9 - Browse repository at this point
Copy the full SHA a47fda9View commit details -
**Fixed** - fix: Remove placeholder defaults from optional parameters [\#778](#778) ([fern-api[bot]](https://github.com/apps/fern-api)) **Added** - feat: Additional updates [\#778](#778) ([fern-api[bot]](https://github.com/apps/fern-api))
Configuration menu - View commit details
-
Copy full SHA for 441ca6e - Browse repository at this point
Copy the full SHA 441ca6eView commit details
Commits on Feb 11, 2026
-
**Fixed** - fix: Remove placeholder defaults from optional parameters + additional updates [\#778](#778) ([fern-api[bot]](https://github.com/apps/fern-api))
Configuration menu - View commit details
-
Copy full SHA for 2f4906d - Browse repository at this point
Copy the full SHA 2f4906dView commit details
Commits on Mar 17, 2026
-
feat+fix: Pagination fix, SDK logging, OAuth1/DPoP types (#785)
## Summary This Fern regeneration includes several significant changes across 61 files: ### Bug Fix: Pagination (Fixes #783) - Fixed incorrect page advancement in **64 paginated endpoints** across all `raw_client.py` files - **Before (broken):** `page = page + len(_items or [])` — skipped pages when `per_page > 1` - **After (fixed):** `page = page + 1` - correctly advances one page at a time ### New Feature: SDK Logging Infrastructure - Added configurable logging via new `logging` parameter on the `Auth0` client - New `core/logging.py` module with `ConsoleLogger`, `Logger`, `LogConfig`, and `ILogger` protocol - Supports log levels: `debug`, `info`, `warn`, `error` with a `silent` mode (default) - HTTP request/response logging at debug level with method, URL, status code - Sensitive header redaction (`Authorization`, `Cookie`, `X-Api-Key`, etc.) in log output - Custom logger support via `ILogger` protocol ### New Types: OAuth1 & DPoP Connection Support - 10 new connection type files for OAuth1 connections (`connection_access_token_url_oauth1`, `connection_client_id_oauth1`, `connection_scripts_oauth1`, etc.) - DPoP signing algorithm types (`connection_dpop_signing_alg_enum`, `connection_dpop_signing_alg_values_supported`) - OIDC metadata types (`connection_options_oidc_metadata`, `connection_options_common_oidc`) - New `client_token_exchange_type_enum` and `resource_server_proof_of_possession_required_for_enum` ### Other Changes - Self-service profiles: updated response types (`create`, `get`, `update`) and `self_service_profile` model - Removed `core/custom_pagination.py` (replaced by standard pagination) - Updated `reference.md` and test configuration (`conftest.py`) ### Manual Fixes (on top of Fern regeneration) - Fixed `client_wrapper.py` to accept and forward the `logging` parameter to `HttpClient`/`AsyncHttpClient` (was missing, causing `TypeError` at runtime) - Added `ManagementClient` and `AsyncManagementClient` to `TYPE_CHECKING` and `__all__` exports in `__init__.py` (Fixes #793) ## Breaking Changes - `custom_pagination.py` has been removed — any code importing from it will need to update ## Test Plan - [x] Pagination: Created 5 roles, paginated with `per_page=2`, verified 3 pages returned with all 5 roles - [x] Logging: Verified debug logging captures HTTP method/URL/status, header redaction works, level filtering suppresses lower levels, silent mode produces zero output - [x] Existing tests (auth, management, Issue #778) continue to pass --------- Co-authored-by: fern-api[bot] <115122769+fern-api[bot]@users.noreply.github.com> Co-authored-by: Snehil Kishore <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for e506d73 - Browse repository at this point
Copy the full SHA e506d73View commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff v4...master