UNPKG

@tatumio/tatum-v1

Version:

Tatum API client allows browsers and Node.js clients to interact with Tatum API.

25 lines (24 loc) 1.17 kB
import { ApproveErc20, Currency } from '../model'; /** * Approve ERC20 transfer for spender. * @param testnet chain to work with * @param body request data * @param provider optional provider to enter. if not present, Tatum Web3 will be used. * @returns {txId: string} Transaction ID of the operation, or signatureID in case of Tatum KMS */ export declare const sendApproveErc20: (testnet: boolean, body: ApproveErc20, provider?: string | undefined) => Promise<unknown>; /** * Prepare approve ERC20 signed transaction. * @param testnet if we are on testnet or not * @param body body of the approve operation * @param provider optional Web3 provider */ export declare const prepareApproveErc20: (testnet: boolean, body: ApproveErc20, provider?: string | undefined) => Promise<string>; /** * Get Decimals for the ERC20 token * @param testnet if we are using testnet or mainnet * @param chain chain to query for the token * @param contractAddress address of the token * @param provider optional provider */ export declare const getErc20Decimals: (testnet: boolean, chain: Currency, contractAddress: string, provider?: string | undefined) => Promise<any>;