Skip to content
Server Helpers hasRoleNamed

$hasRoleNamed — Tells whether a member has a role, found by its name (not case sensitive)

Tells whether a member has a role, found by its name (not case sensitive).

Syntax

$hasRoleNamed[userID;roleName]

Parameters

  • userID (ID, required) — The member.
  • roleName (text, required) — The name of the role.

Return Value

  • true or false.

Usage

$hasRoleNamed[1;mod] → "true"

Example

$sendMessage[$hasRoleNamed[1;mod]]

Try it

Paste an example into the playground to preview its message (functions that act on Discord are not run), or build the same thing with blocks.