UNPKG

@orca-so/whirlpool-sdk

Version:

Whirlpool SDK for the Orca protocol.

17 lines (16 loc) 928 B
import { u64 } from "@solana/spl-token"; import { Connection, PublicKey } from "@solana/web3.js"; import { ResolvedTokenAddressInstruction } from "./helpers"; /** * IMPORTANT: wrappedSolAmountIn should only be used for input/source token that * could be SOL. This is because when SOL is the output, it is the end * destination, and thus does not need to be wrapped with an amount. * * @param connection Solana connection class * @param ownerAddress The user's public key * @param tokenMint Token mint address * @param wrappedSolAmountIn Optional. Only use for input/source token that could be SOL * @returns */ export declare function resolveOrCreateATA(connection: Connection, ownerAddress: PublicKey, tokenMint: PublicKey, wrappedSolAmountIn?: u64): Promise<ResolvedTokenAddressInstruction>; export declare function deriveATA(ownerAddress: PublicKey, tokenMint: PublicKey): Promise<PublicKey>;