coinhive-nodejs

1.2.0 • Public • Published

Coinhive NodeJs module

initialization

var coinhive = require('coinhive-nodejs');
var mycoinhive = new coinhive('public_key', 'private_key');

Create a link with coinhive

const params = {
  link: 'https://thomas-t.fr', // The link where you want to redirect
  hashes: 1024, // The number of hashes you want for redirect the user
  onError: function(params){
    // This function is optional
  }
}
 
const callback = function(link){
  // Make an happy world with your link :)
}
mycoinhive.create_link(params, callback)

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.2.0
    2
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.2.0
    2
  • 1.0.1
    1
  • 1.0.0
    1

Package Sidebar

Install

npm i coinhive-nodejs

Weekly Downloads

4

Version

1.2.0

License

MIT

Unpacked Size

3.22 kB

Total Files

4

Last publish

Collaborators

  • thomast_404