Insert meta data when using sendassetfrom rpc api call

+2 votes
Hi MC Team

I am developing a ticket system but I need to insert a gps coordinate in the same api call: "sendassetfrom" to other address.Is this possible?

Thanks in advance.
asked Dec 25, 2019 by davotrade

1 Answer

+1 vote

Yes, it's easy, but you would need to use a different API. Instead of:

sendassetfrom <from> <to> <asset> <qty>


sendwithdatafrom <from> <to> '{"<asset>":<qty>}' '{"json":{"i":[1,2],"j":"yes"}}'

This assumes you are using the multichain-cli command line and want to add JSON metadata outside of a stream. See this for other options:

answered Dec 27, 2019 by MultiChain