Withdraw LP from Jediswap V1

Follow these step-by-step process to withdraw your liquidity from Jediswap V1.

1

Get all Jediswap v1 LP tokens

  • Search your wallet address in the search bar

  • Go to Portfolio

  • Look for Tokens with symbol "JEDI-P"

  • Click on Token contract address for each individual LP token

2

Get your LP balance

  • Go to the LP token page on Starkscan as described above

  • Go to Read/Write contract

  • Click on function "balanceOf(account)"

  • Input your wallet address and click query

  • Copy the value of the balance on a note, it will be used in step 4 and 5

3

Get address for token0 and token1

  • Scroll down on the same page as above and click on function "token0()"

  • Click query and copy the address on a note, it will be used to call withdraw function at end

  • Similarly scroll down again and click on function "token1()"

  • Click query and copy the address on a note, it will be used to call withdraw function at end

4

Give "Jediswap Router contract" approval to spend your Jedi-P LP token

  • Go to "Write" from top left options on the same Jedi-P LP contract

  • Connect your Starknet wallet

  • Click on "increaseAllowance" function

  • In the "spender" field, paste "0x041fd22b238fa21cfcf5dd45a8548974d8263b3a531a60388411c5e230f97023"

  • In the "added_value" field, paste the LP balance value you copied from step 2

  • Click "write" and confirm tx on your Starknet wallet

5

Remove your liquidity

  • Go to "Write Contract" on Jediswap Router Contract

  • Connect your Starknet wallet

  • Click on "remove_liquidity" function

  • Input these values in the fields

    • tokenA = token0 value you received from step 3

    • tokenB = token1 value you received from step 3

    • liquidity = LP balance value from step 2

    • amountAMin = 0

    • amountBMin = 0

    • to = [your wallet address in which you want your funds]

    • deadline = 10000000000

  • Click write and confirm the tx on your wallet

6

Done! Your funds should be in your wallet. Repeat these steps for each of your Jediswap V1 LP position.

Last updated