Help: can I use transferAsset API to create transaction voucher? I tried following but failed:
sender publickey: 91d79431648e15b8d63dfg34653grferd5469ecc22a5e9e53a3d664b0634
recipient:ARDOR-AAAA-AAAA-AAAA-AAAAA
parameters:
requestType:transferAsset
chain: 2
recipient:ARDOR-AAAA-AAAA-AAAA-AAAAA
asset:12345678901234567890
quantityQNT:10
secretPhrase: ARDOR-AAAA’s passphrase
(sender’s) publicKey: 91d79431648e15b8d63dfg34653grferd5469ecc22a5e9e53a3d664b0634
recipientPublicKey: (blank)
feeNQT:-1
broadcast:false
voucher: ture
JSON Response did not match voucher created by wallet.
Hi. What do you mean “JSON Response did not match voucher created by wallet” ? Of course the generated voucher would not be always the same, there are fields that change, like timestamp, and that will also change the signature.
You got the API parameters right: you send the recipient’s secret instead of the sender’s, and put the sender public key.
yes, first one is from API, second one from wallet.
from API I use recipient’s passpharse to sign the transaction, and use intend sender’ publick key in the ‘publicKey’ field, the result show senderRS same as recipientRS:
from API JSON responses:
“senderPublicKey”: “8c4c704ee5d320a521e6cc27265e2bc5cf3fce4392bc24b476e71bb0c78a3422”,
“senderRS”: “ARDOR-MJEK-6QAF-Y9WQ-58678”,
“subtype”: 1,
“amountNQT”: “0”,
“sender”: “3680714291370639761”,
“recipientRS”: “ARDOR-MJEK-6QAF-Y9WQ-58678”,
“recipient”: “3680714291370639761”,
From wallet it show the correct information:
“senderPublicKey”: “91d79431648e15b8d6359574e9170cada422d5469ecc22a5e9e53a3d664b0634”,
“sender”: “12881356309019739920”,
“recipient”: “3680714291370639761”,
I tried with identical transaction attachment still have same senderRS and recipientRS created by API.