> For the complete documentation index, see [llms.txt](https://docs.pancakeswap.finance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.pancakeswap.finance/chinese/gei-kai-fa-zhe-men/zhi-neng-he-yue-evm/market-maker-pool.md).

# Market Maker Pool

## Contract info

**Contract name: MM Pool**

**BSC**

**Contract address:** [0xfEACb05b373f1A08E68235bA7FC92636b92ced01](https://bscscan.com/address/0xfEACb05b373f1A08E68235bA7FC92636b92ced01#code)

[View on BscScan](https://bscscan.com/address/0xfEACb05b373f1A08E68235bA7FC92636b92ced01)

**ETH**

**Contract address:** [0x9Ca2A439810524250E543BA8fB6E88578aF242BC](https://etherscan.io/address/0x9Ca2A439810524250E543BA8fB6E88578aF242BC#code)

[View on Etherscan](https://etherscan.io/address/0x9Ca2A439810524250E543BA8fB6E88578aF242BC)

### Example of Swapping

#### EIP 712 Signature

```
const domain = {
  name: "PCS MM Pool",
  version: "1",
  chainId: // 1 or 56,
  verifyingContract: // please refer to the address above,
};

const quoteType = {
  Quote: [
    { name: "nonce", type: "uint256" },
    { name: "user", type: "address" },
    { name: "baseToken", type: "address" },
    { name: "quoteToken", type: "address" },
    { name: "baseTokenAmount", type: "uint256" },
    { name: "quoteTokenAmount", type: "uint256" },
    { name: "expiryTimestamp", type: "uint256" },
  ],
};

const quoteValue = {
    nonce,
    user,
    baseToken,
    quoteToken,
    baseTokenAmount,
    quoteTokenAmount,
    expiryTimestamp,
};

// EIP 712 Signature
const signature = await mm._signTypedData(domain, quoteType, quoteValue);
```

<table><thead><tr><th width="214">Name</th><th width="123.33333333333331">Type</th><th>Description</th></tr></thead><tbody><tr><td>nonce</td><td>uint256</td><td>The user nonce can be called from <code>getUserNonce</code> in the contract</td></tr><tr><td>user</td><td>address</td><td>user address</td></tr><tr><td>baseToken</td><td>address</td><td>The token address that the user is sending to the market maker</td></tr><tr><td>quoteToken</td><td>address</td><td>The token address that the user is receiving from the market maker</td></tr><tr><td>baseTokenAmount</td><td>uint256</td><td>The amount of base token in the swap</td></tr><tr><td>quoteTokenAmount</td><td>uint256</td><td>The amount of quote token in the swap</td></tr><tr><td>expiryTimestamp</td><td>uin256</td><td>The expiry time of the signature in unix</td></tr></tbody></table>

#### swap

```
struct Quote {
    uint256 nonce;
    address user;
    address baseToken;
    address quoteToken;
    uint256 baseTokenAmount;
    uint256 quoteTokenAmount;
    uint256 expiryTimestamp;
}

function swap(
        address _mmSigner,
        Quote calldata _quote,
        bytes calldata _signature
    ) external payable
```

| Name        | Type    | Description                        |
| ----------- | ------- | ---------------------------------- |
| \_mmSigner  | address | The market maker address           |
| \_quote     | Quote   | The Quote struct                   |
| \_signature | bytes   | The signature generated from above |


---

# 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.pancakeswap.finance/chinese/gei-kai-fa-zhe-men/zhi-neng-he-yue-evm/market-maker-pool.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.
