cURL
curl --request GET \ --url https://api.amberdata.com/blockchains/contracts/{hash} \ --header 'x-api-key: <api-key>'
{ "description": "Successful request", "payload": { "abi": [ { "constant": true, "inputs": [ { "name": "_interfaceID", "type": "bytes4" } ], "name": "supportsInterface", "outputs": [ { "name": "", "type": "bool" } ], "payable": false, "stateMutability": "view", "type": "function" } ], "bytecode": "0x60806040...", "contractName": "CryptoKitties", "source": "pragma solidity ^0.4.11;\n\ncontract Example {\n // Contract body...\n}\n" }, "status": 200, "title": "OK" }
Retrieves all the detailed information for the specified contract (ABI, bytecode, sourcecode…).
The id of the blockchain
ethereum-mainnet
The address of the contract
OK
The response is of type object.
object
Was this page helpful?