Get the contract code at a specific address
GET/:network/contract/code
Get the contract code at a specific address
Request
Path Parameters
network stringrequired
Blockchain network name or chain id
Query Parameters
block_height number
Optional block number for which the balance is requested. Provide only block height or timestamp you want to check for.
date string
Optional Date timestamp for which the balance is requested (ISO 8601 format). Provide only block height or timestamp you want to check for.
contract_address stringrequired
Address of the contract
projectId stringrequired
The id of your project. Can be found in your Histori dashboard.
Responses
- 200
- 400
Contract code fetched successfully.
- application/json
- Schema
- Example (from schema)
Schema
network stringrequired
Name of the blockchain network
chain_id numberrequired
Chain ID of the blockchain network
contract_address stringrequired
Address of the contract
code stringrequired
Bytecode of the contract deployed at the given address
{
"network": "eth-mainnet",
"chain_id": 1,
"contract_address": "0x1234567890abcdef1234567890abcdef12345678",
"code": "0x6080604052348015600f57600080fd5b506040516020806101238339810180604052810190808051..."
}
Invalid contract address or network name.
Loading...