UNPKG

@tatumio/tron-connector

Version:

Tron Connector for Tatum API

113 lines (112 loc) 3.34 kB
import { TronService } from './TronService'; import { BroadcastTx, CreateTronTrc10, CreateTronTrc20, FreezeTron, TransferTron, TransferTronTrc10, TransferTronTrc20 } from '@tatumio/tatum'; import { PathAddress } from './dto/PathAddress'; import { PathTxId } from './dto/PathTxId'; import { PathTokenId } from './dto/PathTokenId'; import { QueryMnemonic } from './dto/QueryMnemonic'; import { GeneratePrivateKey } from './dto/GeneratePrivateKey'; import { PathXpubI } from './dto/PathXpubI'; export declare abstract class TronController { protected readonly service: TronService; protected constructor(service: TronService); broadcast(body: BroadcastTx): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; }>; generateWallet(query: QueryMnemonic): Promise<{ mnemonic: string; } | { address: string; privateKey: string; } | { privateKey: string; address: string; } | { address: string; secret: string; } | { address: any; secret: any; }>; generatePrivKey(body: GeneratePrivateKey): Promise<{ key: string; }>; generateAccount(params: PathXpubI): Promise<{ address: any; }>; getInfo(): Promise<{ testnet: boolean; hash: string; blockNumber: number; }>; getBlock(hashOrHeight: string): Promise<import("@tatumio/tatum").TronBlock>; getAccount(path: PathAddress): Promise<import("@tatumio/tatum").TronAccount>; getTransaction(path: PathTxId): Promise<import("@tatumio/tatum").TronTransaction>; getTransactionsByAccount(path: PathAddress, next?: string): Promise<{ transactions: import("@tatumio/tatum").TronTransaction[]; internalTransactions: import("@tatumio/tatum").TronTransaction[]; next?: string; }>; getTransactions20ByAccount(path: PathAddress, next?: string): Promise<{ transactions: import("./dto/Trc20Tx").Trc20Tx[]; next?: string; }>; sendTransaction(body: TransferTron): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; } | { signatureId: string; }>; freezeBalance(body: FreezeTron): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; } | { signatureId: string; }>; getTrc10Detail(path: PathTokenId): Promise<import("@tatumio/tatum").TronTrc10>; sendTrc10Transaction(body: TransferTronTrc10): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; } | { signatureId: string; }>; createTrc10(body: CreateTronTrc10): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; } | { signatureId: string; }>; createTrc20(body: CreateTronTrc20): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; } | { signatureId: string; }>; sendTrc20Transaction(body: TransferTronTrc20): Promise<{ txId: any; failed: boolean; } | { txId: any; failed?: undefined; } | { signatureId: string; }>; }