Browse Source

docs: added change of realm example

pull/365/head
Romuald OUATTARA 2 years ago
parent
commit
a1591ba50a
  1. 6
      README.md

6
README.md

@ -319,4 +319,10 @@ idps = keycloak_admin.get_idps()
# Create a new Realm
keycloak_admin.create_realm(payload={"realm": "demo"}, skip_exists=False)
# Changing Realm
keycloak_admin = KeycloakAdmin(realm_name="main", ...)
keycloak_admin.get_users() # Get user in main realm
keycloak_admin.realm_name = "demo" # Change realm to 'demo'
keycloak_admin.get_users() # Get users in realm 'demo'
keycloak_admin.create_user(...) # Creates a new user in 'demo'
```
Loading…
Cancel
Save