Last active
November 8, 2017 14:26
-
-
Save semasping/e8a41fd6fabe2c9e5be9564ae20406ac to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//мучаю nodejs | |
//просто проголосовать: | |
const golos = require('golos-js'); | |
/* | |
golos.config.set('websocket', 'wss://api.golos.cf'); | |
golos.config.set('address_prefix', 'GLS'); | |
golos.config.set('chain_id', '782a3039b478c839e4cb0c941ff4eaeb7df40bdd68bd441afd444b9da763de12'); | |
*/ | |
var percent = 10000; | |
var account = "semasping"; | |
var key = "5Jklfnref........"; | |
var parentAuthorAns = '...'; | |
var parentPermlinkAns = '...'; | |
var wif = golos.auth.toWif(account, key, 'posting'); | |
/* | |
console.log('wif=' + wif + golos.auth.isWif(wif)); // true | |
pub = golos.auth.wifToPublic(wif); | |
console.log(golos.auth.wifIsValid(wif, pub)); //true | |
console.log(pub); | |
*/ | |
golos.broadcast.vote(wif, account, parentAuthorAns, parentPermlinkAns, percent, function (err, result) { | |
console.log(err, result); | |
}); | |
---------------------------- | |
в ответ получаю | |
error: | |
{ code: 1, | |
message: 3030000 tx_missing_posting_ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
по состоянию на ноябрь 2017