UNPKG

@zebec-network/exchange-card-sdk

Version:
48 lines (47 loc) 1.41 kB
import { BaseTransaction, Client, SubmittableTransaction, Transaction, TxResponse } from "xrpl"; export interface XRPLWallet { address: string; signTransaction: (transaction: SubmittableTransaction | BaseTransaction) => Promise<string>; } export declare class XRPLService { readonly wallet: XRPLWallet; private apiService; readonly client: Client; constructor(wallet: XRPLWallet, options?: { sandbox?: boolean; }); /** * Fetches the Bitcoin vault address. * * @returns {Promise<{ address: string }>} A promise that resolves to the vault address. */ fetchVault(symbol?: string): Promise<{ address: string; tag?: string; }>; transferXRP(params: { walletAddress?: string; amount: string; }): Promise<TxResponse<Transaction>>; transferTokens(params: { walletAddress?: string; amount: string; token: { currency: string; issuer: string; }; }): Promise<TxResponse<Transaction>>; createTrustLine(params: { walletAddress?: string; amount: string; token: { currency: string; issuer: string; }; }): Promise<TxResponse<Transaction>>; getTokenBalances(walletAddress?: string): Promise<{ value: string; currency: string; issuer?: string | undefined; }[]>; }