UNPKG

bitcoin-cli-ts

Version:

Auto-generated Bitcoin client library for bitcoind JSON-RPC API

17 lines (16 loc) 876 B
// Auto synced from github actions. Don't change this file import { __rest } from "tslib"; import request from '../../rpc-request'; /** * getblock "blockhash" ( verbosity ) * * If verbosity is 0, returns a string that is serialized, hex-encoded data for block 'hash'. * If verbosity is 1, returns an Object with information about block 'hash'. * If verbosity is 2, returns an Object with information about block <hash> and information about each transaction. * If verbosity is 3, returns an Object with information about block <hash> and information about each transaction, including prevout information for inputs (only for unpruned blocks in the current best chain). * */ export function getBlock(params) { var bitcoind = params.bitcoind, methodParams = __rest(params, ["bitcoind"]); return request({ method: 'getblock', params: methodParams }, bitcoind); }