---
title: "Migrate LP position calldata"
method: POST
path: "/lp/migrate"
tags: ["Liquidity"]
---

# Migrate LP position calldata

`POST /lp/migrate`

The response will also have the transaction to migrate the position for the corresponding pool. If the parameter `simulateTransaction` is set to `true`, then the response will include the gas fees for the migrate transaction.

## Request body

- MigrateLPPositionRequest
  - `tokenId` number, required
  - `walletAddress` string, required
  - `chainId` 1 | 10 | 56 | 130 | 137 | 324 | 480 | 1868 | 8453 | 10143 | 42161 | 42220 | 43114 | 81457 | 7777777 | 1301 | 84532 | 11155111 | 143 | 196, required — The unique ID of the blockchain. For a list of supported chains see the [FAQ](https://uniswap-docs.readme.io/reference/faqs).
  - `inputProtocol` 'V2' | 'V3' | 'V4' | 'UNISWAPX' | 'UNISWAPX_V2' | 'UNISWAPX_V3', required — The protocol to use for the swap/order.
  - `inputPosition` Position, required
    - `pool` Pool, required
      - `token0` string, required
      - `token1` string, required
      - `fee` number — The fee of the pool in basis points.
      - `tickSpacing` number — The width of ticks in this pool (e.g. the price range between two ticks) specified in basis points. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
      - `hooks` string
    - `tickLower` number
    - `tickUpper` number
  - `inputPoolLiquidity` string, required — The amount of liquidity in the pool at a given tick. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `inputCurrentTick` number, required — The current tick of the pool. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `inputSqrtRatioX96` string, required — The square root of the ratio of the token0 and token1 in the pool, as a Q64.64 number. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `inputPositionLiquidity` string, required — The amount of liquidity in the pool at a given tick. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `signature` string
  - `amount0` string, required — The quantity of tokens denominated in the token's base units. (For example, for an ERC20 token one token is 1x10^18 base units. For one USDC token one token is 1x10^6 base units.) This value must be greater than 0.
  - `amount1` string, required — The quantity of tokens denominated in the token's base units. (For example, for an ERC20 token one token is 1x10^18 base units. For one USDC token one token is 1x10^6 base units.) This value must be greater than 0.
  - `outputProtocol` 'V2' | 'V3' | 'V4' | 'UNISWAPX' | 'UNISWAPX_V2' | 'UNISWAPX_V3', required — The protocol to use for the swap/order.
  - `outputPosition` Position, required
    - `pool` Pool, required
      - `token0` string, required
      - `token1` string, required
      - `fee` number — The fee of the pool in basis points.
      - `tickSpacing` number — The width of ticks in this pool (e.g. the price range between two ticks) specified in basis points. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
      - `hooks` string
    - `tickLower` number
    - `tickUpper` number
  - `initialPrice` string
  - `outputPoolLiquidity` string — The amount of liquidity in the pool at a given tick. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `outputCurrentTick` number — The current tick of the pool. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `outputSqrtRatioX96` string — The square root of the ratio of the token0 and token1 in the pool, as a Q64.64 number. For more information see the [Uniswap V3 Whitepaper](https://app.uniswap.org/whitepaper-v3.pdf).
  - `expectedTokenOwed0RawAmount` string, required
  - `expectedTokenOwed1RawAmount` string, required
  - `slippageTolerance` number — The slippage tollerace as a percentage up to a maximum of two decimal places. For Uniswap Protocols (v2, v3, v4), the slippage tolerance is the maximum amount the price can change between the time the transaction is submitted and the time it is executed. The slippage tolerance is a percentage of the total value of the swap. When submitting a quote, note that slippage tolerance works differently in UniswapX swaps where it does not set a limit on the Spread in an order. See [here](https://uniswap-docs.readme.io/reference/faqs#why-do-the-uniswapx-quotes-have-more-slippage-than-the-tolerance-i-set) for more information. Note that if the trade type is `EXACT_INPUT`, then the slippage is in terms of the output token. If the trade type is `EXACT_OUTPUT`, then the slippage is in terms of the input token. When submitting a request, `slippageTolerance` may not be set when `autoSlippage` is defined. One of `slippageTolerance` or `autoSlippage` must be defined.
  - `deadline` number — The unix timestamp at which the order will be reverted if not filled.
  - `signatureDeadline` number
  - `simulateTransaction` boolean

## Response `200`

Migrate LP Position successful.

- MigrateLPPositionResponse
  - `requestId` string — A unique ID for the request.
  - `migrate` TransactionRequest
    - `to` string, required — The wallet address which will receive the token.
    - `from` string, required — The wallet address which will be used to send the token.
    - `data` string, required — The calldata for the transaction.
    - `value` string, required — The quantity of ETH tokens approved for spending by the transaction, denominated in wei. Note that by default Uniswap Labs sets this to the maximum approvable spend.
    - `gasLimit` string — The maximum units of gas that will be consumed by this transaction.
    - `chainId` 1 | 10 | 56 | 130 | 137 | 324 | 480 | 1868 | 8453 | 10143 | 42161 | 42220 | 43114 | 81457 | 7777777 | 1301 | 84532 | 11155111 | 143 | 196, required — The unique ID of the blockchain. For a list of supported chains see the [FAQ](https://uniswap-docs.readme.io/reference/faqs).
    - `maxFeePerGas` string — The sum of the base fee and priority fee. Subtracting `maxPriorityFeePerGas` from this value will yield the base fee to be paid for this transaction.
    - `maxPriorityFeePerGas` string — The maximum tip to the block builder. Adjusted based upon the urgency specified in the request.
    - `gasPrice` string — The cost per unit of gas.
  - `gasFee` string — The total estimated gas cost of this transaction (eg. `gasLimit` multiplied by `maxFeePerGas`) in the base unit of the chain.

## Other responses

- `400` — RequestValidationError, Bad Input
- `401` — UnauthorizedError eg. Account is blocked.
- `404` — ResourceNotFound eg. Cant Find LP Position.
- `419` — Ratelimited
- `500` — Unexpected error
- `504` — Request duration limit reached.

---

[API](https://skmtc.net/uniswap/apis/token-trading.md) · [All operations](https://skmtc.net/uniswap/apis/token-trading/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/uniswap/token-trading/revisions/55533f9bd1ab/schema)
