SwapParams: SwapInput & {
    oracle: PublicKey;
    tokenAuthority: PublicKey;
    tokenOwnerAccountA: PublicKey;
    tokenOwnerAccountB: PublicKey;
    tokenVaultA: PublicKey;
    tokenVaultB: PublicKey;
    whirlpool: PublicKey;
}

Raw parameters and accounts to swap on a Whirlpool

Type declaration

  • oracle: PublicKey
  • tokenAuthority: PublicKey
  • tokenOwnerAccountA: PublicKey
  • tokenOwnerAccountB: PublicKey
  • tokenVaultA: PublicKey
  • tokenVaultB: PublicKey
  • whirlpool: PublicKey

Param: swapInput

Parameters in SwapInput

Param: whirlpool

PublicKey for the whirlpool that the swap will occur on

Param: tokenOwnerAccountA

PublicKey for the associated token account for tokenA in the collection wallet

Param: tokenOwnerAccountB

PublicKey for the associated token account for tokenB in the collection wallet

Param: tokenVaultA

PublicKey for the tokenA vault for this whirlpool.

Param: tokenVaultB

PublicKey for the tokenB vault for this whirlpool.

Param: oracle

PublicKey for the oracle account for this Whirlpool.

Param: tokenAuthority

authority to withdraw tokens from the input token account

Generated using TypeDoc