Delete() [UserServicePermissionManager]
Delete a user permission
Description
Delete a user permission for a service.
Package Details
Interface
IUserServicePermissionManager
Syntax
await UserServicePermissionManager.Delete(UserServicePermission);
Returns
Task<UserServicePermission>
API
DELETE
/api/v1/users/{id}/permissions/{permissionId}
Parameters
Parameter | Description | Parameter Type |
---|---|---|
id | The user's id | path |
permissionId | The permission id | path |
serviceId | The service id | query string |
organizationId | The id of the organization (optional) | query string |
Returns
200 OK
Example
const int userId = 2757;
const int serviceId = 2;
const int permissionId = 3;
const int organizationId = 9999;
var userServicePermission = new UserServicePermission
{
PermissionId = permissionId,
UserId = userId,
ServiceId = serviceId,
OrganizationId = organizationId
};
var userServicePermission = await _userServicePermissionManager.Delete(userServicePermission);