# SmartBots AI Tokens

:::info
Token is a "currency" or "charge" you own, used by SmartBots AI engine.


Think of token as a short word (\~4 characters). Longer words may consume more than 1 token.

:::

## Obtaining tokens

You can fund your AI tokens balance in your account, "SmartBots AI" section. Your token balance is available to all the bots you own.

## Spending tokens

SmartBots AI engine spends tokens while processing your bot queries. The "token payment" consists of:


1. Your bot AI instructions ("Act as a support manager...") - can be short, or long depending on what you instruct
2. User message ("Hello", or "Can I get help") - usually quite short
3. The response of the bot AI ("Yes, I can help")
4. Previous user messages and bot responses (to let AI keep stay in context

You can control tokens usage at "History" page of SmartBots AI.

### Token consumption

Each request processed by AI includes:

* User message (what your visitor/customer says)
* [instructions](/doc/c68214de-69c3-41c8-ac15-83cb4d9c6bb4)
* All previous user messages (to keep a context)

For example:

**1st message from resident**

Resident: *"Hello!"*

Request to AI: "Your instructions" + "Hello"

Bot response: *"Hi!"*

**2nd message**

Resident: *"Who are you?"*

Request to AI: "Your instructions + "Hello" (1st message) + "Hi!" (1st response) + "Who are you?" (new message)

Bot response: *"I am a bot"*