$guildRoles
Returns a list of all roles in the guild, displaying their names, IDs, or mentions.
You can specify the type of information you want (ID, name, or mention) and limit the number of roles returned.
Usage:
$guildRoles[type;amount;separator]
Parameters:
type(Optional): Determines what information to return for each role. Possible values are:id: Returns the role's ID.name: Returns the role's name. (Default)mention: Returns the role's mention.
amount(Optional): The maximum number of roles to return. If omitted, all roles will be returned.separator(Optional): The separator between the returned list, default is ', '
Example:
This example shows how to retrieve the IDs of all roles in the guild.
Related Functions
- $roleID: Retrieves a role ID by its name.
Function difficulty: Easy
Tags: Guild Roles all roles server roles roles server/ guild
⏱️ Function Cooldown
This function has a built-in cooldown to help prevent excessive usage.
| Property | Value |
|---|---|
| ⏱️ Duration | 1 second |
| 🆔 Tracked By | Server |
| 🌐 Scope | Cache |
Functions with the same Scope share cooldowns based on the same
Tracked Byvalue.
💎 Tier 3+ servers bypass this cooldown. See Premium Perks.