LogoLogo
HomeTwitterKnowledge BaseAPI PRO
BaseScan
BaseScan
  • Introduction
  • ✨Getting Started
    • Creating an Account
    • Getting an API key
    • Endpoint URLs
  • 🎯API Endpoints
    • Accounts
    • Contracts
    • Transactions
    • Blocks
    • Logs
    • Geth/Parity Proxy
    • Tokens
    • Stats
  • 🏆API PRO
    • BaseScan API PRO
    • API PRO Endpoints
  • 🤝Support
    • FAQ
    • Rate Limits
    • Common Error Messages
    • Common Verification Errors
    • Getting Help
  • Visit BaseScan.org
Powered by GitBook
On this page
  • Check Contract Execution Status
  • Check Transaction Receipt Status
  1. API Endpoints

Transactions

PreviousContractsNextBlocks

Last updated 1 year ago

Check Contract Execution Status

Returns the status code of a contract execution.

https://api.basescan.org/api
   ?module=transaction
   &action=getstatus
   &txhash=0x4de3556b73420442ffd825927028bca98c75eb196d8b9e41e5f2ab7dd145a5f1
   &apikey=YourApiKeyToken

Try this endpoint in your

Query Parameters

Parameter
Description

txhash

the string representing the transaction hash to check the execution status

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":{
      "isError":"1",
      "errDescription":"execution reverted"
   }
}

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 transactions.

https://api.basescan.org/api
   ?module=transaction
   &action=gettxreceiptstatus
   &txhash=0x8291daa460156d59c6153a480eaa32c35af4817e0934b09b53be90344733f216
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

txhash

the string representing the transaction hash to check the execution status

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":{
      "status":"1"
   }
}

Try this endpoint in your

Tip: The status field returns 0 for failed transactions and 1 for successful transactions.

🎯
📖
🔗
📖
📝
browser
Byzantium Fork
🔗
browser