TheDocumentation Index
Fetch the complete documentation index at: https://v2-docs.exponent.finance/llms.txt
Use this file to discover all available pages before exploring further.
ixMergeToBase method on the Vault class creates transaction instructions that merge PT and YT back into SY and then unwrap the SY into the base asset in a single atomic operation.
Usage
Required Parameters
| Parameter | Type | Description |
|---|---|---|
owner | PublicKey | The owner’s wallet public key |
amountPy | bigint | Amount of PT and YT to merge |
Optional Parameters
| Parameter | Type | Description |
|---|---|---|
ptSrc | PublicKey | Source PT token account. Defaults to owner’s ATA |
ytSrc | PublicKey | Source YT token account. Defaults to owner’s ATA |
syDst | PublicKey | Intermediate SY token account. Defaults to owner’s ATA |
baseDst | PublicKey | Destination base token account |
Returns
Returns aPromise<{ ixs: TransactionInstruction[]; setupIxs: TransactionInstruction[] }>:
ixs— The merge and unwrap instructions, including any flavor-specific pre/post instructionssetupIxs— Setup instructions that create associated token accounts for SY, PT, and YT