Metadata-Version: 2.1
Name: keycloaknanny
Version: 23.0.0
Summary: Simple Python library for managing a toy Keycloak instance.
Project-URL: Documentation, https://github.com/soxofaan/keycloak-nanny#readme
Project-URL: Issues, https://github.com/soxofaan/keycloak-nanny/issues
Project-URL: Source, https://github.com/soxofaan/keycloak-nanny
Author-email: Stefaan Lippens <soxofaan@gmail.com>
License-Expression: MIT
License-File: LICENSE.txt
Keywords: keycloak
Classifier: Development Status :: 4 - Beta
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Requires-Python: >=3.7
Requires-Dist: requests>2.28.0
Description-Content-Type: text/markdown


# Keycloak Nanny

Simple Python wrapper around the Keycloak admin REST API,
to programmatically create realms, clients, users, ...

Intended to be used on test/toy/dummy Keycloak instances,
e.g. running locally in docker:

```bash
docker run --rm \
    -p 8642:8080 \
    -e KEYCLOAK_ADMIN=admin \
    -e KEYCLOAK_ADMIN_PASSWORD=admin \
    quay.io/keycloak/keycloak:21.0.2 start-dev
```

Then create realms, client and users against this instance:

```python
kc_nanny = keycloaknanny.KeycloakNanny("http://localhost:8642"),


realm = nanny.create_realm()
print("Created realm", realm)
nanny.set_default_realm(realm.name)

client = nanny.create_client()
print("Created client", client)

user = nanny.create_user()
print("Created user", user)

```
