- Notifications
You must be signed in to change notification settings - Fork0
bch.js - Bitcoin Cash JavaScript API
License
NotificationsYou must be signed in to change notification settings
panda-suite/bchjs
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
bch.js
is a lightweight wrapper around a Bitcoin Cash Node RPC. This allows you to easily create tooling around any Bitcoin Cash Node functionality. It uses anHttpProvider
API similar to the one used by Ethereum'sweb3.js
, so any developer familiar with Ethereum will feel right at home.
npm install bchjs
const{BCH, HttpProvider}=require('bchjs');consthttpBlockchainProvider=newHttpProvider('http://localhost:48332','regtest','regtest');consthttpWalletProvider=newHttpProvider('http://localhost:48332','regtest','regtest');constbch=newBCH(httpBlockchainProvider,httpWalletProvider);awaitbch.rpc.getblockchaininfo();
bch.js
can be added to your application or tests. It can be configured to connect to any node. You can usepandacash-core
local blockchain for local development and testing.
constpanda=require("pandacash-core");const{BCH, HttpProvider}=require('bchjs');constserver=awaitpanda.server().listen({port:48332,walletPort:48333});constbch=newBCH(newHttpProvider('http://localhost:48332'),newHttpProvider('http://localhost:48333'));awaitbch.rpc.getblockchaininfo();
All rpc methods have been added.
About
bch.js - Bitcoin Cash JavaScript API
Topics
Resources
License
Stars
Watchers
Forks
Packages0
No packages published