Python Keycloak API client
This library wraps the Keycloak REST API, providing an easy way to manage users, clients, and other Keycloak resources. It’s simple, extendable, and has been tested in production.
Usage
Install
$ pip install python-keycloak-api-client
Example
from keycloak_api_client import KeycloakApiClient
client = KeycloakApiClient(
keycloak_url: "https://auth.myservice.com",
realm: "myservice",
admin_username: "my_keycloak_admin",
admin_password: "...",
admin_client_id: "my_service_backend_client_id",
admin_client_secret: "...",
relative_path: "/auth",
)
read_kc_user = client.get_keycloak_user_by_email('johndoe@myservice.com')
read_kc_user.email # johndoe@myservice.com
read_kc_user.enabled # True
read_kc_user.first_name # John
read_kc_user.last_name # Doe
...
Development
Test
# Run linter and tests for all Python versions
$ tox
Linter
# Format
$ ruff format
# Check
$ ruff check
Install
$ pip install -e .
Changelog
License
Metadata
Release files for python-keycloak-api-client 0.14.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| python_keycloak_api_client-0.14.2.tar.gz | 41.4 kB | Without provenance | Details for python_keycloak_api_client-0.14.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| python_keycloak_api_client-0.14.2-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details for python_keycloak_api_client-0.14.2-py2.py3-none-any.whl |
Total release size: 49.5 kB
Release files / python_keycloak_api_client-0.14.2.tar.gz
| Download URL | python_keycloak_api_client-0.14.2.tar.gz |
|---|---|
| Size | 41.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
182950bef26cc6606420c213b1d809b585dc0bf00a6b0c70d087bf0d620f4bfc
|
|
BLAKE2b-256 checksum How to use checksums |
c57e6b073ee46d81ba887044fc9465adf2fb2a34afafb3e209950ed6b334a8fa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.13
|
Release files / python_keycloak_api_client-0.14.2-py2.py3-none-any.whl
| Download URL | python_keycloak_api_client-0.14.2-py2.py3-none-any.whl |
|---|---|
| Size | 8.2 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
7bead2636e88f9cdfe0c25b6f73cc7a3ecafe2cc6f176d7775d49bd6e76134f0
|
|
BLAKE2b-256 checksum How to use checksums |
6e3a238e74ce1ccf9829fa9d6e13638d843501c533454f36000e92eb6594e7b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.13
|
Security for python-keycloak-api-client 0.14.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.