createFirstAdmin #
Creates a new user in Keycloak and use the createFirstAdmin function of Kuzzle.
It add the local strategy to the admin user and set the password. In order to connect to the Admin Console
Parameters #
Parameter | Type | Description | Required |
---|---|---|---|
kuid | string | kuzzle user ID (like admin ) | yes |
string | User email | yes | |
firstName | string | User first name | yes |
lastName | string | User last name | yes |
username | string | User username | yes |
password | string | User password | yes |
Websocket #
await kuzzle.query({
controller: "keycloak",
action: "createFirstAdmin",
_id: "<kuid>",
body: {
content: {
email: "admin@example.com",
firstName: "Admin",
lastName: "User",
username: "admin",
password: "password123",
},
},
});
HTTP #
POST http://<host>:<port>/keycloak/users/firstAdmin/<kuid>
Content-Type: application/json
{
"content": {
"email": "admin@example.com",
"firstName": "Admin",
"lastName": "User",
"username": "admin",
"password": "password123"
}
}