Manage Permissions of the Role
- Get the list of existing permissions for the required role
- Call API GET /role-groups/permissions.
You need to pass roleCode in the request URL parameter.
Role code can be taken from code in the response of API GET /role-groups or POST /role-groups/view
- Copy the list of permissions returned in the permissions section.
Example:
API GET /role-groups/permissions?roleCode=accountant
Response { "records": [ { "roleCode": "accountant", "permissions": [ "ISSUER_VIEWER", "TRANSACTIONS_VIEWER", "COIN_MANAGER", "CONVERSATION_MESSAGE_CREATION_EXECUTOR", "CONVERSATION_VIEWER", "BUSINESS_REQUEST_BANK_WITHDRAWAL", "CASH_DESK_INPUT_EXECUTOR", "BUSINESS_REQUEST_MANAGER", "BUSINESS_REQUEST_BANK_TOP_UP", "CURRENCY_VIEWER", "BANK_TOP_UP_VALIDATION_EXECUTOR", "CASH_DESK_COLLECT_EXECUTOR", "COIN_VIEWER", "COIN_VALIDATOR", "BANK_WITHDRAWAL_VALIDATION_EXECUTOR", "GATE_INVESTMENT_EXECUTOR", "BUSINESS_REQUEST_CASH_DESK_WITHDRAWAL", "CASH_DESK_WITHDRAWALS_MANAGER", "ORGANIZATION_VIEWER", "BANK_PROCESS_VIEWER", "GATE_PROVIDER_VIEWER", "CONTACT_VALIDATOR", "CASH_DESK_INVESTMENT_EXECUTOR", "PROFILE_VIEWER", "BANK_TOP_UP_EXECUTOR", "CASH_DESK_WORKING_DAYS_MANAGER" ] } ] }
2. Change permissions list
Change the received permissions list so it contains all the permissions you need.
Add permissions you need to add, or delete permissions you need to remove.
3. Assign new list of permissions
Call API PUT /management/organization-settings/{organizationTypeCode}/roles/{roleName}
Pass system in the {organizationTypeCode} and the required role code in the {roleName}
Pass the required list of permissions in the permissions section.
Example:
Added permission “RECONCILIATION_RECORDS_VIEWER”
API PUT /management/organization-settings/system/roles/accountant
Request:
{ "permissions": [ "ISSUER_VIEWER", "TRANSACTIONS_VIEWER", "COIN_MANAGER", "CONVERSATION_MESSAGE_CREATION_EXECUTOR", "CONVERSATION_VIEWER", "BUSINESS_REQUEST_BANK_WITHDRAWAL", "CASH_DESK_INPUT_EXECUTOR", "BUSINESS_REQUEST_MANAGER", "BUSINESS_REQUEST_BANK_TOP_UP", "CURRENCY_VIEWER", "BANK_TOP_UP_VALIDATION_EXECUTOR", "CASH_DESK_COLLECT_EXECUTOR", "COIN_VIEWER", "COIN_VALIDATOR", "BANK_WITHDRAWAL_VALIDATION_EXECUTOR", "GATE_INVESTMENT_EXECUTOR", "BUSINESS_REQUEST_CASH_DESK_WITHDRAWAL", "CASH_DESK_WITHDRAWALS_MANAGER", "ORGANIZATION_VIEWER", "BANK_PROCESS_VIEWER", "GATE_PROVIDER_VIEWER", "CONTACT_VALIDATOR", "CASH_DESK_INVESTMENT_EXECUTOR", "PROFILE_VIEWER", "BANK_TOP_UP_EXECUTOR", "CASH_DESK_WORKING_DAYS_MANAGER", "RECONCILIATION_RECORDS_VIEWER" ] }