{"name":"bitcore-p2p","version":"8.3.3","keywords":["bitcoin","bitcore"],"license":"MIT","_id":"bitcore-p2p@8.3.3","homepage":"https://github.com/bitpay/bitcore-p2p#readme","bugs":{"url":"https://github.com/bitpay/bitcore-p2p/issues"},"dist":{"shasum":"6078625a680e8598ba3eb18d2d1dd291c6ac4599","tarball":"http://registry-npm.ywwl.com/bitcore-p2p/download/bitcore-p2p-8.3.3.tgz","fileCount":62,"integrity":"sha512-YeF1Hve8t9WkYkKuTOx6xMwwj1caYYRd8SzLL4MrZCUmJtUwkBA+1M9BM8CSV6yoeA/53CV17faz77hC1KFsYQ==","signatures":[{"sig":"MEUCIDdGdLki3yLSwk1g9x9qYJdy5D9dskv7+9nh4ZCBbJQjAiEAm4UpeDThoTjrm3scnkoRih5Z+jompRlnlk0KtIH0TOY=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":586407,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJc6DqKCRA9TVsSAnZWagAA/MAP/2do20PEoIPzMLf16VR3\nwY2X8QW7IFUUnZNzUWBRPdEwajAUvNZ/fvw3XQNbAYfNLK4vKAOUE88YOwt3\nH20xaAQtjKR44UO3LX+73f9ygjaoD+8E81EL4VTAV75Uo+VZSDZUVPFVe8Ek\ndTr1BRZG3ePDBeGNFxiQBkYV3CyIL/ZE+8TUZpVTx2qGustuQfbd4lu33+xW\ndVxl+njHzjpxxinGMBp3jyhszIjA47HW8cYxk8ICpSizCUZuKL7MoI6J/L+A\ntSOOSD0lU4rBGoiOg5RgtjNy2OksmV1zRASfH81KGMSixDaYSVFzByEjR13v\nBFdK+2MFqRFEHs/zgirJq3lQ5lD2KmUBGqihTGmRS2qgruzhu/10XHSzmkSa\nyWAbirYBGBfsyhcGbBY5wY6l9nDPRVVN8E4LgqZBxANkueIniTmaWQ+Hwhgf\n2oNcXE2h8Uf2TpxDPFlwyhDDSif709VMV7G7zG3SPS6CfG8uT4SmKDKQD6ZK\np8f7XTdKltCSsZ6y9iGa/orMrETCsTvcrU/KpM9zc0DHtIOs+YxDQzhV70G+\nAOLhGWoxdU0Nk/M7n/qEaRBq9vZyJ1rEUMZxC/Jkvie18DUJTqyubns43CJg\nErXtoe8y5MoK/gy8KZ18EdF4L+YTaZHsOosLaPDWJ73GY2bILP9bRmwUgyXh\nEV54\r\n=E+sQ\r\n-----END PGP SIGNATURE-----\r\n","size":204764,"noattachment":false,"key":"/bitcore-p2p/-/bitcore-p2p-8.3.3.tgz"},"main":"index.js","_from":"file:bitcore-p2p-8.3.3.tgz","gitHead":"012cc0216a9bc6b195035855bd17149bad41acd1","scripts":{"lint":"gulp lint","test":"gulp test","build":"gulp","test:ci":"npm run test","coverage":"gulp coverage"},"_npmUser":{"name":"ematiu","email":"ematiu@gmail.com"},"_resolved":"","_integrity":"","repository":{"url":"git+https://github.com/bitpay/bitcore-p2p.git","type":"git"},"_npmVersion":"6.4.1","description":"Interface to the bitcoin P2P network for bitcore","directories":{},"_nodeVersion":"10.15.3","dependencies":{"bcoin":"1.0.0-beta.12","buffers":"github:bitpay/node-buffers#v0.1.2-bitpay","bitcore-lib":"^8.3.3","bloom-filter":"^0.2.0","socks5-client":"^0.3.6"},"_hasShrinkwrap":false,"devDependencies":{"brfs":"^1.2.0","chai":"~1.10.0","gulp":"^4.0.0","sinon":"^1.12.2","bitcore-build":"^8.3.3"},"_npmOperationalInternal":{"tmp":"tmp/bitcore-p2p_8.3.3_1558723209300_0.19386093502760593","host":"s3://npm-registry-packages"},"readme":"# Bitcore P2P\n\n[![NPM Package](https://img.shields.io/npm/v/bitcore-p2p.svg?style=flat-square)](https://www.npmjs.org/package/bitcore-p2p)\n[![Build Status](https://img.shields.io/travis/bitpay/bitcore-p2p.svg?branch=master&style=flat-square)](https://travis-ci.org/bitpay/bitcore-p2p)\n[![Coverage Status](https://img.shields.io/coveralls/bitpay/bitcore-p2p.svg?style=flat-square)](https://coveralls.io/r/bitpay/bitcore-p2p?branch=master)\n\n**The peer-to-peer networking protocol for BTC.**\n\n`bitcore-p2p` adds [Bitcoin protocol](https://en.bitcoin.it/wiki/Protocol_documentation) support for Bitcore.\n\nSee [the main bitcore repo](https://github.com/bitpay/bitcore) for more information.\n\n## Getting Started\n\n```sh\nnpm install bitcore-p2p\n```\n\nIn order to connect to the Bitcoin network, you'll need to know the IP address of at least one node of the network, or use [Pool](./docs/pool.md) to discover peers using a DNS seed.\n\n```javascript\nvar Peer = require('bitcore-p2p').Peer;\n\nvar peer = new Peer({host: '127.0.0.1'});\n\npeer.on('ready', function() {\n  // peer info\n  console.log(peer.version, peer.subversion, peer.bestHeight);\n});\npeer.on('disconnect', function() {\n  console.log('connection closed');\n});\npeer.connect();\n```\n\nThen, you can get information from other peers by using:\n\n```javascript\n// handle events\npeer.on('inv', function(message) {\n  // message.inventory[]\n});\npeer.on('tx', function(message) {\n  // message.transaction\n});\n```\n\nTake a look at this [guide](./docs/peer.md) on the usage of the `Peer` class.\n\n## Contributing\n\nSee [CONTRIBUTING.md](https://github.com/bitpay/bitcore/blob/master/CONTRIBUTING.md) on the main bitcore repo for information about how to contribute.\n\n## License\n\nCode released under [the MIT license](https://github.com/bitpay/bitcore/blob/master/LICENSE).\n\nCopyright 2013-2019 BitPay, Inc. Bitcore is a trademark maintained by BitPay, Inc.\n","publish_time":1558723209734,"maintainers":[{"name":"gasteve","email":"stephen@pairhome.net"},{"name":"nitsujlangston","email":"nitsujlangston@gmail.com"},{"name":"unusualbob","email":"unusualbob@gmail.com"}],"_cnpm_publish_time":1558723209734,"dist-tags":{"beta":"11.5.1","latest":"10.10.7"}}