Skip to main content
Version: Current

Roles.DeleteRoleAsync

Description​

The API deletes an existing Role with a specified role ID from the connected AI Command Center.

Signature [C#]​

Task DeleteRoleAsync(int roleId)

Properties​

Input​

PropertyDescription
roleIdSpecify the ID to delete a Role.

Remarks​

Use DeleteRoleAsync API to delete a Role from the connected AI Command Center.

Example​

C#
public void DeleteRole()
{
IControlRoomContext context = LoginControlRoom();

int roleId = 5;

Task.Run(() => context.Roles.DeleteRoleAsync(roleId)).Wait();
}
C#
public IControlRoomContext LoginControlRoom()
{
IControlRoomContext context;
string connectionString;

connectionString = "ServerUrl=https://demo.onnitellibuddies.com;UserName=demoadmin;Password=password";
context = new ControlRoomContext(connectionString);

context.Open();
return context;
}