> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mira.lgbt/llms.txt
> Use this file to discover all available pages before exploring further.

# Buttons

> Add buttons under a message or inside a container.

Buttons sit under a message, or inside a [container](/scripting/containers). Each one is a
single node, and you set it up with `key:value` pairs separated by spaces.

```text Examples theme={null}
{button: label:Click me style:primary}
{button: label:Visit Site url:https://example.com emoji:🔗}
{button: label:Rules style:secondary message:Please read #rules!}
{button: label:Coming Soon style:secondary disabled:true}
```

## Keys

| Key        | Aliases                             | Value                                       | Description                                 |
| ---------- | ----------------------------------- | ------------------------------------------- | ------------------------------------------- |
| `label`    | `lbl`, `name`, `text`, `t`          | text, up to 80 characters                   | What the button says                        |
| `style`    | `color`, `colour`, `type`, `s`, `c` | `primary`, `secondary`, `success`, `danger` | The button's colour                         |
| `url`      | `link`, `href`, `u`                 | link                                        | Turns it into a link button                 |
| `emoji`    | `icon`, `e`                         | an emoji, custom ones included              | An emoji on the button                      |
| `disabled` | `disable`, `off`, `locked`          | `true`                                      | Greys the button out so nobody can press it |
| `message`  | `msg`, `response`, `reply`          | text                                        | What gets sent back when someone presses it |

## Styles

| Style       | Looks like                    |
| ----------- | ----------------------------- |
| `primary`   | Blurple, for the main action  |
| `secondary` | Grey, for everything else     |
| `success`   | Green                         |
| `danger`    | Red, for anything destructive |

<Info>
  Adding a `url` turns the button into a link and **ignores whatever style you set**, since
  Discord always shows link buttons in grey.
</Info>

## Replies

`message` sends a reply when someone presses the button. Only the person who pressed it sees
that reply, so it's a good fit for rules, instructions, or anything you don't want cluttering
the channel.

```text theme={null}
{button: label:How do I get roles? message:Head to #roles and pick the ones you want.}
```

Placeholders work in there too.

```text theme={null}
{button: label:My stats message:You joined as member number {member.join_position}.}
```

## Inside containers

Use `{container.button: …}` instead. Everything else is the same.

```text theme={null}
{container.button: label:Open profile url:{lastfm.url}}
```
