RolesApi

interface RolesApi

Functions

Link copied to clipboard
abstract suspend fun actionsOnRoles(roleId: Long, command: String? = null): PostRolesRoleIdResponse

Enable Role | Disable Role Description : Enable role in case role is disabled. | Disable the role in case role is not associated with any users. Example Request: https://DomainName/api/v1/roles/{roleId}?command=enable https://DomainName/api/v1/roles/{roleId}?command=disable Responses:

Link copied to clipboard
abstract suspend fun createRole(postRolesRequest: PostRolesRequest): PostRolesResponse

Create a New Role Mandatory Fields name, description Responses:

Link copied to clipboard
abstract suspend fun deleteRole(roleId: Long): DeleteRolesRoleIdResponse

Delete a Role Description : Delete the role in case role is not associated with any users. Responses:

Link copied to clipboard
abstract suspend fun retrieveAllRoles(): List<GetRolesResponse>

List Roles Example Requests: roles roles?fields=name Responses:

Link copied to clipboard
abstract suspend fun retrieveRole(roleId: Long): GetRolesRoleIdResponse

Retrieve a Role Example Requests: roles/1 roles/1?fields=name Responses:

Link copied to clipboard

Retrieve a Role's Permissions Example Requests: roles/1/permissions Responses:

Link copied to clipboard
abstract suspend fun updateRole(roleId: Long, putRolesRoleIdRequest: PutRolesRoleIdRequest): PutRolesRoleIdResponse

Update a Role

Link copied to clipboard
abstract suspend fun updateRolePermissions(roleId: Long, putRolesRoleIdPermissionsRequest: PutRolesRoleIdPermissionsRequest): PutRolesRoleIdPermissionsResponse

Update a Role's Permissions