Manage blockchain transactions using our transaction API to create, send, and estimate fees.
The Transaction API enables transactions for various blockchain implementations, including EVM and others. It offers endpoints for creating, compiling, sending, decoding, and estimating fees for transactions.
The Transaction API is part of the Wallet Transact and Chain Watch bundles.
Authentication
You can authenticate your request by using your API Key either as a:
- Query parameter (
?apiKey=<YOUR_API_KEY>
)
or
- Header (
X-API-Key: <YOUR_API_KEY>
)
Info:
Refer to the Authenticate Your API Requests page for more details.
Transaction API v1
The URL structure for Transaction API v1 endpoints is as follows.
https://svc.blockdaemon.com/universal/{version}/{protocol}/{network}
Use the Get the Protocol Info - GET /{protocol}/{network}
endpoint to see which transaction-related endpoints are available for a specific blockchain.
curl --request GET \
--url https://svc.blockdaemon.com/universal/v1/PROTOCOL/NETWORK> \
--header 'accept: application/json' \
--header 'authorization: Bearer <YOUR_API_KEY>'
Available Endpoints
All data will be accessible through the following API endpoints:
Endpoint | What's this for? |
---|---|
Get the Transaction Confirmations - GET /tx/{hash}/confirmations | Retrieves the number of confirmations for a given transaction hash. Useful for tracking transaction finality. |
Get a Transaction - GET /tx/{hash} | Fetches details of a specific transaction using its hash, including inputs, outputs, and metadata. |
Get a Transaction Output by Hash and Index - GET /tx/{hash}/{index} | Retrieves details of a specific transaction output by specifying the transaction hash and output index. |
Get a List of Transaction Inputs and Outputs - GET /account/{address}/utxo | Returns the list of unspent transaction outputs (UTXOs) for a given address, which can be used in new transactions. |
Get a List of Transactions for a Given Address - GET /account/{address}/txs | Lists all transactions linked to a specific address, helping track account activity. |
Get a List of Transactions - GET /txs | Retrieves a list of recent transactions across the network. |
Transaction API v2
The URL structure for Transaction API v2 endpoints is as follows.
https://svc.blockdaemon.com/tx/v1/{blockchain_id}
Use the Get the Supported Protocol Info - GET /{blockchain_id}
endpoint to see which transaction-related endpoints are available for a specific blockchain.
curl --request GET \
--url https://svc.blockdaemon.com/tx/v1/PROTOCOL-NETWORK< \
--header 'accept: application/json' \
--header 'authorization: Bearer YOUR_API_KEY'
Available Endpoints
Version 2 of the API not only includes the functionalities of version 1 but also adds additional improvements through the following API endpoints:
Endpoint | What's this for? |
---|---|
Create an Unsigned Transaction - POST /create | Generates an unsigned transaction that can be signed and broadcasted later. |
Derive a Signing Payload - POST /derive_signing_payload | Generates a signing payload from an unsigned transaction. |
Create an Unsigned Token Transfer Transaction - POST /create/token | Creates an unsigned transaction specifically for transferring tokens. |
Compile an Unsigned Transaction - POST /compile | Converts an unsigned transaction into a format ready for signing. |
Compile and Broadcast an Unsigned Transaction - POST /compile_and_send | Compiles an unsigned transaction, signs it, and broadcasts it to the network. |
Submit a Signed Transaction - POST /send | Sends a signed transaction to the blockchain network for execution. |
Verify a Transaction - POST /verify | Checks if a given transaction is valid and correctly formatted. |
Decode a Transaction - POST /decode | Decodes a raw transaction to a human-readable format. |
Get the Fee Estimation - POST /estimate_fee | Estimates the network fees required for a transaction. |
👋 Need Help?
Contact us through email or our support page for any issues, bugs, or assistance you may need.