Transactions
Get Transaction by ID
Returns transaction information based on the given transaction id
GET
/
api
/
v1
/
transactions
/
{transactionId}
Get transaction by id
curl --request GET \
--url https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}import requests
url = "https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"transactions": [
{
"bytes": null,
"charged_tx_fee": 7,
"consensus_timestamp": "1234567890.000000007",
"entity_id": "0.0.2281979",
"max_fee": 33,
"memo_base64": null,
"name": "CRYPTOTRANSFER",
"nft_transfers": [
{
"is_approval": true,
"receiver_account_id": "0.0.121",
"sender_account_id": "0.0.122",
"serial_number": 1,
"token_id": "0.0.123"
},
{
"is_approval": true,
"receiver_account_id": "0.0.321",
"sender_account_id": "0.0.422",
"serial_number": 2,
"token_id": "0.0.123"
}
],
"node": "0.0.3",
"nonce": 0,
"parent_consensus_timestamp": "1234567890.000000007",
"result": "SUCCESS",
"scheduled": false,
"staking_reward_transfers": [
{
"account": 3,
"amount": 200
},
{
"account": 9,
"amount": 300
}
],
"transaction_hash": "vigzKe2J7fv4ktHBbNTSzQmKq7Lzdq1/lJMmHT+a2KgvdhAuadlvS4eKeqKjIRmW",
"transaction_id": "0.0.8-1234567890-000000006",
"token_transfers": [
{
"token_id": "0.0.90000",
"account": "0.0.9",
"amount": 1200,
"is_approval": true
},
{
"token_id": "0.0.90000",
"account": "0.0.8",
"amount": -1200,
"is_approval": true
}
],
"transfers": [
{
"account": "0.0.3",
"amount": 2,
"is_approval": true
},
{
"account": "0.0.8",
"amount": -3,
"is_approval": true
},
{
"account": "0.0.98",
"amount": 1,
"is_approval": true
},
{
"account": "0.0.800",
"amount": 200,
"is_approval": false
},
{
"account": "0.0.800",
"amount": 300,
"is_approval": false
}
],
"valid_duration_seconds": 11,
"valid_start_timestamp": "1234567890.000000006",
"assessed_custom_fees": [
{
"amount": 100,
"collector_account_id": "0.0.10",
"effective_payer_account_ids": [
"0.0.8",
"0.0.72"
],
"token_id": "0.0.90001"
}
]
}
]
}{
"_status": {
"messages": [
{
"message": "Invalid parameter: account.id"
},
{
"message": "Invalid Transaction id. Please use \\shard.realm.num-sss-nnn\\ format where sss are seconds and nnn are nanoseconds"
}
]
}
}{
"_status": {
"messages": [
{
"message": "Not found"
}
]
}
}Get Transaction information by ID.
This method will use
20 Compute Units.
Path Parameters
Transaction id
Query Parameters
Filter the query result by the nonce of the transaction. A zero nonce represents user submitted transactions while a non-zero nonce is generated by main nodes. The filter honors the last value. If not specified, all transactions with specified payer account ID and valid start timestamp match.
Required range:
x >= 0Filter transactions by the scheduled flag. If true, return information for the scheduled transaction. If false, return information for the non-scheduled transaction. If not present, return information for all transactions matching transactionId.
Response
OK
Show child attributes
Show child attributes
Get transaction by id
curl --request GET \
--url https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}import requests
url = "https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{network}.hedera.validationcloud.io/v1/{API_KEY}/api/v1/transactions/{transactionId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"transactions": [
{
"bytes": null,
"charged_tx_fee": 7,
"consensus_timestamp": "1234567890.000000007",
"entity_id": "0.0.2281979",
"max_fee": 33,
"memo_base64": null,
"name": "CRYPTOTRANSFER",
"nft_transfers": [
{
"is_approval": true,
"receiver_account_id": "0.0.121",
"sender_account_id": "0.0.122",
"serial_number": 1,
"token_id": "0.0.123"
},
{
"is_approval": true,
"receiver_account_id": "0.0.321",
"sender_account_id": "0.0.422",
"serial_number": 2,
"token_id": "0.0.123"
}
],
"node": "0.0.3",
"nonce": 0,
"parent_consensus_timestamp": "1234567890.000000007",
"result": "SUCCESS",
"scheduled": false,
"staking_reward_transfers": [
{
"account": 3,
"amount": 200
},
{
"account": 9,
"amount": 300
}
],
"transaction_hash": "vigzKe2J7fv4ktHBbNTSzQmKq7Lzdq1/lJMmHT+a2KgvdhAuadlvS4eKeqKjIRmW",
"transaction_id": "0.0.8-1234567890-000000006",
"token_transfers": [
{
"token_id": "0.0.90000",
"account": "0.0.9",
"amount": 1200,
"is_approval": true
},
{
"token_id": "0.0.90000",
"account": "0.0.8",
"amount": -1200,
"is_approval": true
}
],
"transfers": [
{
"account": "0.0.3",
"amount": 2,
"is_approval": true
},
{
"account": "0.0.8",
"amount": -3,
"is_approval": true
},
{
"account": "0.0.98",
"amount": 1,
"is_approval": true
},
{
"account": "0.0.800",
"amount": 200,
"is_approval": false
},
{
"account": "0.0.800",
"amount": 300,
"is_approval": false
}
],
"valid_duration_seconds": 11,
"valid_start_timestamp": "1234567890.000000006",
"assessed_custom_fees": [
{
"amount": 100,
"collector_account_id": "0.0.10",
"effective_payer_account_ids": [
"0.0.8",
"0.0.72"
],
"token_id": "0.0.90001"
}
]
}
]
}{
"_status": {
"messages": [
{
"message": "Invalid parameter: account.id"
},
{
"message": "Invalid Transaction id. Please use \\shard.realm.num-sss-nnn\\ format where sss are seconds and nnn are nanoseconds"
}
]
}
}{
"_status": {
"messages": [
{
"message": "Not found"
}
]
}
}