eth_getTransactionReceipt
curl --request GET \
--url 'https://api.etherscan.io/v2/api?apikey='import requests
url = "https://api.etherscan.io/v2/api?apikey="
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.etherscan.io/v2/api?apikey=', 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://api.etherscan.io/v2/api?apikey=",
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://api.etherscan.io/v2/api?apikey="
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://api.etherscan.io/v2/api?apikey=")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.etherscan.io/v2/api?apikey=")
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{
"jsonrpc": "2.0",
"id": 1,
"result": {
"blockHash": "0x07c17710dbb7514e92341c9f83b4aab700c5dba7c4fb98caadd7926a32e47799",
"blockNumber": "0xcf2427",
"contractAddress": null,
"cumulativeGasUsed": "0xeb67d5",
"effectiveGasPrice": "0x1a96b24c26",
"from": "0x292f04a44506c2fd49bac032e1ca148c35a478c8",
"gasUsed": "0xb41d",
"logs": [
{
"address": "0xdac17f958d2ee523a2206206994597c13d831ec7",
"topics": [
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
"0x000000000000000000000000292f04a44506c2fd49bac032e1ca148c35a478c8",
"0x000000000000000000000000ab6960a6511ff18ed8b8c012cb91c7f637947fc0"
],
"data": "0x00000000000000000000000000000000000000000000000000000000013f81a6",
"blockNumber": "0xcf2427",
"transactionHash": "0xadb8aec59e80db99811ac4a0235efa3e45da32928bcff557998552250fa672eb",
"transactionIndex": "0x122",
"blockHash": "0x07c17710dbb7514e92341c9f83b4aab700c5dba7c4fb98caadd7926a32e47799",
"logIndex": "0xdb",
"removed": false
}
],
"logsBloom": "0x0000000000000000000000000000000000000000000000000000000000000400000000000400000000000000000001000000000000000000000000000000000000000000000000000000000800000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000001000000000110000000000000000000000000000000000000000000000000000000200100000000000000000000000000080000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"status": "0x1",
"to": "0xdac17f958d2ee523a2206206994597c13d831ec7",
"transactionHash": "0xadb8aec59e80db99811ac4a0235efa3e45da32928bcff557998552250fa672eb",
"transactionIndex": "0x122",
"type": "0x2"
}
}
Geth/Parity Proxy
eth_getTransactionReceipt
Get the receipt of a transaction by hash.
GET
/
v2
/
api
eth_getTransactionReceipt
curl --request GET \
--url 'https://api.etherscan.io/v2/api?apikey='import requests
url = "https://api.etherscan.io/v2/api?apikey="
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.etherscan.io/v2/api?apikey=', 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://api.etherscan.io/v2/api?apikey=",
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://api.etherscan.io/v2/api?apikey="
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://api.etherscan.io/v2/api?apikey=")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.etherscan.io/v2/api?apikey=")
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{
"jsonrpc": "2.0",
"id": 1,
"result": {
"blockHash": "0x07c17710dbb7514e92341c9f83b4aab700c5dba7c4fb98caadd7926a32e47799",
"blockNumber": "0xcf2427",
"contractAddress": null,
"cumulativeGasUsed": "0xeb67d5",
"effectiveGasPrice": "0x1a96b24c26",
"from": "0x292f04a44506c2fd49bac032e1ca148c35a478c8",
"gasUsed": "0xb41d",
"logs": [
{
"address": "0xdac17f958d2ee523a2206206994597c13d831ec7",
"topics": [
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
"0x000000000000000000000000292f04a44506c2fd49bac032e1ca148c35a478c8",
"0x000000000000000000000000ab6960a6511ff18ed8b8c012cb91c7f637947fc0"
],
"data": "0x00000000000000000000000000000000000000000000000000000000013f81a6",
"blockNumber": "0xcf2427",
"transactionHash": "0xadb8aec59e80db99811ac4a0235efa3e45da32928bcff557998552250fa672eb",
"transactionIndex": "0x122",
"blockHash": "0x07c17710dbb7514e92341c9f83b4aab700c5dba7c4fb98caadd7926a32e47799",
"logIndex": "0xdb",
"removed": false
}
],
"logsBloom": "0x0000000000000000000000000000000000000000000000000000000000000400000000000400000000000000000001000000000000000000000000000000000000000000000000000000000800000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000001000000000110000000000000000000000000000000000000000000000000000000200100000000000000000000000000080000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"status": "0x1",
"to": "0xdac17f958d2ee523a2206206994597c13d831ec7",
"transactionHash": "0xadb8aec59e80db99811ac4a0235efa3e45da32928bcff557998552250fa672eb",
"transactionIndex": "0x122",
"type": "0x2"
}
}
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"blockHash": "0x07c17710dbb7514e92341c9f83b4aab700c5dba7c4fb98caadd7926a32e47799",
"blockNumber": "0xcf2427",
"contractAddress": null,
"cumulativeGasUsed": "0xeb67d5",
"effectiveGasPrice": "0x1a96b24c26",
"from": "0x292f04a44506c2fd49bac032e1ca148c35a478c8",
"gasUsed": "0xb41d",
"logs": [
{
"address": "0xdac17f958d2ee523a2206206994597c13d831ec7",
"topics": [
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",
"0x000000000000000000000000292f04a44506c2fd49bac032e1ca148c35a478c8",
"0x000000000000000000000000ab6960a6511ff18ed8b8c012cb91c7f637947fc0"
],
"data": "0x00000000000000000000000000000000000000000000000000000000013f81a6",
"blockNumber": "0xcf2427",
"transactionHash": "0xadb8aec59e80db99811ac4a0235efa3e45da32928bcff557998552250fa672eb",
"transactionIndex": "0x122",
"blockHash": "0x07c17710dbb7514e92341c9f83b4aab700c5dba7c4fb98caadd7926a32e47799",
"logIndex": "0xdb",
"removed": false
}
],
"logsBloom": "0x0000000000000000000000000000000000000000000000000000000000000400000000000400000000000000000001000000000000000000000000000000000000000000000000000000000800000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000001000000000110000000000000000000000000000000000000000000000000000000200100000000000000000000000000080000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"status": "0x1",
"to": "0xdac17f958d2ee523a2206206994597c13d831ec7",
"transactionHash": "0xadb8aec59e80db99811ac4a0235efa3e45da32928bcff557998552250fa672eb",
"transactionIndex": "0x122",
"type": "0x2"
}
}
Authorizations
Your Etherscan API key.
Query Parameters
Chain ID to query, eg 1 for Ethereum, 8453 for Base from our supported chains.
Set to proxy for this endpoint.
Set to eth_getTransactionReceipt for this endpoint.
The transaction hash to query.
⌘I