Skip to main content
GET
/
transactions
/
{transaction_hash}
/
raw-trace
get transaction raw trace
curl --request GET \
  --url https://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace
import requests

url = "https://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace', 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://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace",
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://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace"

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://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace")
.asString();
require 'uri'
require 'net/http'

url = URI("https://eth.blockscout.com/api/v2/transactions/{transaction_hash}/raw-trace")

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
[
  {
    "action": {
      "callType": "call",
      "to": "0x162e898bd0aacb578c8d5f8d6ca588c13d2a383f",
      "from": "0xf57b55b01b831e602e09674a4e5d69cbcf343f98",
      "input": "0x630cea8e000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000041c25b36779231e71769118210c3eb64c0a9c7577b925b309af3183e13acc7cf30210493d13c8c6c3c0bd337d5e39e454fece0c301f0aedb6c43c7a37650ac83e71c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000019500050000f0add9e5dc02faeca12e9669f045685449d6b80a000000000000744359447362798334d3485c64d1e4870fde2ddc0d75f0b456250dc9990662a6f25808cc74a6d1131ea9000927c001018064382ae87cdd000000000000000000000000bab3cbdcbcc578445480a79ed80269c50bb5b71800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000012000000000000000000000000351af1631aa5ea1ca62ad8a4e3cd87128d4d910800000000000000000000000000000000000000000000005b8decde02914ce837000000000000000000000000000000000000000000000000000000000000001e4d45444f4f5a412045636f73797374656d2076322e30206f6e2078446169000000000000000000000000000000000000000000000000000000000000000000044d445a41000000000000000000000000000000000000000000000000000000000000000000000000000000",
      "gas": "0x25D3FC",
      "value": "0x0"
    },
    "subtraces": 0,
    "traceAddress": [
      0,
      0
    ],
    "type": "call",
    "error": "Reverted",
    "result": {
      "gasUsed": "0x25D3FC",
      "output": "0x0"
    }
  }
]

Path Parameters

transaction_hash
string
required

Transaction hash

Pattern: ^0x([A-Fa-f0-9]{64})$

Response

raw trace

action
object
required
subtraces
integer
required
Example:

0

traceAddress
integer[]
required
Example:
[0, 0]
type
string
required
Example:

"call"

error
string
Example:

"Reverted"

result
object