Author

Topic: raw transaction over json/post - am i doing it right ? (Read 487 times)

newbie
Activity: 30
Merit: 0
I am about to play around with this myself, so im interested in the solution.

I may be wrong, and it is untested, but i believe that the entire jsonrpc params should be an array. For the createrawtransaction you need two elements. First element is another array, containing the inputs. Second element is the address. Maybe something like:

{"jsonrpc": "1.0", "id":"rqid547333300","method": "createrawtransaction",

"params": [[ {"txid":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx","vout":0}],  {"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx":0.00500000} ]

}


/orz.dk

newbie
Activity: 24
Merit: 0


Is the following format json correct ?

I'm sending it over http post over a socket

{"jsonrpc": "1.0", "id":"rqid547333300","method": "createrawtransaction", "params": [{"txid":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx","vout":0}] {"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx":0.00500000}}:

I'm missing a quote somewhere I think -

thanks for any help

MK
Jump to: