From 90619f2f0a11f910b7060515361c7bc4e3e8cd43 Mon Sep 17 00:00:00 2001 From: Grid Cat Date: Wed, 30 Jun 2021 18:42:44 +0200 Subject: [PATCH] feat: add getbestblockhash --- src/RPC/Network.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/RPC/Network.ts b/src/RPC/Network.ts index 0b204a2..de9e874 100644 --- a/src/RPC/Network.ts +++ b/src/RPC/Network.ts @@ -68,4 +68,14 @@ export class Network extends RPCBase { ): Promise<{ addednode: string }> { return this.call<{ addednode: string }>('getaddednodeinfo', dns, node); } + + /** + * Returns the hash of the best block in the longest block chain + * + * @returns {Promise} + * @memberof Network + */ + public async getBestBlockhash(): Promise { + return this.call('getbestblockhash'); + } }