Sync Group Members
POST /obp/v7.0.0/management/groups/GROUP_ID/sync-members
OBPv7.0.0-syncGroupMembers No role required GroupUserEntitlement
Bring the Entitlements of every member of a Group in line with the Group's current Roles.
A Group grants its Roles when a user is added to it, so changing a Group's Roles does not change what its existing members hold. This endpoint does that, for each member:
- a Role of the Group the member does not hold at the Group's bank id is granted (the member gets an email for it), recorded against this Group;
- an Entitlement this Group granted, for a Role the Group no longer has, is deleted, unless another Group the member is in, at the same bank id, still grants that Role: then it is kept and recorded against that Group (no email; the member's Roles do not change).
Entitlements granted by hand, or by other Groups, are not touched. Nobody is added to or removed from the Group.
The members are the users added to the Group, plus the users holding an Entitlement it granted.
With dry_run=true nothing is changed and the response says what would be.
Requires CanAddUserToGroupAtOneBank or CanAddUserToGroupAtAllBanks, and CanRemoveUserFromGroupAtOneBank or CanRemoveUserFromGroupAtAllBanks (the AllBanks Roles for a system level Group).
User Authentication is Required. The User must be logged in. The Application must also be authenticated.
URL Parameters:
GROUP_ID: GROUP_ID
JSON request body fields (0)
JSON response body fields (11)
Example success response
{
"group_id": "group-id-123",
"bank_id": "gh.29.uk",
"dry_run": false,
"members": [
{
"user_id": "user-id-123",
"username": "felixsmith",
"entitlements_created": [
"CanGetCustomer"
],
"entitlements_deleted": [
"CanCreateTransaction"
],
"entitlements_moved": [
{
"role_name": "CanGetAccount",
"to_group_id": "group-id-456"
}
]
}
]
}Possible errors (2)
- OBP-20001: User not logged in. Authentication is required!
- OBP-50000: Unknown Error.