infoblock
Version:
A typed wrapper of the blockchain.info API
17 lines (16 loc) • 622 B
TypeScript
import { Block } from './Block';
import Transaction from "./Transaction";
import { Satoshi, Hash } from './types';
export default class {
private client;
getBlock(hash: string): Promise<Block>;
getLatestBlock(): Promise<Block>;
getBlockByHeight(height: number): Promise<Block>;
getTransaction(hash: string): Promise<Transaction>;
getUnconfirmedTransactions(): Promise<Transaction[]>;
getBalance(address: string): Promise<Satoshi>;
getDifficulty(): Promise<number>;
getBlockCount(): Promise<number>;
getLatestHash(): Promise<Hash>;
getAddressInfo(address: Hash): Promise<any>;
}