> For the complete documentation index, see [llms.txt](https://vingt-io.gitbook.io/vingt.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://vingt-io.gitbook.io/vingt.io/technical-guide/visp-technical-foundation/contract-functions/basicissuancemodule.md).

# BasicIssuanceModule

The Basic Issuance Module is a module enables issuance and redemption functionality on a SetToken for default-only positions.&#x20;

### Select Methods <a href="#select-methods" id="select-methods"></a>

#### issue() <a href="#issue" id="issue"></a>

`function issue(ISetToken _setToken, uint256 _quantity, address _to)`Deposits the SetToken's position components into the SetToken and mints the SetToken of the given quantity to the specified \_to address. This function only handles Default Positions (positionState = 0). Components must be approved to this contract (BasicIssuanceModule) ahead of the issuance call.

| Parameter Name | Type      | Description                      |
| -------------- | --------- | -------------------------------- |
| \_setToken     | ISetToken | Instance of the SetToken         |
| \_quantity     | uint256   | Quantity of the SetToken to mint |
| \_to           | address   | Address to mint SetToken to      |

#### redeem() <a href="#redeem" id="redeem"></a>

`function redeem( ISetToken _setToken, uint256 _quantity,address _to)`Redeems the SetToken's positions and sends the components of the given quantity to the caller. This function only handles Default Positions (positionState = 0).

| Parameter Name | Type      | Description                         |
| -------------- | --------- | ----------------------------------- |
| \_setToken     | ISetToken | Address of the SetToken             |
| \_quantity     | uint256   | Quantity of the SetToken to`redeem` |
| \_to           | address   | Address to redeem components to     |

#### initialize() <a href="#initialize" id="initialize"></a>

`function initialize(ISetToken _setToken, IManagerIssuanceHook _preIssueHook)`**Manager only.** Initializes this module to the SetToken with issuance-related hooks. Only callable by the SetToken's manager. Hook addresses are optional. Address(0) means that no hook will be called

| Parameter Name | Type                 | Description                                                          |
| -------------- | -------------------- | -------------------------------------------------------------------- |
| \_setToken     | ISetToken            | Address of the SetToken                                              |
| \_preIssueHook | IManagerIssuanceHook | Instance of the Manager Contract with the Pre-Issuance Hook function |

### Select View Methods <a href="#select-view-methods" id="select-view-methods"></a>

#### getRequiredComponentUnitsForIssue() <a href="#getrequiredcomponentunitsforissue" id="getrequiredcomponentunitsforissue"></a>

`function getRequiredComponentUnitsForIssue(ISetToken _setToken, uint256 _quantity) view returns (address[] memory, uint256[] memory)`Retrieves the addresses and units required to mint a particular quantity of SetToken.

| Parameter Name | Type      | Description                         |
| -------------- | --------- | ----------------------------------- |
| \_setToken     | ISetToken | Address of the SetToken             |
| \_quantity     | uint256   | Quantity of the SetToken to`redeem` |

| Return Name         | Type       | Description                                                         |
| ------------------- | ---------- | ------------------------------------------------------------------- |
| componentAddresses  | address\[] | Address of the SetToken                                             |
| componentQuantities | uint256\[] | List of component units required to issue the quantity of SetTokens |


---

# 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://vingt-io.gitbook.io/vingt.io/technical-guide/visp-technical-foundation/contract-functions/basicissuancemodule.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.
