unisat-wallet / extension

The first open-source browser extension wallet for Bitcoin NFTs
Other
804 stars 306 forks source link

When adding a memo to create an OP_RETURN transaction using the latest version of the UniSat wallet, a problem occurs. #167

Closed ferrarif1 closed 3 months ago

ferrarif1 commented 3 months ago

I want to know how to correctly create an OP_RETURN transaction using UniSat. When I add a memo in the unisat.sendBitcoin method, the data I input is treated as a string. The Rune protocol requires a format like "OP_RETURN 52 0001fe406f4001 ffdbf3de59dbf3de5912", where 52, 0001fe406f4001, and ffdbf3de59dbf3de5912 should each be parsed as separate parts, similar to the transaction example here: mempool.space testnet transaction. image

However, currently, when I input data like "52 0001fe406f4001 ffdbf3de59dbf3de5912", the transaction generated does not separate these data into three parts, as seen in this transaction: mempool.space testnet transaction. Is there a way to add a method that allows users to directly add the OP_RETURN part encoded by the bscript.compile method into the transaction, for example, "6a0952554e455f544553540900a9cfd6ff1b866800"? image

GGG888GGG commented 3 months ago

Please send your question to contact@unisat.io for developer service. @ferrarif1

ferrarif1 commented 3 months ago

Please send your question to contact@unisat.io for developer service. @ferrarif1

ok