Configure Roles
The role system is a vital component of the Drivers Hub, governing user permissions. A well-configured role system ensures security, prevents unauthorized actions, and allows specific staff members to complete their tasks. Roles also represent the positions users hold, such as "Leadership", "Human Resources Team", and "Driver", and are grouped and displayed in the Members tab.
UNDERToCONSTRUCTIONcreate a role, navigate to Configuration - Roles, click +, and complete the input form.
*Name and Order ID are required fields while the others are all optional.
Attributes
- Name: A string describing the role, e.g., "Leadership", "Human Resources Team".
-
ID: Automatically assigned unique identifier. Editable only in the JSON editor. Changing the ID requires removing the role from all users and re-adding it when the new configuration is active. The role ID in
perms
must also be updated to maintain permissions. -
Permissions: Selectable permissions from a dropdown list of built-in permissions. Additional permissions may be created by typing the key (all lowercase, using
_
to connect words), e.g.,permission_of_external_application
. The client currently uses agallery
permission not built into the server. -
Order ID: The role's order, where a smaller value means a higher role. Negative values are accepted. Users with Manage Roles permission can only add/remove roles lower than or equal to their highest role to/from other users. For instance, a user with the highest role's order ID as
10
cannot add a role with an order ID of5
or10
to other users. -
Display Order ID: Display order of the role in the Members tab. A smaller value means higher in the list, with
-1
reserved for hiding the role in the tab. - Color: Controls the role color in users' profiles. Administrator of Drivers Hubs under the Special Guest subscription can configure users' name colors to match their highest role's color.
- Discord Role ID: When specified, the Discord Role is added/removed to/from the user in Discord along with the Drivers Hub role. The user must have connected their Discord account in Drivers Hub.
Notes
- You can create unlimited roles in Drivers Hubs operated by The Drivers Hub Project (CHub). However, it's not recommended to create too many roles to avoid performance degradation.
- The up and down arrows on the right control the role's order in the configuration tab and do not affect the Order ID of the roles.
- The ID of roles must be unique, while the Order ID / Display Order ID may be duplicated.
- After configuring roles, remember to save and reload the configuration. To reflect changes in your client, go to Settings, click Clear Cache, wait 30 seconds, and reload the current tab.