Open 0xVolar opened 7 months ago
The inscriptions are contained within the inputs of a reveal transaction. In order to uniquely identify them they are assigned an ID of the form:
521f8eccffa4c41a3a7728dd012ea5a4a02feed81f41159231251ecf1e5c79dai0
The part in front of the i is the transaction ID (txid) of the reveal transaction. The number after the i defines the index (starting at 0) of new inscriptions being inscribed in the reveal transaction.
here is the document link: https://docs.ordinals.com/inscriptions.html
https://docs.unisat.io/dev/unisat-developer-service/general/inscriptions/get-inscription-info
this api can get the inscription detail.
So,I can use this apihttps://docs.unisat.io/dev/unisat-developer-service/general/addresses/get-inscription-utxo
to get the utxo as the input of PSBT?
So,I can use this api
https://docs.unisat.io/dev/unisat-developer-service/general/addresses/get-inscription-utxo
to get the utxo as the input of PSBT?
yes
What should I do if I have A signed PSBT A and I want to use the signed input in A as the input for PSBT in the new PSBT B?
const tx = psbtA.extractTransaction();
psbtB.addInput({
hash: tx.ins[0].hash,
index: tx.ins[0].index,
});
and I get this "Can't find pubkey in input without Utxo data" when I use signPsbt. What can I do to solve this question?
If I include both inscriptions and btc in a PSBT, then there is a risk when signing PSBT, so how do I solve this problem and distinguish between inscriptions and btc?
What should I do if I have A signed PSBT A and I want to use the signed input in A as the input for PSBT in the new PSBT B?
const tx = psbtA.extractTransaction(); psbtB.addInput({ hash: tx.ins[0].hash, index: tx.ins[0].index, });
and I get this "Can't find pubkey in input without Utxo data" when I use signPsbt. What can I do to solve this question?
I think you are intending to use the output of transaction A as the input for transaction B. In that case, you should do it like this: const txid = tx.getId(); The hash is the txid, and vout is the number of the output you want to reference.
I want to create a PSBT by using inscription's info.I know how to create a simple PSBT.It requires a input by using txID.And I find inscription has the id too.Is this id same to txID? Or I need to fill in some other information as input?I have no idea with that.