Actions

Your First Action

This guide creates a /hello command that greets the person who ran it. It introduces actions, tags, and variables without trying to teach every tag at once.

# Create the action

In the dashboard, open Actions, create a new action, and choose the Slash Command trigger. Set its command name to hello and save it. Atlas may need a few minutes to show the command in Discord. See Syncing if it does not appear straight away.

# Add the script

Put this in the action's script editor:

{responder.text;Hello {user.name}!}

Run /hello in your server. {user.name} is a tag: Atlas replaces it with the name of the person who ran the command. {responder.text;...} sets the reply that Atlas sends for this command.

# Store a value in a variable

Variables let you name a value and use it later. Change the script to:

{=greeting;Hello}
{responder.text;{$greeting} {user.name}!}

{=greeting;Hello} stores Hello in a variable named greeting. {$greeting} reads that value back. Variables start with $. Tags such as {user.name} do not.

# Find the next tag

The Tags documentation is the catalogue of available tags. Start with the page that matches what you want to work with, such as users, channels, or responses. Each entry lists its syntax, parameters, and any important limitations.

For a deeper explanation of tag parameters and named options, read Options and Parameters. For the information a trigger makes available to your script, see Context and Slash Command.