# Email Marketing - Use of Tokens

In this example, imagine you want leads to submit a form and receive a personalized marketing email with their name.&#x20;

Adding Tokens **can be done both in templates and in emails created** **through the builder** of SprintHub.&#x20;

To do this, follow this tutorial:&#x20;

* Before we begin, you need to create a form, [**to learn how to create forms in SprintHub click here**](https://docs.sprinthub.com/topicos/converter/formularios/formularios-configuracoes-iniciais/formularios-criacao-de-formularios)

1 - In the main menu, click on **'Relate'** and then on **'Emails'**;

<figure><img src="/files/9c13b7591a88a561c471e0bd5a1555195c1c2aa3" alt=""><figcaption></figcaption></figure>

**2 -** Click +New to create a new email template or click Edit to edit an existing template; \
Add a Name, leave Published to make the email available, and click Open Builder.

<figure><img src="/files/7f08d7deda805f79ffd3c2caa4334a54211415e3" alt=""><figcaption></figcaption></figure>

&#x20;**3 - In Dynamics,** click and drag Dynamic Text to where you want to position your text. Double-click to access the text editing area.

<figure><img src="/files/042e5e9367939418d7da058e39953ab627d00140" alt=""><figcaption></figcaption></figure>

**4 - To add the token,** click the + symbol and choose "(Lead) Name", the token will be added alongside the text.&#x20;

{% hint style="info" %}
You can choose any other field that the lead previously filled out in the form.
{% endhint %}

After finishing, click the arrow to exit, then Close, and Save and Close.

<figure><img src="/files/a53c06cfca107a5704d9601af06a0b5e240b97e3" alt=""><figcaption></figcaption></figure>

* The next step will be creating the Automation Flow that will trigger the marketing email to the leads who completed the form

1 - In the main menu, click on **'Relate**' and then in **'Automation Flows'**;

2 - Click on **New** to create a **new Automation Flow**

3 - Define a Name and click **Open Builder and** **add an action to Send Email to the lead**

<figure><img src="/files/fa6cb6fadeba62a0eb74699056608968a21f22c7" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
Include the email template previously created with the builder in the action block within the Flow. The email type must be <mark style="color:red;">**necessarily Marketing Email, otherwise the token will not work.**</mark>
{% endhint %}

* Finally, let's configure the form actions, [to learn more about Form Actions, click here](https://docs.sprinthub.com/topicos/converter/formularios/formularios-configuracoes-iniciais/formularios-criando-acoes)

1 - In the main menu, click on **'Convert**' and then in **'Forms**'

2 - Click on **Edit**

3 - Click on **Actions** and then **New Action**

4 - Select **Change automation flows and p**lace in the field the **automation responsible for sending the marketing email to the lead, click** Save and Close.

<figure><img src="/files/71243bc2a848df7738b6473240eb5f069ee18298" alt=""><figcaption></figcaption></figure>

This way, it will be possible to automatically send personalized emails with the name of the lead who filled out a form.


---

# 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.sprinthub.com/en/topics/relate/email/email-marketing-use-of-tokens.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.
