UNPKG

meta-contract-debug

Version:

Meta Contract SDK

26 lines (25 loc) 625 B
import * as mvc from '../mvc'; import { API_NET } from '../api'; export declare enum OutputType { SENSIBLE_NFT = 0, SENSIBLE_FT = 1, P2PKH = 2, OP_RETURN = 3, UNKNOWN = 4 } declare type DecodedOutput = { type: OutputType; satoshis: number; data?: any; address?: string; }; export declare class TxDecoder { static decodeOutput(output: mvc.Transaction.Output, network: API_NET): DecodedOutput; static decodeTx(tx: mvc.Transaction, network?: API_NET): { txId: string; inputs: DecodedOutput[]; outputs: DecodedOutput[]; fee: number; }; } export {};