# Using the {math=} Token for Mathematical Calculations

#### How does it work?

Just use the token {math=} followed by the operation you want to perform. The system processes the calculation and returns the result automatically.

**Examples:**

* `{math=1 + 1}` → 2
* `{math=(10 + 30) * 2}` → 80
* `{math={contactfield=id} * 2}` → returns the lead's ID field value multiplied by 2

#### Available operators:

You can use the main mathematical operators:

* Addition: +
* Subtraction: -
* Multiplication: \*
* Division: /
* Use of parentheses for precedence: ()<br>

Be careful with decimal numbers

The system does not recognize commas in numbers. Always use a dot (.) as the decimal separator.

**Incorrect example:**

`{math=1.000,32 + 10}` → Error

**Correct example:**\
\
`{math=1000.32 + 10}` → 1010.32

#### Where to use

This token is useful in various contexts, such as:

* Automatic calculations with lead data
* Dynamic messages with personalized values
* Automations of conditional logic based on numbers

#### Conclusion

With the {math=} token you have more flexibility and intelligence in your automations. Try different formulas and make your communications even more precise and automated!

<br>


---

# 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/strategies/tokens/using-the-math-token-for-mathematical-calculations.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.
