# Actions

## How it works?

You can find an explanation [**here**](/overview/how-it-works.md#actions).

{% hint style="danger" %}
Be sure to have read [how to configure a character](/fundamentals/getting-set-up/configure-a-character.md) and [how to configure a behavior](/fundamentals/getting-set-up/configure-a-behavior.md) before starting here.
{% endhint %}

## List

This section lists all the types of actions that can be added to behaviors.

***

{% hint style="info" %}
Every actions support the [placeholders](/behavior/placeholders.md) which can be used anywhere there is text.
{% endhint %}

### SEND\_MESSAGE

This action allows you to send a message defined in a channel.

#### Settings

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Message</td><td>The message to send.</td><td>Text</td></tr><tr><td>Channel</td><td>The channel to send the message in.</td><td>Channel or "event channel"</td></tr></tbody></table>

***

### SEND\_EMBED\_MESSAGE

This action allows you to send a embed message defined in a channel.

#### Settings

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Title</td><td>The embed title.</td><td>Text</td></tr><tr><td>Description</td><td>The embed description.</td><td>Text</td></tr><tr><td>Footer</td><td>The embed footer.</td><td>Text</td></tr><tr><td>Image URL</td><td>The embed image.</td><td>Text (URL)</td></tr><tr><td>Color</td><td>The embed color.</td><td>Number (RGB)</td></tr><tr><td>Channel</td><td>The channel to send the message in.</td><td>Channel or "event channel"</td></tr></tbody></table>

***

### AI\_SEND\_MESSAGE

This action sends an AI-generated message into a channel.

<mark style="color:yellow;">⚠️</mark> This action consumes [ai-credits](/overview/faq.md#how-work-ai-credits). You can use [SEND\_MESSAGE](/behavior/actions.md#send_message) if you want no consumption but you will not be able to generate messages by AI.

#### Settings

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Pre-prompt</td><td>Context/Personality of the response.</td><td>Text</td></tr><tr><td>Prompt</td><td>User input.</td><td>Text</td></tr><tr><td>Message</td><td>The message to send.</td><td>Text</td></tr><tr><td>Temperature</td><td>AI temperature. Higher, more random and whimsical.</td><td>Selecting from a defined list</td></tr><tr><td>Channel</td><td>The channel to send the message in.</td><td>Channel or "event channel"</td></tr></tbody></table>

{% hint style="info" %}
In most cases, the **Prompt** setting is set to **{event\_message}** to match the message sent. Same thing for the **Message** setting which is set to **{result}** to send the generated message.
{% endhint %}

Here are some examples:

{% tabs %}
{% tab title="Pre-prompt" %}

* You're Harry Potter so answer like him.
* You're {character} so answer like him.
* You are {character} and your answers are very funny.
  {% endtab %}

{% tab title="Prompt" %}

* {event\_message}
* The message is: {event\_message}
  {% endtab %}

{% tab title="Message" %}

* {result}
* Here is my answer: {result}
  {% endtab %}
  {% endtabs %}

***

### AI\_SEND\_EMBED\_MESSAGE

This action sends an AI-generated embed message into a channel.

<mark style="color:yellow;">⚠️</mark> This action consumes [ai-credits](/overview/faq.md#how-work-ai-credits). You can use [SEND\_EMBED\_MESSAGE](#send_embed_message) if you want no consumption but you will not be able to generate messages by AI.

#### Settings

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Pre-prompt</td><td>Context/Personality of the response.</td><td>Text</td></tr><tr><td>Prompt</td><td>User input.</td><td>Text</td></tr><tr><td>Temperature</td><td>AI temperature. Higher, more random and whimsical.</td><td>Selecting from a defined list</td></tr><tr><td>Channel</td><td>The channel to send the message in.</td><td>Channel or "event channel"</td></tr><tr><td>Title</td><td>The embed title.</td><td>Text</td></tr><tr><td>Description</td><td>The embed description.</td><td>Text</td></tr><tr><td>Footer</td><td>The embed footer.</td><td>Text</td></tr><tr><td>Image URL</td><td>The embed image.</td><td>Text (URL)</td></tr><tr><td>Color</td><td>The embed color.</td><td>Number (RGB)</td></tr></tbody></table>

{% hint style="info" %}
In most cases, the **Prompt** setting is set to **{event\_message}** to match the message sent. Same thing for the **Message** setting which is set to **{result}** to send the generated message.
{% endhint %}

Here are some examples:

{% tabs %}
{% tab title="Pre-prompt" %}

* You're Harry Potter so answer like him.
* You're {character} so answer like him.
* You are {character} and your answers are very funny.
  {% endtab %}

{% tab title="Prompt" %}

* {event\_message}
* The message is: {event\_message}
  {% endtab %}

{% tab title="Message" %}

* {result}
* Here is my answer: {result}
  {% endtab %}
  {% endtabs %}

***

### AI\_RENAME\_MEMBER

This action edit the username of a member of your server; AI-generated.

<mark style="color:yellow;">⚠️</mark> This action consumes [ai-credits](/overview/faq.md#how-work-ai-credits). You can use [RENAME\_MEMBER](#rename_member) if you want no consumption but you will not be able to generate name by AI.

#### Settings

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Pre-prompt</td><td>Context/Personality of the response.</td><td>Text</td></tr><tr><td>Prompt</td><td>User input.</td><td>Text</td></tr><tr><td>New name</td><td>The new nember name.</td><td>Text</td></tr><tr><td>Temperature</td><td>AI temperature. Higher, more random and whimsical.</td><td>Selecting from a defined list</td></tr></tbody></table>

Here are some examples:

{% tabs %}
{% tab title="Pre-prompt" %}

* Your answer is a funny name from an existing name. The user input is the existing name.
  {% endtab %}

{% tab title="Prompt" %}

* {event\_member\_nickname}
  {% endtab %}
  {% endtabs %}

***

### RENAME\_MEMBER

This action allows you to rename the member associated with the triggered event.

#### Settings

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>New name</td><td>The new member name.</td><td>Text</td></tr></tbody></table>

***

### ADD\_ROLE

This action is used to give a role to the member associated with the triggered event.

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Role</td><td>The role to add.</td><td>Selecting from a defined list</td></tr></tbody></table>

***

### REMOVE\_ROLE

This action is used to remove a role to the member associated with the triggered event.

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Role</td><td>The role to remove.</td><td>Selecting from a defined list</td></tr></tbody></table>

***

### DELETE\_MESSAGE

This action is used to delete a message with a specific delay.

<table><thead><tr><th width="174">Name of setting</th><th width="314.3333333333333">Description</th><th>Type of input</th></tr></thead><tbody><tr><td>Delay</td><td>Delay in seconds.</td><td>Number</td></tr></tbody></table>

***

> 💡 An "event channel" is an additional type of option which allows action in the channel where the event was triggered. This option can obviously only be used in contexts where a channel is concerned.

{% hint style="info" %}
To understand how placeholders work, refer to [**this**](/behavior/placeholders.md#how-it-works) page.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.characterweaver.com/behavior/actions.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
