You are viewing a single comment's thread from:

RE: TUTORIAL - Beginner friendly - Build your first steem bot in Javascript - 30minutes

in #utopian-io7 years ago

The code you have given in your sample works perfectly.

I was just trying to build on it to add comments to a post.

I keep getting the following error.

"Expected version 128, instead got 149"

Please let me know if you were able to post comments through the code.

Sort:  

okay thanks for clarifying, it's 100% possible to send comments through code.

See this broadcast function - https://github.com/code-with-sam/steem-versary-bot/blob/master/bot.js#L183

notice the operations array on line 150 - https://github.com/code-with-sam/steem-versary-bot/blob/master/bot.js#L150

Looks like I am having issues with all the broadcast functions. stream functions are working fine though.

Let me know if we can discuss this in steemchat.

perhaps you are trying to do steem.api.broadcast() when it should be steem.broadcast() ?

Also check you're not redefining steem anywhere?

p.s post your full code as a gist!

For ACCOUNT_WIF I was using the actual password and not the posting key. After changing that it is working well. Since it was WIF related issue other calls were working and only those where WIF was involved were throwing the error.

I wish the message was little more verbose. It could have saved me a lot of time :P

Thanks for your inputs.