diff --git a/README.md b/README.md index f95200c..faaaf58 100644 --- a/README.md +++ b/README.md @@ -584,7 +584,7 @@ Note: Ids are sent as clientScopeId or clientId and mapperId everything else is | Update the user | updateUser | ️️️✔️ | | Update partial data for the user | updatePartialUser | ️️️✔️ | | Delete the user | deleteUser | ️️️✔️ | -| Get consents granted by the user | | ❌ | +| Get consents granted by the user | | ️✔️ | | Revoke consent and offline tokens for particular client from user | | ❌ | | Disable all credentials for a user of a specific type | | ❌ | | Send a update account email to the user An email contains a link the user can click to perform a set of required actions. | executeActionsEmail | ✔️ | diff --git a/src/Admin/KeycloakClient.php b/src/Admin/KeycloakClient.php index 58ec556..df62886 100644 --- a/src/Admin/KeycloakClient.php +++ b/src/Admin/KeycloakClient.php @@ -275,9 +275,10 @@ * @method array syncUserStorage(array $args = array()) { @command Keycloak syncUserStorage } * * @method array getSocialLogins(array $args = array()) { @command Keycloak getSocialLogins } - * @method array addSocialLogin(array $args = array()) { @command Keycloak getSocialLogins } - * @method array removeSocialLogin(array $args = array()) { @command Keycloak getSocialLogins } - * + * @method array addSocialLogin(array $args = array()) { @command Keycloak addSocialLogin } + * @method array removeSocialLogin(array $args = array()) { @command Keycloak removeSocialLogin } + * @method array getUserConsents(array $args = array()) { @command Keycloak getUserConsents } + * */ class KeycloakClient extends GuzzleClient diff --git a/src/Admin/Resources/keycloak-1_0.php b/src/Admin/Resources/keycloak-1_0.php index 3f9c81f..24dba02 100644 --- a/src/Admin/Resources/keycloak-1_0.php +++ b/src/Admin/Resources/keycloak-1_0.php @@ -5197,6 +5197,26 @@ ) ), + 'getUserConsents' => array( + 'uri' => 'admin/realms/{realm}/users/{id}/consents', + 'description' => 'Get the consents granted by a user', + 'httpMethod' => 'GET', + 'parameters' => array( + 'realm' => array( + 'location' => 'uri', + 'description' => 'The Realm name', + 'type' => 'string', + 'required' => true, + ), + 'id' => array( + 'location' => 'uri', + 'description' => 'User id', + 'type' => 'string', + 'required' => true + ) + ) + ), + 'updateUser' => array( 'uri' => 'admin/realms/{realm}/users/{id}', 'description' => 'Update a user (Username must be unique)',