# Solana Burn Tokens Tool

#### Solana Burn Token Tool (`solana_burn_token_tool`)

Performs an **on-chain transaction** to **permanently burn (destroy)** a specified amount of an SPL token from the agent's (user's) wallet, removing them from circulation forever. **This action is irreversible.**

{% hint style="info" %}
**Inputs:** Requires owner's wallet, token details, and amount to burn.
{% endhint %}

```
class SolanaBurnTokenInput(BaseModel):
    agent_public: str      # Owner's public key
    agent_private: str     # Owner's ENCRYPTED private key
    token_address: str     # SPL token mint address to burn
    amount: float          # Amount of the token to burn
```

***

**Key Functionality:**

* Securely decrypts the owner's private key.
* Validates the amount and checks the owner's balance for the specified SPL token.
* Constructs and sends a versioned transaction to the Solana network to execute the burn instruction.
* Returns a confirmation with the transaction signature and an explorer link upon success.

***

**Sample Usage Queries (How an AI might use it):** *(These imply the agent has access to or will securely prompt for necessary wallet details, and can use a token identification tool to get `token_address` if a name like "USDC" or "LUMO" is given.)*

* "Burn 100 of my unwanted tokens with mint address `TokenMintAddressHere`."
* "I want to destroy 50 of my FARTCOIN tokens."
* "Help me burn `AmountX` of `TOKEN_SYMBOL` from my wallet."
* "Initiate a token burn for `N` units of LUMO."
* "Execute a transaction: burn `0.5` of GOAT tokens."
* "Permanently remove `Z` amount of token `SomeMintAddress` from my holdings."

***

**Quick Code Glance:**

```python
class SolanaBurnTokenTool(BaseTool):
    name: ClassVar[str] = "solana_burn_token_tool"
    description: ClassVar[str] = "Burn SPL tokens from agent wallet, permanently removing them from circulation."
    args_schema: ClassVar[Type[BaseModel]] = SolanaBurnTokenInput
```

***

**⚠️ CRITICAL INFORMATION / WARNING:**

* **Permanent & Irreversible:** Burning tokens permanently removes them from circulation. **This action cannot be undone.** Double-check all details before proceeding.
* **Encrypted Private Key:** Requires the agent's **encrypted** private key. The security of the encryption/decryption mechanism is vital.
* **Token & Wallet Addresses:** Ensure correct SPL token mint address and owner wallet details are used.
* **Network Dependent:** Relies on a connection to a Solana RPC node (`CONFIG.SOLANA_RPC_URL`).
* **Asynchronous:** Primarily designed for asynchronous execution (`_arun`).


---

# 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://www.lumolabs.ai/tools/solana-burn-tokens-tool.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.
