This service is available via Telligent.Evolution.Extensibility.Apis.Get<Telligent.Evolution.Extensibility.Api.Version1.IRoles>()
and is defined in Telligent.Evolution.Platform.dll
Events
Events.AfterCreate
Handler
void RoleAfterCreateEventHandler(RoleAfterCreateEventArgs e);
Events.AfterDelete
Handler
void RoleAfterDeleteEventHandler(RoleAfterDeleteEventArgs e);
Events.AfterUpdate
Handler
void RoleAfterUpdateEventHandler(RoleAfterUpdateEventArgs e);
Events.BeforeCreate
Handler
void RoleBeforeCreateEventHandler(RoleBeforeCreateEventArgs e);
Events.BeforeDelete
Handler
void RoleBeforeDeleteEventHandler(RoleBeforeDeleteEventArgs e);
Events.BeforeUpdate
Handler
void RoleBeforeUpdateEventHandler(RoleBeforeUpdateEventArgs e);
Methods
Role Create(string name, string description, RolesCreateOptions options = null);
Creates a role
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
name | string | Name | Required | ||
description | string | Description | Required | ||
options | RolesCreateOptions | Optional parameter names are: GroupId, UserId, Username, RoleId, RoleName, Include | Optional |
Return Type
Role CreateFromLdap(string ldapGroupName);
Creates a role based on an LDAP group
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
ldapGroupName | string | LDAP group name | Required |
Return Type
Role CreateFromLdap(string ldapGroupName, string distinguishedName);
Creates a role based on an LDAP group
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
ldapGroupName | string | LDAP group name | Required | ||
distinguishedName | string | Distinguished name | Required |
Return Type
AdditionalInfo Delete(int roleId, RolesDeleteOptions options = null);
Deletes a role
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
roleId | int | Role Id | Required | ||
options | RolesDeleteOptions | Optional parameter names are: UserId, Username, Include (user) | Optional |
Return Type
ApiList<Role> Find(string matchText);
Searches for a role
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
matchText | string | Match text | Required |
Return Type
Role Get(int roleId);
Gets a role
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
roleId | int | Role Id | Required |
Return Type
Role Get(string application, int? id, int roleId, RolesGetOptions options = null);
Gets a role
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
application | string | Application type | Required | ||
id | int? | ID of the application to get a role for | Required | ||
roleId | int | Role Id | Required | ||
options | RolesGetOptions | Optional parameter names are: IncludePermissions, Include (granted or denied) | Optional |
Return Type
ApiList<Role> List(Guid nodeId, Guid permissionId);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
nodeId | Guid | Node Id | Required | ||
permissionId | Guid | Permission Id | Required |
Return Type
PagedList<Role> List(RolesListOptions options = null);
Lists roles
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
options | RolesListOptions | Optional parameter names are: Application, Id (ID of the application), UserId, Username, IncludePermissions, PermissionId, Include (granted or denied), IncludeWithAvatarUrl, PageSize, PageIndex | Optional |
Return Type
Role Update(int roleId, string name, string description, RolesUpdateOptions options = null);
Updates a role
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
roleId | int | Role Id | Required | ||
name | string | Name | Required | ||
description | string | Description | Required | ||
options | RolesUpdateOptions | Optional parameter names are: GroupId | Optional |