# Burn Position (remove liquidity)

This is an example of withdrawing all or part of an asset from an existing position in Pangea's pool.

```typescript
import { ethers } from "ethers";
import {BigNumber} from "@ethersproject/bignumber";

/// concentrated Liquidity Pool Manager address
const poolManagerAddress = "0x000...";

/// web3 Provider (metamask provider / jsonRPC provider / ...)
const provider = ethers.getDefaultProvider();

// burn position
async function burnPosition(
    tokenId:number,  // tokenId
    amount:string,   // amount of liquidity to burn
    recipient:string // recipient address
) {
      const poolManager = await ConcentratedLiquidityPoolManager__factory.connect(positionManagerAddress, provider);
      const tx = await poolManager.burn(
            tokenId, // position ID to remove liquidity from. will burn if all liquidity is removed
            amount, // amount of liquidity to burn. You can get position liquidity size through poolManager.positions(tokenId).
            recipient,
            0, // token0 slippage limit. if removed token0 is less, revert
            0, // token1 slippage limit. if removed token1 is less, revert
            false // Unwrap? "true" if you want to get KLAY instead of wKLAY
      );
      await tx.wait();
}
```


---

# 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://pangeaswap.gitbook.io/pangeaswap/en/developers/interacting-with-the-protocol/burn-position-remove-liquidity.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.
