send_raw_transaction - Monero

Example code for the send_raw_transaction JSON-RPC method. Complete guide on how to use send_raw_transaction JSON-RPC in GetBlock Web3 documentation.

This non-JSON-RPC endpoint broadcasts a serialized signed transaction to the network. It is the primary submission point for transactions constructed and signed offline by a wallet.

Parameters

Parameter
Type
Required
Description

tx_as_hex

string

Yes

Hex-encoded signed transaction blob

do_not_relay

boolean

No

If true, the node will accept the tx but not propagate it (rare; useful for testing)

Request Example

curl --location --request POST 'https://go.getblock.io/<ACCESS-TOKEN>/send_raw_transaction' \
--header 'Content-Type: application/json' \
--data-raw '{
    "tx_as_hex": "de6a3\u2026",
    "do_not_relay": false
}'

Response Example

{
    "double_spend": false,
    "fee_too_low": false,
    "invalid_input": false,
    "invalid_output": false,
    "low_mixin": false,
    "not_relayed": false,
    "overspend": false,
    "reason": "",
    "status": "OK",
    "too_big": false,
    "too_few_outputs": false,
    "untrusted": false
}

Response Parameters

Field
Type
Description

status

string

OK if the transaction was accepted; otherwise a failure code

reason

string

Human-readable rejection reason (empty on success)

double_spend

boolean

true if rejected as a double-spend

fee_too_low

boolean

true if rejected because the fee was below the minimum

low_mixin

boolean

true if the ring size was below the network minimum

invalid_input

boolean

true if an input was invalid

invalid_output

boolean

true if an output was invalid

not_relayed

boolean

true if accepted but not relayed (e.g. do_not_relay=true)

overspend

boolean

true if outputs exceed inputs

too_big

boolean

true if the transaction exceeds the maximum allowed size

Use Cases

  • Broadcasting signed XMR transactions from cold wallets

  • Mining-pool payouts and operational disbursements

  • Exchanges and merchant settlement flows

Error Handling

Status Code
Error Message
Cause

403

Forbidden

Missing or invalid <ACCESS-TOKEN>

-32602

Invalid params

Request parameters are missing or malformed

429

Too Many Requests

Rate limit exceeded for your plan

SDK Integration

Last updated

Was this helpful?