# PlusPool Factory

This contract creates PlusPools and manages the state of each PlusPool.

## Events, Read-Only Functions, and State-Changing Functions

{% tabs %}
{% tab title="Events" %}

## Events

**CreatePool**

```solidity
event CreatePool(address token0, address token1, address lpToken, uint borrowFactor, uint liquidationFactor, bool borrowable0, bool borrowable1, address poolAddress, uint exid);
```

* Event to create new PlusPool
* Parameters
  * `token0` : token0 address in LP
  * `token1` : token1 address in LP
  * `lpToken` : address in LP
  * `borrowFactor` : Utilization cost interest rate of utilized assets
  * `liquidationFactor` : automatic return factor
  * `borrowable0` : Whether token0 can be borrowable
  * `borrowable1` : Whether token1 can be borrowable
  * `poolAddress` : PlusPool contract address of this pool
  * `exid` : PlusPool id

**SetDepositActive**

```solidity
event SetDepositActive(address plusPoolAddress, bool b);
```

* Event that occurs when PlusPool deposit availability is changed

**SetWithdrawActive**

```solidity
event SetWithdrawActive(address plusPoolAddress, bool b);
```

* Event that occurs when PlusPool withdrawal availability is changed
  {% endtab %}
  {% endtabs %}


---

# 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.meshswap.fi/developers/contract/pluspool-factory.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.
