Transactions & Fees
sendTransaction
Submits a signed transaction to the cluster for processing
Parameters
Fully-signed transaction as a base-64 encoded string
Configuration object containing:
Encoding format for the transaction (base58, base64, json)
Commitment level (processed, confirmed, finalized)
Commitment level for preflight (processed, confirmed, finalized)
If true, skip the preflight transaction checks
Maximum number of times for the RPC node to retry sending the transaction to the leader
The minimum slot that the request can be evaluated at
Response
First transaction signature embedded in the transaction (base-58 encoded)
Code Examples
Basic Request
Using web3.js
Notes
- Submits a signed transaction to the cluster
- The transaction must be fully signed
- The response is the transaction signature
- The transaction must be confirmed before changes are applied
- The transaction must include a recent blockhash
Best Practices
- Use appropriate commitment level based on your needs
- Wait for transaction confirmation before proceeding
- Handle rate limits and network errors
- Monitor transaction status for failures
- Consider using preflight checks for validation
Common Errors
Code | Message | Solution |
---|---|---|
-32601 | Method not found | Verify you’re connected to a Solana RPC node |
-32602 | Invalid params | Check transaction format and encoding |
-32003 | Transaction simulation failed | Verify transaction validity and account balances |
-32004 | Blockhash not found | Use a more recent blockhash |
-32005 | Node is behind | Try a different RPC node |
-32006 | Transaction already processed | Transaction was already submitted |
-32007 | Transaction signature verification failed | Check transaction signatures |
Use Cases
-
Transaction Management
-
Transaction Monitoring
-
Transaction Planning