UNPKG

fbonds-core

Version:

Banx protocol sdk

17 lines (16 loc) 1.37 kB
import { Wallet, web3 } from '@coral-xyz/anchor'; declare class NodeWallet implements Wallet { readonly payer: web3.Keypair; constructor(payer: web3.Keypair); static local(): NodeWallet | never; get publicKey(): web3.PublicKey; signTransaction<T extends web3.Transaction | web3.VersionedTransaction>(tx: T): Promise<T>; signAllTransactions<T extends web3.Transaction | web3.VersionedTransaction>(txs: T[]): Promise<T[]>; } export declare const createFakeWallet: () => NodeWallet; export declare const findAssociatedTokenAddress: (walletAddress: web3.PublicKey, tokenMintAddress: web3.PublicKey) => Promise<web3.PublicKey>; export declare const findAssociatedTokenAddresSync: (walletAddress: web3.PublicKey, tokenMintAddress: web3.PublicKey) => web3.PublicKey; export declare const getTokenBalance: (pubkey: web3.PublicKey, connection: web3.Connection) => Promise<number>; export declare const createAssociatedTokenAccountInstruction: (associatedTokenAddress: web3.PublicKey, payer: web3.PublicKey, walletAddress: web3.PublicKey, splTokenMintAddress: web3.PublicKey) => web3.TransactionInstruction[]; export declare const createAssociatedTokenAccountInstructionIdimpotent: (associatedTokenAddress: web3.PublicKey, payer: web3.PublicKey, walletAddress: web3.PublicKey, splTokenMintAddress: web3.PublicKey) => web3.TransactionInstruction[]; export {};