Not able to use sendasset method while trying to make a rpc call from one node to another

+1 vote
Hello,

I am new to multichain and trying hands on it.I have two nodes, one miner and another connected to it.I have created a native asset in the miner and sent some quantity to the connected other node by using multichain-cli api. Now i am trying to do the same through multichain RPC-API.

The problem i am facing right now is that after running the curl command ,i am getting a txid but still when i check the balance,its the same as before the transaction.

 

Curl:

curl --user multichainrpc:FL4NBKuxEvJ8drAWZjCQgrDn6dPzYotwmn18q6GtmbMp --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "sendasset", "params": ["1HJYmkhGFjr8cVXfsXrFUFDRHWwPbqMufuUCNR","asset3",10]}' -H 'content-type: text/plain;' http://XXX.XXX.XX.XXX:7346/

{"result":"3301f8384615e12d13734f3e2dadd332dba3a23a33d834ea8391d22a8099ffa9","error":null,"id":"curltest"}

Can anyone please guide me on this?
asked Feb 26, 2017 by anonymous

1 Answer

0 votes

The most likely explanation is that you are sending the asset from the node back to itself. Try using sendassetfrom to explicitly specify the 'from' and 'to' addresses. This will help you make sure you are sending to an address that was created by the other node, or at least a different address on the same node. If you have multiple addresses on each node, you can also use getmultibalances to see a breakdown of which address owns which assets.

answered Feb 26, 2017 by MultiChain
...