{
"message": "OK",
"result": {
"blockMiner": "0x13a06d3dfe21e0db5c016c03ea7d2509f7f8d1e3",
"blockNumber": "2165403",
"blockReward": "5314181600000000000",
"timeStamp": "1472533979",
"uncleInclusionReward": null,
"uncles": null
},
"status": "1"
}{
"message": "OK",
"result": {
"blockNumber": "2165403"
},
"status": "1"
}https://fonscan.io/api
?module=block
&action=getblocknobytime
×tamp={blockTimestamp}
&closest={before/after}https://fonscan.io/api
?module=block
&action=eth_block_number{
"jsonrpc": "2.0",
"result": "0x103538a",
"id": 1
}?module=stats
?module=logs
https://fonscan.io/api
?module=logs
&action=getLogs
&fromBlock=1379224
&toBlock=13792288
&address=0x33990122638b9132ca29c723bdf037f1a891a70c
&topic0=0xf63780e752c6a54a94fc52715dbc5518a3b4c3c2833d301a204226548a2a8545
&topic1=0x72657075746174696f6e00000000000000000000000000000000000000000000
&topic0_1_opr=or{
"message": "OK",
"result": [
{
"address": "0x33990122638b9132ca29c723bdf037f1a891a70c",
"blockNumber": "0x5c958",
"data": "0x",
"gasPrice": "0xba43b7400",
"gasUsed": "0x10682",
"logIndex": "0x",
"timeStamp": "0x561d688c",
"topics": [
"0xf63780e752c6a54a94fc52715dbc5518a3b4c3c2833d301a204226548a2a8545",
"0x72657075746174696f6e00000000000000000000000000000000000000000000",
"0x000000000000000000000000d9b2f59f3b5c7b3c67047d2f03c3e8052470be92"
],
"transactionHash": "0x0b03498648ae2da924f961dda00dc6bb0a8df15519262b7e012b7d67f4bb7e83",
"transactionIndex": "0x"
}
],
"status": "1"
}?module=token
?module=transaction
{
"message": "OK",
"result": {
"cataloged": true,
"contractAddress": "0x0000000000000000000000000000000000000000",
"decimals": "18",
"name": "Example Token",
"symbol": "ET",
"totalSupply": "1000000000",
"type": "ERC-20"
},
https://fonscan.io/api
?module=token
&action=getToken
&contractaddress={contractaddressHash}https://fonscan.io/api
?module=token
&action=getTokenHolders
&contractaddress={contractaddressHash}
&page={integer}
&offset={integer}https://fonscan.io/api
?module=token
&action=bridgedTokenList
&chainid={chainid}
&page={integer}
&offset={integer}{
"message": "OK",
"result": {
"status": "1"
},
"status": "1"
}{
"message": "OK",
"result": {
"errDescription": "Out of gas",
"isError": "1"
},
"status": "1"
}https://fonscan.io/api
?module=transaction
&action=gettxinfo
&txhash={transactionHash}https://fonscan.io/api
?module=transaction
&action=gettxreceiptstatus
&txhash={transactionHash}https://fonscan.io/api
?module=transaction
&action=getstatus
&txhash={transactionHash}{
"message": "OK",
"result": [
{
"address": "0x3887e82dbdbe8ec6db44e6298a2d48af572a3b78",
"value": "153737849289497644937838"
},
{
"address": "0xc894c5de34cb2a3615c737d1276876e44e9700a3",
"value": "77247336418828547887499"
}
],
"status": "1"
}{
"message": "OK",
"result": [
{
"foreignChainId": "1",
"foreignTokenContractAddressHash": "0x0ae055097c6d159879521c384f1d2123d1f195e6",
"homeContractAddressHash": "0xb7d311e2eb55f2f68a9440da38e7989210b9a05e",
"homeDecimals": "18",
"homeHolderCount": 393,
"homeName": "STAKE on xDai",
"homeSymbol": "STAKE",
"homeTotalSupply": "1484374.775044204093387391",
"homeUsdValue": "18807028.39981006586321824397"
},
{
"foreignChainId": "1",
"foreignTokenContractAddressHash": "0xf5581dfefd8fb0e4aec526be659cfab1f8c781da",
"homeContractAddressHash": "0xd057604a14982fe8d88c5fc25aac3267ea142a08",
"homeDecimals": "18",
"homeHolderCount": 73,
"homeName": "HOPR Token on xDai",
"homeSymbol": "HOPR",
"homeTotalSupply": "26600449.86076749062791602",
"homeUsdValue": "6638727.472651464170990256943"
}
],
"status": "1"
{
"result": {
"revertReason": "No credit of that type",
"blockNumber": "3",
"confirmations": "0",
"from": "0x000000000000000000000000000000000000000c",
"gasLimit": "91966",
"gasPrice": "100000",
"gasUsed": "95123",
"hash": "0x0000000000000000000000000000000000000000000000000000000000000004",
"input": "0x04",
"logs": [
{
"address": "0x000000000000000000000000000000000000000e",
"data": "0x00",
"topics": [
"First Topic",
"Second Topic",
"Third Topic",
"Fourth Topic"
]
}
],
"success": true,
"timeStamp": "1541018182",
"to": "0x000000000000000000000000000000000000000d",
"value": "67612"
},
"status": "1"
}?module=account
https://fonscan.io/api
?module=account
&action=eth_get_balance
&address={addressHash}{
"message": "OK",
"result": [
{
"ABI": "[{\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event\"\n}, {\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event2\"\n}, {\n\"type\":\"function\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\"}],\n\"name\":\"foo\",\n\"outputs\": []\n}]\n",
"CompilerVersion": "v0.2.1-2016-01-30-91a6b35",
"ContractName": "Test",
"OptimizationUsed": "1",
"SourceCode": "pragma solidity >0.4.24;\n\ncontract Test {\nconstructor() public { b = hex\"12345678901234567890123456789012\"; }\nevent Event(uint indexed a, bytes32 b);\nevent Event2(uint indexed a, bytes32 b);\nfunction foo(uint a) public { emit Event(a, b); }\nbytes32 b;\n}\n"
}
],
"status": "1"
}{
"id": 1,
"jsonrpc": "2.0",
"result": "0x0234c8a3397aab58"
}{
"message": "OK",
"result": {
"ABI": "[{\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event\"\n}, {\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event2\"\n}, {\n\"type\":\"function\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\"}],\n\"name\":\"foo\",\n\"outputs\": []\n}]\n",
"CompilerVersion": "v0.2.1-2016-01-30-91a6b35",
"ContractName": "Test",
"ImplementationAddress": "0x000000000000000000000000000000000000000e",
"IsProxy": "true",
"OptimizationUsed": "1",
"SourceCode": "pragma solidity >0.4.24;\n\ncontract Test {\nconstructor() public { b = hex\"12345678901234567890123456789012\"; }\nevent Event(uint indexed a, bytes32 b);\nevent Event2(uint indexed a, bytes32 b);\nfunction foo(uint a) public { emit Event(a, b); }\nbytes32 b;\n}\n"
},
"status": "1"
}{
"message": "OK",
"result": {
"ABI": "[{\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event\"\n}, {\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event2\"\n}, {\n\"type\":\"function\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\"}],\n\"name\":\"foo\",\n\"outputs\": []\n}]\n",
"CompilerVersion": "v0.2.1-2016-01-30-91a6b35",
"ContractName": "Test",
"ImplementationAddress": "0x000000000000000000000000000000000000000e",
"IsProxy": "true",
"OptimizationUsed": "1",
"SourceCode": "pragma solidity >0.4.24;\n\ncontract Test {\nconstructor() public { b = hex\"12345678901234567890123456789012\"; }\nevent Event(uint indexed a, bytes32 b);\nevent Event2(uint indexed a, bytes32 b);\nfunction foo(uint a) public { emit Event(a, b); }\nbytes32 b;\n}\n"
},
"status": "1"
}{
"message": "OK",
"result": {
"ABI": "[{\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event\"\n}, {\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event2\"\n}, {\n\"type\":\"function\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\"}],\n\"name\":\"foo\",\n\"outputs\": []\n}]\n",
"CompilerVersion": "v0.2.1-2016-01-30-91a6b35",
"ContractName": "Test",
"ImplementationAddress": "0x000000000000000000000000000000000000000e",
"IsProxy": "true",
"OptimizationUsed": "1",
"SourceCode": "pragma solidity >0.4.24;\n\ncontract Test {\nconstructor() public { b = hex\"12345678901234567890123456789012\"; }\nevent Event(uint indexed a, bytes32 b);\nevent Event2(uint indexed a, bytes32 b);\nfunction foo(uint a) public { emit Event(a, b); }\nbytes32 b;\n}\n"
},
"status": "1"
}
{
"message": "OK",
"result": "b080b96bd06ad1c9341c2afb7e3730311388544961acde94",
"status": "1"
}https://fonscan.io/api
?module=contract
&action=getabi
&address={addressHash}{
"message": "OK",
"result": "[{\"constant\":false,\"inputs\":[{\"name\":\"voucher_token\",\"type\":\"bytes32\"}],\"name\":\"burn\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"voucher_token\",\"type\":\"bytes32\"}],\"name\":\"is_expired\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"voucher_token\",\"type\":\"bytes32\"}],\"name\":\"is_burnt\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"voucher_token\",\"type\":\"bytes32\"},{\"name\":\"_lifetime\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"}]",
"status": "1"
}https://fonscan.io/api
?module=contract
&action=getsourcecode
&address={addressHash}{
"message": "OK",
"result": {
"ABI": "[{\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event\"\n}, {\n\"type\":\"event\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\",\"indexed\":true},{\"name\":\"b\",\"type\":\"bytes32\",\"indexed\":false}],\n\"name\":\"Event2\"\n}, {\n\"type\":\"function\",\n\"inputs\": [{\"name\":\"a\",\"type\":\"uint256\"}],\n\"name\":\"foo\",\n\"outputs\": []\n}]\n",
"CompilerVersion": "v0.2.1-2016-01-30-91a6b35",
"ContractName": "Test",
"FileName": "{sourcify path or empty}",
"ImplementationAddress": "0x000000000000000000000000000000000000000e",
"IsProxy": "true",
"OptimizationUsed": "1",
"SourceCode": "pragma solidity >0.4.24;\n\ncontract Test {\nconstructor() public { b = hex\"12345678901234567890123456789012\"; }\nevent Event(uint indexed a, bytes32 b);\nevent Event2(uint indexed a, bytes32 b);\nfunction foo(uint a) public { emit Event(a, b); }\nbytes32 b;\n}\n"
},
"status": "1"
}https://fonscan.io/api
?module=contract
&action=verify
&addressHash={addressHash}
&name={name}
&compilerVersion={compilerVersion}
&optimization={false}
&contractSourceCode={contractSourceCode}curl -d '{"addressHash":"0xc63BB6555C90846afACaC08A0F0Aa5caFCB382a1","compilerVersion":"v0.5.4+commit.9549d8ff", "contractSourceCode":"pragma solidity ^0.5.4; contract Test { }","name":"Test","optimization":false}' -H "Content-Type: application/json" -X POST "https://blockscout.com/poa/sokol/api?module=contract&action=verify"https://fonscan.io/api
?module=contract
&action=verify_via_sourcify
&addressHash={addressHash}--6e1e4c11657c62dc1e4349d024de9e28
Content-Disposition: form-data; name="addressHash"
0xb77b7443e0F32F1FEBf0BE0fBd7124D135d0a525
--6e1e4c11657c62dc1e4349d024de9e28
Content-Disposition: form-data; name="files[0]"; filename="contract.sol"
Content-Type: application/json
...Source code...
--6e1e4c11657c62dc1e4349d024de9e28
Content-Disposition: form-data; name="files[1]"; filename="metadata.json"
Content-Type: application/json
...JSON metadata...
--6e1e4c11657c62dc1e4349d024de9e28--https://fonscan.io/api
?module=contract
&action=verify_vyper_contract
&addressHash={addressHash}
&name={name}
&compilerVersion={compilerVersion}
&contractSourceCode={contractSourceCode}curl --location --request POST 'http://localhost:4000/api?module=contract&action=verify_vyper_contract' --form 'contractSourceCode="SOURCE_CODE"' --form 'name="Vyper_contract"' --form 'addressHash="0xE60B1B8bD493569a3E945be50A6c89d29a560Fa1"' --form 'compilerVersion="v0.2.12"'https://fonscan.io/api
?module=contract
&action=verifysourcecode
&codeformat={solidity-standard-json-input}
&contractaddress={contractaddress}
&contractname={contractname}
&compilerversion={compilerversion}
&sourceCode={sourceCode}https://fonscan.io/api
?module=contract
&action=checkverifystatus
&guid={identifierString}{
"message": "OK",
"result": "Pending in queue",
"status": "1"
}
"message": "OK",
"result": [
{
"contractAddress": "",
"cumulativeGasUsed": "122207",
"from": "0x3fb1cd2cd96c6d5c0b5eb3322d807b34482481d4",
"gas": "122261",
"gasPrice": "50000000000",
"gasUsed": "122207",
"hash": "0x98beb27135aa0a25650557005ad962919d6a278c4b3dde7f4f6a3a1e65aa746c",
"input": "0xf00d4b5d000000000000000000000000036c8cecce8d8bbf0831d840d7f29c9e3ddefa63000000000000000000000000c5a96db085dda36ffbe390f455315d30d6d3dc52",
"nonce": "0",
"to": "0xde0b295669a9fd93d5f28d9ec85e40f4cb697bae",
"value": "0"
}
],
"status": "1"
}{
"message": "OK",
"result": [
{
"blockHash": "0x373d339e45a701447367d7b9c7cef84aab79c2b2714271b908cda0ab3ad0849b",
"blockNumber": "65204",
"confirmations": "5994246",
"contractAddress": "",
"cumulativeGasUsed": "122207",
"from": "0x3fb1cd2cd96c6d5c0b5eb3322d807b34482481d4",
"gas": "122261",
"gasPrice": "50000000000",
"gasUsed": "122207",
"hash": "0x98beb27135aa0a25650557005ad962919d6a278c4b3dde7f4f6a3a1e65aa746c",
"input": "0xf00d4b5d000000000000000000000000036c8cecce8d8bbf0831d840d7f29c9e3ddefa63000000000000000000000000c5a96db085dda36ffbe390f455315d30d6d3dc52",
"isError": "0",
"nonce": "0",
"timeStamp": "1439232889",
"to": "0xde0b295669a9fd93d5f28d9ec85e40f4cb697bae",
"transactionIndex": "0",
"txreceipt_status": "1",
"value": "0"
}
],
"status": "1"
}{
"message": "OK",
"result": [
{
"blockNumber": "6153702",
"callType": "delegatecall",
"contractAddress": "0x883103875d905c11f9ac7dacbfc16deb39655361",
"errCode": "",
"from": "0x2ca1e3f250f56f1761b9a52bc42db53986085eff",
"gas": "814937",
"gasUsed": "536262",
"index": "0",
"input": "",
"isError": "0",
"timeStamp": "1534362606",
"to": "",
"transactionHash": "0xd65b788c610949704a5f9aac2228c7c777434dfe11c863a12306f57fcbd8cdbb",
"type": "call",
"value": "5488334153118633"
}
],
"status": "1"
}{
"message": "OK",
"result": [
{
"blockHash": "0x6169c5dc05d0051564ba3eae8ebfbdefda640c5f5ffc095846b8aed0b44f64ea",
"blockNumber": "5997843",
"confirmations": "199384",
"contractAddress": "0x9f8f72aa9304c8b593d555f12ef6589cc3a579a2",
"cumulativeGasUsed": "1043649",
"from": "0x4e83362442b8d1bec281594cea3050c8eb01311c",
"gas": "44758",
"gasPrice": "7000000000",
"gasUsed": "37298",
"hash": "0xd65b788c610949704a5f9aac2228c7c777434dfe11c863a12306f57fcbd8cdbb",
"input": "0xa9059cbb00000000000000000000000021e21ba085289f81a86921de890eed30f1ad23750000000000000000000000000000000000000000000000008ac7230489e80000",
"logIndex": "0",
"nonce": "765",
"timeStamp": "1532086946",
"to": "0x21e21ba085289f81a86921de890eed30f1ad2375",
"tokenDecimal": "18",
"tokenName": "Maker",
"tokenSymbol": "MKR",
"transactionIndex": "27",
"value": "10000000000000000000"
}
],
"status": "1"
}{
"message": "OK",
"result": "135499",
"status": "1"
}{
"message": "OK",
"result": "135499",
"status": "1"
}{
"message": "OK",
"result": [
{
"address": "0x3870c57fbf1d7e49b154269331c7bc66c64d8857",
"balance": "3790064387342000000",
"stale": false
},
{
"address": "0x497d69ae30d7cca0aa84d647c6d85a59a82c16ef",
"balance": "2047176464264000000",
"stale": false
},
{
"address": "0x9233042b8e9e03d5dc6454bbbe5aee83818ff103",
"balance": "444111960222208758647",
"stale": false
}
],
"status": "1"
}https://fonscan.io/api
?module=account
&action=balance
&address={addressHash}{
"message": "OK",
"result": "663046792267785498951364",
"status": "1"
}https://fonscan.io/api
?module=account
&action=balancemulti
&address={addressHash1,addressHash2,addressHash3}{
"message": "OK",
"result": [
{
"account": "0xddbd2b932c763ba5b1b7ae3b362eac3e8d40121a",
"balance": "40807168566070000000000",
"stale": true
},
{
"account": "0x63a9975ba31b0b9626b34300f7f627147df1f526",
"balance": "332567136222827062478",
"stale": false
},
{
"account": "0x198ef1ec325a96cc354c7266a038be8b5c558f67",
"balance": "185178830000000000",
"stale": false
}
],
"status": "1"
}https://fonscan.io/api
?module=account
&action=pendingtxlist
&address={addressHash}
&page=1
&offset=5https://fonscan.io/api
?module=account
&action=txlist
&address={addressHash}
&startblock=555555
&endblock=666666
&page=1
&offset=5
&sort=aschttps://fonscan.io/api
?module=account
&action=txlistinternal
&txhash={transactionHash}
&startblock=555555
&endblock=666666
&page=1
&offset=5
&sort=aschttps://fonscan.io/api
?module=account
&action=tokentx
&address={addressHash}
&page=1
&offset=10
&sort=aschttps://fonscan.io/api
?module=account
&action=tokenbalance
&contractaddress={contractAddressHash}
&address={addressHash}https://fonscan.io/api
?module=account
&action=tokenlist
&address={addressHash}{
"message": "OK",
"result": [
{
"balance": "135499",
"contractAddress": "0x0000000000000000000000000000000000000000",
"decimals": "18",
"name": "Example Token",
"symbol": "ET",
"type": "ERC-20"
},
{
"balance": "1",
"contractAddress": "0x0000000000000000000000000000000000000001",
"decimals": "18",
"name": "Example ERC-721 Token",
"symbol": "ET7",
"type": "ERC-721"
}
],
"status": "1"
}https://fonscan.io/api
?module=account
&action=getminedblocks
&address={addressHash}https://fonscan.io/api
?module=account
&action=listaccounts
&address={addressHash}
&page=1
&offset=3