Withdraw from farm
withdraw lp tokens is a command that enables you to withdraw Liquidity Provider (LP) tokens from a yield farm.
Yield farming is a method of earning more cryptocurrency using existing cryptocurrency. When you participate in yield farming, you provide liquidity by adding assets to a liquidity pool. The pool then provides you with LP tokens, representing your share in the pool.
Parameters
Farm: The yield farm from which you wish to withdraw your LP tokens.
Amount: The amount of LP tokens that you wish to withdraw from the yield farm.
Transaction Info Variable: (Optional, advanced) The variable name where the transaction information will be stored. The default value is '#txinfo'.
Example
withdraw lp tokens("SushiSwap", "10")
In the script example above, the 'withdraw lp tokens' command withdraws 10 LP tokens from the specified yield farm on the SushiSwap network.
Post-Run
After running this command, RecordTxData is executed to record transaction data.
- Please note:**
Before withdrawing LP tokens, ensure you have the required number of LP tokens in the yield farm, and you have enough balance of native token (for transaction fees). It's advised to only farm on platforms you trust with funds you can afford to risk, as DeFi involves potential risks.