Transactions

Check Contract Execution Status

Returns the status code of a contract execution.
1
https://api-ropsten.etherscan.io/api
2
?module=transaction
3
&action=getstatus
4
&txhash=0xb2356f16434729b34c38e064b889c558fc4d337e47d4fd2a667f0f8b7c32e4e6
5
&apikey=YourApiKeyToken
Copied!
Try this endpoint in your browser
πŸ”—
​
Request
Response
Query Parameters
Parameter
Description
txhash
the string representing the transaction hash to check the execution status
Sample Response
1
{
2
"status":"1",
3
"message":"OK",
4
"result":{
5
"isError":"1",
6
"errDescription":"Reverted"
7
}
8
}
Copied!
​
πŸ“–
Tip: The isError field returns 0 for successful transactions and 1 for failed transactions.

Check Transaction Receipt Status

Returns the status code of a transaction execution.
​
πŸ“
Note: Only applicable for post Byzantium Fork transactions.
1
https://api-ropsten.etherscan.io/api
2
?module=transaction
3
&action=gettxreceiptstatus
4
&txhash=0xd1bb32274f861c4754afee1d5a4cc863eaf37c78fb319f6215a10ad630a5a946
5
&apikey=YourApiKeyToken
Copied!
Try this endpoint in your browser
πŸ”—
​
Request
Response
Query Parameters
Parameter
Description
txhash
the string representing the transaction hash to check the execution status
Sample Response
1
{
2
"status":"1",
3
"message":"OK",
4
"result":{
5
"status":"0"
6
}
7
}
Copied!
​
πŸ“–
Tip: The status field returns 0 for failed transactions and 1 for successful transactions.
Last modified 3mo ago