Socket
Socket
Sign inDemoInstall

chain-node

Package Overview
Dependencies
29
Maintainers
2
Versions
26
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.0.5 to 0.0.6

35

index.js

@@ -23,6 +23,12 @@ var request = require('request');

},
getTransaction: function(hash, cb) {
getAddressTransactions: function(addr, options, cb) {
options = options || {};
if (typeof(options) == 'function') {
cb = options;
options = {};
}
request({
method: 'GET',
uri: URL + '/v1/bitcoin/transactions/' + hash,
uri: URL + '/v1/bitcoin/addresses/' + addr + '/transactions',
qs: options,
strictSSL: true,

@@ -35,18 +41,17 @@ cert: PEM,

},
sendTransaction: function(hex, cb) {
getAddressUnspents: function(addr, cb) {
request({
method: 'PUT',
uri: URL + '/v1/bitcoin/transactions/',
method: 'GET',
uri: URL + '/v1/bitcoin/addresses/' + addr + '/unspents',
strictSSL: true,
cert: PEM,
auth: {user: this.getKey()},
json: {hex: hex},
}, function(err, msg, resp) {
cb(err, resp);
cb(err, JSON.parse(resp));
});
},
getAddressUnspents: function(addr, cb) {
getTransaction: function(hash, cb) {
request({
method: 'GET',
uri: URL + '/v1/bitcoin/addresses/' + addr + '/unspents',
uri: URL + '/v1/bitcoin/transactions/' + hash,
strictSSL: true,

@@ -58,3 +63,15 @@ cert: PEM,

});
},
sendTransaction: function(hex, cb) {
request({
method: 'PUT',
uri: URL + '/v1/bitcoin/transactions/',
strictSSL: true,
cert: PEM,
auth: {user: this.getKey()},
json: {hex: hex},
}, function(err, msg, resp) {
cb(err, resp);
});
}
};
{
"name": "chain-node",
"version": "0.0.5",
"version": "0.0.6",
"description": "The Official Node.js SDK for Chain's Bitcoin API",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc