8000 Added user assignment to groups and updated doc by vcreuza · Pull Request #28 · MohammadWaleed/keycloak-admin-client · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Added user assignment to groups and updated doc #28

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
mer 8000 ged 1 commit into from
Nov 20, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -477,8 +477,8 @@ Note: Ids are sent as clientScopeId or clientId and mapperId everything else is
| Remove a social login provider from user | | ❌ |
| GET /{realm}/users/{id}/groups | getUserGroups | ✔️ |
| GET /{realm}/users/{id}/groups/count | getUserGroupsCount | ✔️ |
| PUT /{realm}/users/{id}/groups/{groupId} | | ❌ |
| DELETE /{realm}/users/{id}/groups/{groupId} | | ❌ |
| PUT /{realm}/users/{id}/groups/{groupId} | addUserToGroup | ✔️ |
| DELETE /{realm}/users/{id}/groups/{groupId} | deleteUserFromGroup | ✔️ |
| Impersonate the user | | ❌ |
| Remove all user sessions associated with the user Also send notification to all clients that have an admin URL to invalidate the sessions for the particular user. | | ❌ |
| Get offline sessions associated with the user and client | | ❌ |
Expand Down
2 changes: 2 additions & 0 deletions src/Admin/KeycloakClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,8 @@
* @method array getUserGroupsCount(array $args = array()) { @command Keycloak getUserGroupsCount }
* @method array updateUser(array $args = array()) { @command Keycloak updateUser }
* @method array deleteUser(array $args = array()) { @command Keycloak deleteUser }
* @method array addUserToGroup(array $args = array()) { @command Keycloak addUserToGroup }
* @method array deleteUserFromGroup(array $args = array()) { @command Keycloak deleteUserFromGroup }
*
*/

Expand Down
52 changes: 52 additions & 0 deletions src/Admin/Resources/keycloak-1_0.php
Original file line number Diff line number Diff line change
Expand Up @@ -4963,5 +4963,57 @@
),
),

'addUserToGroup' => array(
'uri' => 'auth/admin/realms/{realm}/users/{id}/groups/{groupId}',
'description' => 'Assign a specific user to a specific group',
'httpMethod' => 'PUT',
'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,
),
'groupId' => array(
'location' => 'uri',
'description' => 'Group id',
'type' => 'string',
'required' => true,
),
),
),

'deleteUserFromGroup' => array(
'uri' => 'auth/admin/realms/{realm}/users/{id}/groups/{groupId}',
'description' => 'Remove a specific user from a specific group',
'httpMethod' => 'DELETE',
'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,
),
'groupId' => array(
'location' => 'uri',
'description' => 'Group id',
'type' => 'string',
'required' => true,
),
),
),

) //End of Operations Array
);//End of return array
0