Official Python SDK for the OneLogin API (v1 and v2). Supports OAuth2 authentication, user and role management, event and factor APIs, and SAML assertion handling. Current version 3.2.5, requires Python >=3.10. Active development with quarterly releases.
pip install oneloginVerified import paths — ran on the pinned version, not inferred.
Initialize the OneLogin client and fetch a list of users.
Use keyword arguments: OneLoginClient(client_id=..., client_secret=..., region='us')
Use create_user2() and handle the User model returned.
Access attributes via dot notation (e.g., user.email) rather than user['email'].
Wrap API calls with token expiry check or call authenticate() before each batch.
Migrate to the new client and use v2 endpoints where possible.