UNPKG

@marinade.finance/kamino-sdk

Version:
14 lines (13 loc) 1.34 kB
import { Connection, PublicKey, Transaction, TransactionInstruction } from '@solana/web3.js'; import Decimal from 'decimal.js'; import { CreateAta } from './types'; export declare const MAX_ACCOUNTS_PER_TRANSACTION = 64; export declare const decodeSerializedTransaction: (tx: string | undefined) => Transaction | undefined; export declare const getComputeBudgetAndPriorityFeeIxns: (units: number, priorityFeeLamports?: Decimal) => TransactionInstruction[]; export declare const createAtaIfMissingIx: (connection: Connection, mint: PublicKey, owner: PublicKey) => Promise<TransactionInstruction | undefined>; export declare const getAtasWithCreateIxnsIfMissing: (connection: Connection, mints: PublicKey[], owner: PublicKey) => Promise<TransactionInstruction[]>; export declare const createWsolAtaIfMissing: (connection: Connection, amount: Decimal, owner: PublicKey, method?: 'deposit' | 'withdraw') => Promise<CreateAta>; export declare const isWsolInfoInvalid: (wsolAtaAccountInfo: any) => boolean; export declare function checkIfAccountExists(connection: Connection, account: PublicKey): Promise<boolean>; export declare function removeBudgetAndAtaIxns(ixns: TransactionInstruction[], mints: string[]): TransactionInstruction[]; export declare const findAtaBalance: (connection: Connection, ata: PublicKey) => Promise<number | null>;