{"id":48000,"library":"grpc-bchrpc","title":"grpc-bchrpc","description":"A common interface for grpc-bchrpc-node and grpc-bchrpc-web npm packages, enabling gRPC communication with Bitcoin Cash nodes. Current version 0.3.0, with irregular releases. Key differentiator: abstracts over Node.js and web environments for BCH gRPC.","status":"active","version":"0.3.0","language":"javascript","source_language":"en","source_url":"https://github.com/simpleledgerinc/grpc-bchrpc","tags":["javascript"],"install":[{"cmd":"npm install grpc-bchrpc","lang":"bash","label":"npm"},{"cmd":"yarn add grpc-bchrpc","lang":"bash","label":"yarn"},{"cmd":"pnpm add grpc-bchrpc","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"Default export; ESM and CJS support depends on underlying packages.","wrong":"const BCH = require('grpc-bchrpc')","symbol":"BCH","correct":"import BCH from 'grpc-bchrpc'"},{"note":"Named export for web variant.","wrong":"import BCHWeb from 'grpc-bchrpc'","symbol":"BCHWeb","correct":"import { BCHWeb } from 'grpc-bchrpc'"},{"note":"Named export for Node.js variant.","wrong":"import BCHNode from 'grpc-bchrpc'","symbol":"BCHNode","correct":"import { BCHNode } from 'grpc-bchrpc'"}],"quickstart":{"code":"import BCH from 'grpc-bchrpc';\n\nconst client = new BCH('https://bchd.fountainhead.cash:8335', { grpc: require('@grpc/grpc-js') });\n\nasync function main() {\n  const info = await client.getBlockchainInfo();\n  console.log('Blockchain info:', info);\n}\n\nmain().catch(console.error);","lang":"typescript","description":"Shows how to create a client and fetch blockchain info using gRPC."},"warnings":[{"fix":"Add one of the underlying packages to your dependencies.","message":"Package is essentially an alias - ensures you install grpc-bchrpc-node or grpc-bchrpc-web separately.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"npm install --save-dev @types/grpc__grpc-js","message":"No built-in TypeScript types; you may need to install @types/grpc__grpc-js.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Set up a gRPC-web proxy if targeting browsers.","message":"gRPC web may require a proxy like Envoy; not suitable for direct browser usage without additional configuration.","severity":"deprecated","affected_versions":">=0.0.0"}],"env_vars":null,"search_vec":"'0.3.0':28 'abstract':34 'bch':41 'bchrpc':3,10,15 'bitcoin':23 'cash':24 'common':5 'communic':21 'current':26 'differenti':33 'enabl':19 'environ':39 'grpc':2,9,14,20,42 'grpc-bchrpc':1 'grpc-bchrpc-node':8 'grpc-bchrpc-web':13 'interfac':6 'irregular':30 'javascript':43 'key':32 'node':11,25 'node.js':36 'npm':17 'packag':18 'releas':31 'version':27 'web':16,38","created_at":"2026-06-07T16:54:24.992014+00:00","updated_at":"2026-06-07T16:54:24.992014+00:00","problems":[{"fix":"npm install grpc-bchrpc-node","cause":"Missing underlying package.","error":"Error: Cannot find module 'grpc-bchrpc-node'"},{"fix":"Use import BCH from 'grpc-bchrpc'","cause":"Incorrect import or missing default export.","error":"TypeError: BCH is not a constructor"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/simpleledgerinc/grpc-bchrpc#readme","github":"https://github.com/simpleledgerinc/grpc-bchrpc","docs":null,"changelog":null,"pypi":null,"npm":"grpc-bchrpc","openapi_spec":null,"status_page":null,"smithery":null,"categories":["devops"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-07","next_check":"2026-09-05","install_tag":null}}