> For the complete documentation index, see [llms.txt](https://docs.saddle.finance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.saddle.finance/solidity-docs/helper/genericerc20.md).

# GenericERC20

This contract simulates a generic ERC20 token that is mintable and burnable.

## Functions:

* [`constructor(string name_, string symbol_, uint8 decimals_)`](#GenericERC20-constructor-string-string-uint8-)
* [`mint(address recipient, uint256 amount)`](#GenericERC20-mint-address-uint256-)

## Function `constructor(string name_, string symbol_, uint8 decimals_)` <a href="#genericerc20-constructor-string-string-uint8" id="genericerc20-constructor-string-string-uint8"></a>

Deploy this contract with given name, symbol, and decimals

the caller of this constructor will become the owner of this contract

### Parameters:

* `name_`: name of this token
* `symbol_`: symbol of this token
* `decimals_`: number of decimals this token will be based on

## Function `mint(address recipient, uint256 amount)` <a href="#genericerc20-mint-address-uint256" id="genericerc20-mint-address-uint256"></a>

Mints given amount of tokens to recipient

only owner can call this mint function

### Parameters:

* `recipient`: address of account to receive the tokens
* `amount`: amount of tokens to mint


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.saddle.finance/solidity-docs/helper/genericerc20.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
