melis-api-js
Version:
Melis Javascript API bindings
8 lines (5 loc) • 477 B
JavaScript
const B=require('bitcoinjs-lib')
let s=`I do not want to be public, but, there is an issue with SegWit. If it is not fixed, there will be nothing and I would have failed. There is only one way that Bitcoin survives and it is important to me that it works. Important enough, that I may be known openly.`
console.log(s)
console.log('hash: '+B.crypto.sha256(Buffer.from(s,'utf-8')).toString('hex'))
console.log('hash: '+B.crypto.hash256(Buffer.from(s,'utf-8')).toString('hex'))