Skip to content

Actions

Actions are used to perform various operations in response to a command or component invocation.


Actions are part of Custom Commands.


Settings Interface#

Each action has a certain set of general settings regardless of its type:

action

Action Settings Interface
  • Action Name — the name of the action displayed in its tab and action selections;

  • Action UUID ("i" icon) — unique action identifier used in Message Templates;

  • Action Type — type of the action. You can find detailed explanation for each of them just below in next sections within this category;

  • Short description — just a short description of this action displayed in action selections;

  • Override Access Rights — turning on this option will force access rights checking for this action additionally to command's access rights.


Action Types#

  1. Send Message — execution of such action will result in simple response with specified text or embed.

  2. Modal Form — execution of such action will show modal form to get some input from user with great UI.

  3. Change Roles — execution of such action will remove or add the roles specified in the action settings. By default, this can only be done by the member who executed this action by command or component.

  4. Internal Command — execution of such action will be redirected to build-in command specified in the template of this action. For example, if you create a command with the name me, enter the user in the action template, invocation of !me command will do the same thing as you would invoke !user command directly.

  5. Execute Template Code — execution of such action will interpret specified template and will respond with simple success message. This action type is useful for executing another action conditionally.


Executing action by another action#

If you're an advanced used able to handle advanced features of Message Templates, you can use run tag to run action from another action. More detailed information about how to do it is described here.


Parameters#

Every action message template has parameters variable used to get all parameters passed to this action and to store new parameters for passing them to Message Components or child actions.

Message Components have all parameters that were available for its own message template including newly stored parameters. It means that action executed by message component will get the same parameters that parent message template had.

Info

Parameters lifecycle is limited to 15 minutes from the moment when they were accessed last time!