Skip to main content

Admin

Changes made in the admin console or through the admin APIs are recorded as admin events.

Example​

The following is an example of the detail contained in an admin event:

{
"uid": "31db295f-4bc7-4ba0-b689-65197efb5c6e",
"time": 1588696343501,
"realmId": "master",
"type": "admin.CLIENT-CREATE",
"resourceType": "CLIENT",
"operationType": "CREATE",
"resourcePath": "clients/396664b6-40c5-4d45-bedf-2d8dd0f2af0e",
"authDetails": {
"realmId": "master",
"clientId": "54aee1f9-2fe5-4049-99e8-3b72277a8e43",
"userId": "f7cd3491-7c6c-480c-bc5c-b2b3b0fb048c",
"ipAddress": "78.195.109.209",
"username": "admin"
}
}

Event types​

All admin event types are indicated in the type field of the json event with the admin. prefix. This field is a concatenation of the resourceType and operationType.

Operation types​

This field indicates what operation was executed on a resource. It is one of CREATE, DELETE, UPDATE, or ACTION. ACTION is used for operations that don't fit the classic CRUD model, such as sending a user a required-actions email, logging out all of a user's sessions, or testing an LDAP connection.

Resource types​

NameDescription
REALMThe realm and its settings
REALM_ROLEA realm role
REALM_ROLE_MAPPINGA realm role granted to a user or group
REALM_SCOPE_MAPPINGA realm role in a client or client scope's scope
AUTH_FLOWAn authentication flow
AUTH_EXECUTION_FLOWA sub-flow within an authentication flow
AUTH_EXECUTIONA step within an authentication flow
AUTHENTICATOR_CONFIGThe configuration of an authentication step
REQUIRED_ACTIONA required action
REQUIRED_ACTION_CONFIGThe configuration of a required action
IDENTITY_PROVIDERAn identity provider
IDENTITY_PROVIDER_MAPPERAn identity provider mapper
PROTOCOL_MAPPERA protocol mapper on a client or client scope
USERA user
USER_LOGIN_FAILUREA user's brute force detection state
USER_SESSIONA user session
USER_FEDERATION_PROVIDERA user federation provider, such as LDAP
USER_FEDERATION_MAPPERA user federation mapper
USER_PROFILEThe realm's user profile configuration
GROUPA group
GROUP_MEMBERSHIPA user's membership in a group
CLIENTA client
CLIENT_INITIAL_ACCESS_MODELAn initial access token for dynamic client registration
CLIENT_ROLEA client role
CLIENT_ROLE_MAPPINGA client role granted to a user or group
CLIENT_SCOPEA client scope
CLIENT_SCOPE_MAPPINGA role in a client scope's scope
CLIENT_SCOPE_CLIENT_MAPPINGA client scope assigned to a client
CLUSTER_NODEA registered cluster node for a client
COMPONENTA component, such as a key provider or user storage provider
AUTHORIZATION_RESOURCE_SERVERA client's authorization services settings
AUTHORIZATION_RESOURCEAn authorization resource
AUTHORIZATION_SCOPEAn authorization scope
AUTHORIZATION_POLICYAn authorization policy or permission
CUSTOMA custom resource type

Phase Two's Organizations extension adds these resource types for organization changes: ORGANIZATION, ORGANIZATION_MEMBERSHIP, ORGANIZATION_ROLE, ORGANIZATION_ROLE_MAPPING, INVITATION, DOMAIN, and ORGANIZATION_IMPORT.

Resource path​

The resourcePath field is the path of the changed resource relative to the realm in the admin API, delimited by /. For example, clients/396664b6-40c5-4d45-bedf-2d8dd0f2af0e is a client, and users/f7cd3491-7c6c-480c-bc5c-b2b3b0fb048c/role-mappings/realm is a user's realm role mappings.