# Macros

## Macros list

**Macro** - a set of sequential saved actions that run in a dialog and help agents speed up customer service (e.g. assign a tag to a conversation, assign a team, update a custom attribute). With a macro, you can execute all these actions with a single click.&#x20;

When agents run a macro, the actions are executed in the defined sequence.

<figure><img src="https://2498134934-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5yF7NRiGknx3Bqj4OgYA%2Fuploads%2FN1MwXnc4l9fC1n4AUyMd%2F3.PNG?alt=media&#x26;token=c4ec79ea-b8c2-4742-90d7-a0024fa82d99" alt=""><figcaption></figcaption></figure>

To create a new macro/edit an existing one, select **Add a New Macro/Edit Macro.**

***

## **Create/Edit a Macro**

<figure><img src="https://2498134934-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5yF7NRiGknx3Bqj4OgYA%2Fuploads%2FH5TfkfoIcVrWQIESjVdb%2Fimage.png?alt=media&#x26;token=7d1469cd-c71e-41bc-8969-6142b92abcfd" alt=""><figcaption></figcaption></figure>

1. **Macro name**
2. **Library** - a folder that contains a Macro. It is used to organize Macros.
3. **Macro Visibility** **-** availability of a macro for other users:

* Private – only a user who created it has access to a macro.
* Public – available publicly for all users in this account.

{% hint style="info" %}
Public macros can only be created by Administrators.
{% endhint %}

{% hint style="info" %}
Private library can only create a Private Macro.
{% endhint %}

3. **Action** - specifies actions to be performed when the macro is run. Possible actions:

* Assign a team&#x20;
* Assign an agent&#x20;
* Assign a label
* Remove a label
* Remove Assigned Team&#x20;
* Resolve conversation
* Send a message&#x20;
* Send Attachment&#x20;
* Add to:

Private Note - a private note of a conversation in which a macro was run (with sending to the conversation).

Reply section - the Reply section of a conversation in which a macro was run (without sending it to the conversation).

Dialogue note - a dialogue note (with saving to a note), within which the macro was run

Conversation Custom Attributes (text only)

Contact Custom Attributes (text only)

* Add a private note&#x20;
* Send Custom Event (usually used to call a custom NovaTalks script. For instance, the system is set up with a scenario for a chatbot to collect a phone number. You can use a macro to run this scenario. As part of the request, you can specify which parameter values to pass through the  Key/Value fields)&#x20;
* Send Webhook Event (usually used to transfer data to third systems. As part of the request, you can specify which parameter values to pass through the Key/Value fields)&#x20;
* Send Browser Event (used to send data to Dashboard Apps. As part of the request, you can specify which parameter values to pass through the Key/Value fields)&#x20;

You can add multiple actions in sequence. When you run a macro, its actions execute in the order specified in the settings. You can reorder the actions by dragging the handle next to each node.

***

## Library

### Library list

<figure><img src="https://2498134934-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5yF7NRiGknx3Bqj4OgYA%2Fuploads%2FNDcvWEwn1olo3h4wHuXR%2FCapture.PNG?alt=media&#x26;token=021f5948-7556-4013-8b5b-4b1cad12f93b" alt=""><figcaption></figcaption></figure>

**A library** is a folder used to organise macros and make them easier to find. Libraries can also be used to hide unnecessary macros that are included in them or to manage access rights - private or public.&#x20;

The Library List page displays their settings and the option to hide/show Macros that are included in the Library when communicating with clients.

***

### Create/Edit Library

<figure><img src="https://2498134934-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5yF7NRiGknx3Bqj4OgYA%2Fuploads%2FRjyoGkvws1lVr26FfP7b%2F2.PNG?alt=media&#x26;token=1ddf5a25-96bc-4a05-91fd-65df9337656d" alt=""><figcaption></figcaption></figure>

1. Library name&#x20;
2. Visibility - the accessibility of the library to other users. It can be:&#x20;

* Private - only the user who created it has access to the library;&#x20;
* Public - available to all users of the account.

{% hint style="info" %}
Public Libraries can only be created by Administrators.
{% 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://help.novatalks.com.ua/en/get-started/settings/macros.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.
