UNPKG

@vafanassieff/bitcoin-cli-ts

Version:

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

21 lines (17 loc) 515 B
// Auto synced from github actions. Don't change this file import { Bitcoind } from '../../types.js' import request from '../../rpc-request.js' type GetBlockCountParams = { bitcoind: Bitcoind } /** * getblockcount * * Returns the height of the most-work fully-validated chain. * The genesis block has height 0. * */ export function getBlockCount(params: GetBlockCountParams) { const { bitcoind, ...methodParams } = params return request({ method: 'getblockcount', params: methodParams }, bitcoind) }