Enum TeamRole
- Namespace
- NetCord
- Assembly
- NetCord.dll
A TeamUser can have one of four roles (Owner, Admin , Developer, and ReadOnly), and each role inherits the access of those below it.
[JsonConverter(typeof(SafeStringEnumConverter<TeamRole>))]
public enum TeamRole
Fields
[JsonPropertyName("admin")] Admin = 0
Admins have similar access to owners, except they cannot take destructive actions on the team or team-owned apps.
[JsonPropertyName("developer")] Developer = 1
Developers can access information about team-owned apps, like the client secret or public key. They can also take limited actions on team-owned apps, like configuring interaction endpoints or resetting the bot token. TeamUsers with the Developer role cannot manage the Team or its users, or take destructive actions on team-owned Applications.
[JsonPropertyName("read-only")] ReadOnly = 2
Read-only users can access information about a Team and any team-owned Applications. Some examples include getting the IDs of applications and exporting payout records. Members can also invite bots associated with team-owned apps that are marked private.
Remarks
The Owner role is not represented in the TeamRole enum, as it is not represented in TeamUser's Role field. Instead, owners can be identified using a Team's OwnerId field. They have the most permissive role, and can take destructive, irreversible actions like deleting team-owned apps or the team itself. Teams are limited to 1 owner.