Releases: PropelAuth/propelauth-py
v3.0.0b5
Roles and Permissions are now customizable in the PropelAuth backend, and this new change handles that. A user still has a single role, but now we give a list of all roles that role "inherits" from, plus a list of permissions associated with that role. These are populated in OrgMemberInfo.
There are three basic attributes to handle these changes, alongside some associated functions:
- use_role is now user_assigned_role. It's now a straight string instead of an enum. Check for this exact role with user_is_role() method.
- user_inherited_roles_plus_current_role is a list of all roles that this user "inherits". Instead of checking roles with < and >, you should check for the existence of the role in this list using the new user_is_at_least_role() method.
- user_permissions is a list of all permissions this user has. These are the four propelauth-specific permissions (e.g. enabling SAML, deleting users, etc) plus any custom permissions you've added to the assigned role. Check for these permissions with the user_has_permission() and user_has_all_permissions() methods.
Also included with these changes are four new validation functions to that will throw appropriate errors, plus four wrappers to work with access tokens.
Other changes in relation to customizable RBAC roles:
- Removed UserRole enum, the concept of minimum required roles, and the associated UnexpectedException.
- New exception: ForbiddenException.user_doesnt_have_required_permission
The basic function validate_access_token_and_get_user_with_org has been changed to validate_access_token_and_get_user_with_org_by_minimum_role. If you do nothing else with your code, update this.
v2.0.4
Add API endpoints for configuring SAML and user management
v2.0.3
Release new APIs for migrations
v3.0.0b4
Adds support for mapping roles => permissions and allow for tree-like roles.
v3.0.0b3
Make sure to wrap the org member function
v3.0.0b1
v3.0.0b2 Bump version for new APIs
v2.0.2
- Added update user metadata + update user email APIs
- Added ID checks to avoid unnecessary calls and discourage requests with malformed ids
v2.0.1
Added new APIs for fetching users/orgs and creating users
v3.0.0b0
Add beta release for custom role support Remove role enum. Roles are now fetched from the server, and are therefore strings.
v2.0.0
Rename init_auth to init_base_auth