0

I'm attempting to create a transaction for broadcast later but tx_blob always returns empty. tx_metadata is populated so I attempted to relay that at: https://monero-stagenet.exan.tech/rawtx but it was rejected.

The data does not appear to be signed raw tx! Data prefix: 0xffffffd3]z0xffffffef~0xffffffb90xffffffefn0xffffffbd0xffffffeb^0xffffff9c0xffffffeb0xffffffde0xffffffda0xffffffeb^0xfffffff80xffffffeb0xffffffde0xffffff9f

Request:

{
  "params": {
    "unlock_time": 0,
    "ring_size": 7,
    "priority": 1,
    "mixin": 7,
    "get_tx_metadata": true,
    "get_tx_key": true,
    "get_tx_hex ": true,
    "do_not_relay": true,
    "destinations": [
      {
        "amount": 1000000000000,
        "address": "56Wfz6VXwNJcek5fmSGV6P2Li5oSDzJvKf3rkfxue1Qd67Y18MPmKwTeR656bLqmXvHPFJ1vdsk6K4AzAuPp6yJmVSVqyqF"
      }
    ]
  },
  "method": "transfer",
  "jsonrpc": "2.0",
  "id": 0
}

Response:

{
  "id": 0,
  "jsonrpc": "2.0",
  "result": {
    "amount": 1000000000000,
    "fee": 13564070000,
    "multisig_txset": "",
    "unsigned_txset": "",
    "tx_blob": "",
    "tx_hash": "bc8bb62afca7bd35e8df7a9b8da71b33164a123d8b81b97413ea835e65908a3f",
    "tx_key": "8a607569d6d69e5888ba43bbb2020dd6fa5ba323393aba9eabff852ec45aea0b",
    "tx_metadata": "011673657269616c697a6174696f6e3a3a617263686976650000000103000001020000000101000000010300000..."
  }
}
C Flip
  • 3
  • 2

3 Answers3

0

If you are using the relay_tx method, you're supposed to pass the tx_metadata to it.

See the method here.

I can confirm it works fine.

el00ruobuob
  • 845
  • 4
  • 8
0

As per the docs, tx_blob is only returned if you relayed the tx from transfer.

If you wish to relay later, you use relay_tx passing in your returned tx_metadata from transfer.

https://getmonero.org/resources/developer-guides/wallet-rpc.html#relay_tx

jtgrassie
  • 19,601
  • 4
  • 17
  • 54
0

The reason why you're not getting tx_blob back is that it is only returned if you set get_tx_hex to true. You did not, you set "get_tx_hex " with a space to true.

user36303
  • 34,928
  • 2
  • 58
  • 123