Only this pageAll pages
Powered by GitBook
1 of 10

Curtis Apescan

Loading...

API Endpoints

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Sepolia Testnet

Similarly, all endpoints and parameter formatting remain the same across testnet explorers, you are only required to change the relevant API endpoint URL as follows.

Source attribution via a backlink or a mention that your app is "Powered by Apescan APIs" is required except for personal/private usage.

An API key generated on Apescan ​ can be used across all mainnet and testnet explorers.

Network
URL
Documentation

Mainnet

Curtis

https://api.apescan.io/api
https://docs.apescan.io/
https://api-curtis.apescan.io/api
https://docs.apescan.io/curtis-apescan/

Logs

Below are the list of supported filter parameters:

  • fromBlock, toBlock, address

  • topic0, topic1, topic2, topic3 (32 Bytes per topic)

  • topic0_1_opr (and|or between topic0 & topic1), topic1_2_opr (and|or between topic1 & topic2), topic2_3_opr (and|or between topic2 & topic3), topic0_2_opr (and|or between topic0 & topic2), topic0_3_opr (and|or between topic0 & topic3), topic1_3_opr (and|or between topic1 & topic3)

  • FromBlock & ToBlock accepts the blocknumber (integer, NOT hex) or 'latest' (earliest & pending is NOT supported yet)

  • Topic Operator (opr) choices are either 'and' or 'or' and are restricted to the above choices only

  • FromBlock & ToBlock parameters are required

  • An address and/or topic(X) parameters are required, when multiple topic(X) parameters are used the topicX_X_opr (and|or operator) is also required

For performance & security considerations, only the first 1000 results are return. So please narrow down the filter parameters.

Sample Log API Queries

Get Event Logs from block number 1092029 to 'latest' , where log address = 0x639D4384b429ea4660f377B7A29dAe6d2255090f and topic[0] = 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef

https://api-curtis.apescan.io/api
   ?module=logs
   &action=getLogs
   &fromBlock=1092029
   &toBlock=latest
   &address=0x639D4384b429ea4660f377B7A29dAe6d2255090f
   &topic0=0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
   &apikey=YourApiKeyToken

Get Event Logs from block number 9433622 to block 'latest', where log address = 0x5592ec0cfb4dbc12d3ab100b257153436a1f0fea, topic[0] = 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef 'AND' topic[1] = 0x0000000000000000000000008e811410ce01e0244808af95bba906b8ab77a40b

https://api-curtis.apescan.io/api
   ?module=logs
   &action=getLogs
   &fromBlock=1089604
   &toBlock=latest
   &address=0x64A736Aa55958a41bC1B18590AB7dfCb78444Dd1
   &topic0=0xc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62
   &topic0_1_opr=and
   &topic1=0x000000000000000000000000955866ee0bd3b8b0be4d4ea306670f34b90ef3ed
   &apikey=YourApiKeyToken

The Event Log API was designed to provide an alternative to the native .

Some parameters to take note of

Try this endpoint in your

Try this endpoint in your

📝
eth_getLogs
🔗
browser
🔗
browser

Transactions

Check Contract Execution Status

Returns the status code of a contract execution.

https://api-curtis.apescan.io/api
   ?module=transaction
   &action=getstatus
   &txhash=0x8dac9d2429f2f73cab7db5d26986f77b96552188b1c969a50ce7bff563ffbb6c
   &apikey=YourApiKeyToken

Check Transaction Receipt Status

Returns the status code of a transaction execution.

https://api-curtis.apescan.io/api
   ?module=transaction
   &action=gettxreceiptstatus
   &txhash=0x57fe171a6bcf99669f4bb4a0947a59503f7a88059a9749e3d3ebecda53c08f55
   &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":"0"
   }
}

Accounts

Get Ether Balance for a Single Address

Returns the Ether balance of a given address.

Get Ether Balance for Multiple Addresses in a Single Call

Returns the balance of the accounts from a list of addresses.

Query Parameters

Sample Response

Get a list of 'Normal' Transactions By Address

Returns the list of transactions performed by an address, with optional pagination.

Query Parameters

Sample Response

Get a list of 'Internal' Transactions by Address

Returns the list of internal transactions performed by an address, with optional pagination.

Query Parameters

Sample Response

Get 'Internal Transactions' by Transaction Hash

Returns the list of internal transactions performed within a transaction.

Note : This API endpoint returns a maximum of 10000 records only.

Query Parameters

Sample Response

The isError field returns 0 for successful transactions and 1 for rejected/cancelled transactions.

Get "Internal Transactions" by Block Range

Returns the list of internal transactions performed within a block range, with optional pagination.

Query Parameters

Sample Response

The isError field returns 0 for successful transactions and 1 for rejected/cancelled transactions.

Get a list of 'ERC20 - Token Transfer Events' by Address

Returns the list of ERC-20 tokens transferred by an address, with optional filtering by token contract.

Usage:

  • ERC-20 transfers from an address, specify the address parameter

  • ERC-20 transfers from a contract address, specify the contract address parameter

  • ERC-20 transfers from an address filtered by a token contract, specify both address and contract address parameters.

Query Parameters

Sample Response

Get a list of 'ERC721 - Token Transfer Events' by Address

Returns the list of ERC-721 ( NFT ) tokens transferred by an address, with optional filtering by token contract

Usage:

  • ERC-721 transfers from an address, specify the address parameter

  • ERC-721 transfers from a contract address, specify the contract address parameter

  • ERC-721 transfers from an address filtered by a token contract, specify both address and contract address parameters.

Query Parameters

Sample Response

Get list of Blocks Mined by Address

Returns the list of blocks mined by an address.

Query Parameters

Sample Response

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.

Note: Only applicable for post transactions.

Try this endpoint in your

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

Try this endpoint in your

Query Parameters

Parameter
Description

Sample Response

Tip: The result is returned in

Convert Ethereum units using our

Try this endpoint in your

Parameter
Description

Tip: The result is returned in

Convert Ethereum units using our

​​ ​ Note : This API endpoint returns a maximum of 10000 records only.

Try this endpoint in your

Parameter
Description

Tip: Specify a smaller startblock and endblock range for faster search results.

Note : This API endpoint returns a maximum of 10000 records only.

Try this endpoint in your

Parameter
Description

Tip: Specify a smaller startblock and endblock range for faster search results

Try this endpoint in your

Parameter
Description

​​ Note : This API endpoint returns a maximum of 10000 records only.

Try this endpoint in your

Parameter
Description

Try this endpoint in your

Parameter
Description

Try this endpoint in your

Parameter
Description

Try this endpoint in your

Parameter
Description

Note : The timeStamp is represented in

📖
📖
🔗
browser
📝
Byzantium Fork
🔗
browser
https://api-curtis.apescan.io/api
   ?module=account
   &action=balance
   &address=0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd
   &tag=latest
   &apikey=YourApiKeyToken
https://api-curtis.apescan.io/api
   ?module=account
   &action=balancemulti
   &address=https://api-curtis.apescan.io/api?module=account&action=balance&address=0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd,0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd,0x8a5847fd0e592b058c026c5fdc322aee834b87f5&tag=latest&apikey=YourApiKeyToken,0x63a9dbCe75413036B2B778E670aaBd4493aAF9F3,0xd82b6aB1f20A21484fA5E28221B95425dddC5E8E
   &apikey=YourApiKeyToken

address

the strings representing the addresses to check for balance, separated by , commas up to 20 addresses per call

tag

the integer pre-defined block parameter, either earliest, pending or latest

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "account":"0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd",
         "balance":"206796937658929992503000"
      },
      {
         "account":"0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd",
         "balance":"206796937658929992503000"
      },
      {
         "account":"0x8a5847fd0e592b058c026c5fdc322aee834b87f5",
         "balance":"16288712393992050891"
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=txlist
   &address=0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd
   &startblock=0
   &endblock=99999999
   &page=1
   &offset=10
   &sort=asc
   &apikey=YourApiKeyToken

address

the string representing the addresses to check for balance

startblock

the integer block number to start searching for transactions

endblock

the integer block number to stop searching for transactions

page

the integer page number, if pagination is enabled

offset

the number of transactions displayed per page

sort

the sorting preference, use asc to sort by ascending and desc to sort by descending

{
   "status":"1",
   "message":"OK-Missing/Invalid API Key, rate limit of 1/5sec applied",
   "result":[
      {
         "blockNumber":"1037571",
         "timeStamp":"1651759857",
         "hash":"0x710e53707c79dd438a8bc3db2a45a123af6dba0d4a653a134035306d11f415fd",
         "nonce":"5",
         "blockHash":"0x64201f8940cee65186f64adb68a99fe3da0450bc9490617aeedd08f80cb8e29b",
         "transactionIndex":"0",
         "from":"0x10f5d45854e038071485ac9e402308cf80d2d2fe",
         "to":"0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd",
         "value":"50000000000000000000000",
         "gas":"21000",
         "gasPrice":"1500000007",
         "isError":"0",
         "txreceipt_status":"1",
         "input":"0x",
         "contractAddress":"",
         "cumulativeGasUsed":"21000",
         "gasUsed":"21000",
         "confirmations":"48476"
      },
      {
         "blockNumber":"1061942",
         "timeStamp":"1652077697",
         "hash":"0x7734cae034c8a7198a5988c5ae927adf30cf77d2cbb25ed996278e402c0e0032",
         "nonce":"0",
         "blockHash":"0xedc7119adb34edf5480fe52f090dedbef647948ffc91806afe7d8b0182781b40",
         "transactionIndex":"0",
         "from":"0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd",
         "to":"0x93e973436cd7757f21b1c947599f67082624a721",
         "value":"1000000000000000",
         "gas":"21000",
         "gasPrice":"2000000007",
         "isError":"0",
         "txreceipt_status":"1",
         "input":"0x",
         "contractAddress":"",
         "cumulativeGasUsed":"21000",
         "gasUsed":"21000",
         "confirmations":"24105"
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=txlistinternal
   &address=0xa4fadaa5e8577fee5799e2bd9615014013b45c5d
   &startblock=0
   &endblock=99999999
   &page=1
   &offset=10
   &sort=asc
   &apikey=YourApiKeyToken

address

the string representing the addresses to check for balance

startblock

the integer block number to start searching for transactions

endblock

the integer block number to stop searching for transactions

page

the integer page number, if pagination is enabled

offset

the number of transactions displayed per page

sort

the sorting preference, use asc to sort by ascending and desc to sort by descending

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "blockNumber":"765371",
         "timeStamp":"1648218619",
         "hash":"0xcb6609b6f9133fc1bfd189fb52ed616968a5f7c56af8da3bd6724f7655fe5f78",
         "from":"0x02f11eabf51d28bb0bae795e256ce52161d65c2b",
         "to":"0xa4fadaa5e8577fee5799e2bd9615014013b45c5d",
         "value":"10000000000000000",
         "contractAddress":"",
         "input":"",
         "type":"call",
         "gas":"2300",
         "gasUsed":"0",
         "traceId":"0_1",
         "isError":"0",
         "errCode":""
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=txlistinternal
   &txhash=0xb730ee4dc8d0274be31d1e31ed7fe9749d7a67c0e35b297f3c2d10b06c1f6f1e
   &apikey=YourApiKeyToken

txhash

the string representing the transaction hash to check for internal transactions

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "blockNumber":"312070",
         "timeStamp":"1639592011",
         "from":"0xa234eead085ac80a4f7cc5220789e048373f0f1e",
         "to":"",
         "value":"0",
         "contractAddress":"0x63a19c2868e469ffc2c8346c93f81ff6e140ffaf",
         "input":"",
         "type":"create",
         "gas":"8504616",
         "gasUsed":"134349",
         "isError":"0",
         "errCode":""
      },
     
      {
         "blockNumber":"312070",
         "timeStamp":"1639592011",
         "from":"0xa234eead085ac80a4f7cc5220789e048373f0f1e",
         "to":"",
         "value":"0",
         "contractAddress":"0xe05ba0186f4a5a5d0eb8a5394d8413411ffd321c",
         "input":"",
         "type":"create",
         "gas":"1119086",
         "gasUsed":"134349",
         "isError":"0",
         "errCode":""
      },
      {
         "blockNumber":"312070",
         "timeStamp":"1639592011",
         "from":"0xa234eead085ac80a4f7cc5220789e048373f0f1e",
         "to":"",
         "value":"0",
         "contractAddress":"0x7b99f4f6260c3cd12984e8d2b83eaf51d44e2254",
         "input":"",
         "type":"create",
         "gas":"134349",
         "gasUsed":"134349",
         "isError":"0",
         "errCode":""
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=txlistinternal
   &startblock=484887
   &endblock=765371
   &page=1
   &offset=10
   &sort=asc
   &apikey=YourApiKeyToken

startblock

the integer block number to start searching for transactions

endblock

the integer block number to stop searching for transactions

page

the integer page number, if pagination is enabled

offset

the number of transactions displayed per page

sort

the sorting preference, use asc to sort by ascending and desc to sort by descending

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "blockNumber":"484887",
         "timeStamp":"1644613109",
         "hash":"0xc3ff81084b157b7d695f3df8636eebcacb6ca938c62c3102492978dbe8f5879b",
         "from":"0x9bcdb32c4d0f0992bfb926a28ee2cb7b9d9750cc",
         "to":"0x105083929bf9bb22c26cb1777ec92661170d4285",
         "value":"3906875000000000000000",
         "contractAddress":"",
         "input":"",
         "type":"call",
         "gas":"2300",
         "gasUsed":"0",
         "traceId":"0_1",
         "isError":"0",
         "errCode":""
      },
      {
         "blockNumber":"498080",
         "timeStamp":"1644787132",
         "hash":"0x1ab55087625084f2e1462a49f13a36d0996bff67da3cb4e7250e110e922274bd",
         "from":"0x9bcdb32c4d0f0992bfb926a28ee2cb7b9d9750cc",
         "to":"0x84e9304fa9aafc5e70090eadda9ac2c76d93ad51",
         "value":"1491314746532500000000",
         "contractAddress":"",
         "input":"",
         "type":"call",
         "gas":"2300",
         "gasUsed":"0",
         "traceId":"0_1",
         "isError":"0",
         "errCode":""
      },
      {
         "blockNumber":"518080",
         "timeStamp":"1645046610",
         "hash":"0x1b08041082471d96bbf5362db688f447ce8c775d242998a3b190211560911d86",
         "from":"0x9bcdb32c4d0f0992bfb926a28ee2cb7b9d9750cc",
         "to":"0x105083929bf9bb22c26cb1777ec92661170d4285",
         "value":"4250625000000000000000",
         "contractAddress":"",
         "input":"",
         "type":"call",
         "gas":"2300",
         "gasUsed":"0",
         "traceId":"0_1",
         "isError":"0",
         "errCode":""
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=tokentx
   &contractaddress=0xa808b14492AC6E33419ac16112154D40D0A4AEBA
   &address=0x105083929bf9bb22c26cb1777ec92661170d4285
   &page=1
   &offset=100
   &startblock=0
   &endblock=99999999
   &sort=asc
   &apikey=YourApiKeyToken

address

the string representing the address to check for balance

contractaddress

the string representing the token contract address to check for balance

page

the integer page number, if pagination is enabled

offset

the number of transactions displayed per page

startblock

the integer block number to start searching for transactions

endblock

the integer block number to stop searching for transactions

sort

the sorting preference, use asc to sort by ascending and desc to sort by descending

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "blockNumber":"496492",
         "timeStamp":"1644767322",
         "hash":"0x433994d50986d0c021098adadac4f4a89249c51fb4ea372e553af6ee6fc0965c",
         "nonce":"20",
         "blockHash":"0x29394a72a707d77a167a1eec53d33940b5a366a2c01cd10094c18a15517ff44b",
         "from":"0x84e9304fa9aafc5e70090eadda9ac2c76d93ad51",
         "contractAddress":"0xa808b14492ac6e33419ac16112154d40d0a4aeba",
         "to":"0x105083929bf9bb22c26cb1777ec92661170d4285",
         "value":"100000000000000000000000",
         "tokenName":"Vitcoin",
         "tokenSymbol":"VTC",
         "tokenDecimal":"18",
         "transactionIndex":"0",
         "gas":"53517",
         "gasPrice":"1000000007",
         "gasUsed":"35678",
         "cumulativeGasUsed":"35678",
         "input":"deprecated",
         "confirmations":"589603"
      },
      {
         "blockNumber":"886779",
         "timeStamp":"1649789803",
         "hash":"0x1071238546873837a9b03736a8ca26ce379e66999f6e74748dd919890232e34a",
         "nonce":"28",
         "blockHash":"0xd1a3ad751eba89ac664e691844a5a44361d8c801ce6bbfe31c03f1d7970e28f7",
         "from":"0x84e9304fa9aafc5e70090eadda9ac2c76d93ad51",
         "contractAddress":"0xa808b14492ac6e33419ac16112154d40d0a4aeba",
         "to":"0x105083929bf9bb22c26cb1777ec92661170d4285",
         "value":"999900000000000000000000000",
         "tokenName":"Vitcoin",
         "tokenSymbol":"VTC",
         "tokenDecimal":"18",
         "transactionIndex":"0",
         "gas":"53553",
         "gasPrice":"1500000007",
         "gasUsed":"30902",
         "cumulativeGasUsed":"30902",
         "input":"deprecated",
         "confirmations":"199316"
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=tokennfttx
   &contractaddress=0x03e73ef97303e11703864a5404d71351ef61d8f8
   &address=0xb541f07fd1ae0a0d0244982e847a072436ee67db
   &page=1
   &offset=100
   &startblock=0
   &endblock=99999999
   &sort=asc
   &apikey=YourApiKeyToken

address

the string representing the address to check for balance

contractaddress

the string representing the token contract address to check for balance

page

the integer page number, if pagination is enabled

offset

the number of transactions displayed per page

startblock

the integer block number to start searching for transactions

endblock

the integer block number to stop searching for transactions

sort

the sorting preference, use asc to sort by ascending and desc to sort by descending

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "blockNumber":"8618316",
         "timeStamp":"1621510305",
         "hash":"0x9c10c45f47088060c9493e88361d7eedbc3b4dd2772e0b1deeb84d46a5c8e623",
         "nonce":"338",
         "blockHash":"0x2b690dd69f868351e179068befc3cd3f6d2621a8d425093d3980a24ac1347179",
         "from":"0x0000000000000000000000000000000000000000",
         "contractAddress":"0x03e73ef97303e11703864a5404d71351ef61d8f8",
         "to":"0xb541f07fd1ae0a0d0244982e847a072436ee67db",
         "tokenID":"10001",
         "tokenName":"Artifex",
         "tokenSymbol":"ARTIFEX",
         "tokenDecimal":"0",
         "transactionIndex":"0",
         "gas":"5016425",
         "gasPrice":"2051200000",
         "gasUsed":"5016425",
         "cumulativeGasUsed":"5016425",
         "input":"deprecated",
         "confirmations":"927169"
      },
      {
         "blockNumber":"8618316",
         "timeStamp":"1621510305",
         "hash":"0x9c10c45f47088060c9493e88361d7eedbc3b4dd2772e0b1deeb84d46a5c8e623",
         "nonce":"338",
         "blockHash":"0x2b690dd69f868351e179068befc3cd3f6d2621a8d425093d3980a24ac1347179",
         "from":"0x0000000000000000000000000000000000000000",
         "contractAddress":"0x03e73ef97303e11703864a5404d71351ef61d8f8",
         "to":"0xb541f07fd1ae0a0d0244982e847a072436ee67db",
         "tokenID":"10002",
         "tokenName":"Artifex",
         "tokenSymbol":"ARTIFEX",
         "tokenDecimal":"0",
         "transactionIndex":"0",
         "gas":"5016425",
         "gasPrice":"2051200000",
         "gasUsed":"5016425",
         "cumulativeGasUsed":"5016425",
         "input":"deprecated",
         "confirmations":"927169"
      }
   ]
}
https://api-curtis.apescan.io/api
   ?module=account
   &action=getminedblocks
   &address=0x3d080421c9DD5fB387d6e3124f7E1C241ADE9568
   &blocktype=blocks
   &page=1
   &offset=10
   &apikey=YourApiKeyToken

address

the string representing the address to check for balance

blocktype

the string pre-defined block type, either blocks for canonical blocks or uncles for uncle blocks only

page

the integer page number, if pagination is enabled

offset

the number of transactions displayed per page

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "blockNumber":"1088398",
         "timeStamp":"1652415312",
         "blockReward":"2000000000000000000"
      },
      {
         "blockNumber":"1088395",
         "timeStamp":"1652415289",
         "blockReward":"2000000000000000000"
      },
      {
         "blockNumber":"1088361",
         "timeStamp":"1652414946",
         "blockReward":"2000000000000000000"
      }
   ]
}
📝
💡
📝
💡
📝
🔗
browser

address

the string representing the address to check for balance

tag

the string pre-defined block parameter, either earliest, pending or latest

{
   "status":"1",
   "message":"OK",
   "result":"206796937658929992503000" 
}
📖
wei.
Unit Converter.
🔗
browser
📖
wei.
Unit Converter.
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
⏳
Unix timestamp.

Blocks

Get Block And Uncle Rewards by BlockNo

Returns the block reward and 'Uncle' block rewards.

https://api-curtis.apescan.io/api
   ?module=block
   &action=getblockreward
   &blockno=1090932
   &apikey=YourApiKeyToken

Get Estimated Block Countdown Time by BlockNo

Returns the estimated time remaining, in seconds, until a certain block is mined.

https://api-curtis.apescan.io/api
   ?module=block
   &action=getblockcountdown
   &blockno=1090932
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

blockno

the integer block number to estimate time remaining to be mined eg. 12697906

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":{
      "CurrentBlock":"9548810",
      "CountdownBlock":"9588666",
      "RemainingBlock":"39856",
      "EstimateTimeInSec":"577927.0"
   }
}

Get Block Number by Timestamp

Returns the block number that was mined at a certain timestamp.

https://api-curtis.apescan.io/api
   ?module=block
   &action=getblocknobytime
   &timestamp=1652459409
   &closest=before
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

timestamp

the integer representing the Unix timestamp in seconds.

closest

the closest available block to the provided timestamp, either before or after

Sample Response

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

Tokens

Get ERC20-Token TotalSupply by ContractAddress

Returns the current amount of an ERC-20 token in circulation.

https://api-curtis.apescan.io/api
   ?module=stats
   &action=tokensupply
   &contractaddress=0x15f0ca26781c3852f8166ed2ebce5d18265cceb7
   &apikey=YourApiKeyToken

Get ERC20-Token Account Balance for TokenContractAddress

Returns the current balance of an ERC-20 token of an address.

https://api-curtis.apescan.io/api
   ?module=account
   &action=tokenbalance
   &contractaddress=0x15f0ca26781c3852f8166ed2ebce5d18265cceb7
   &address=0x89c184f7c342b106f37c486a38453a1af7db10b6
   &tag=latest&apikey=YourApiKeyToken

Query Parameters

Parameter
Description

contractaddress

the contract address of the ERC-20 token

address

the string representing the address to check for token balance

Sample Response

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

Eg. a token with a balance of 215.241526476136819398 and 18 decimal places will be returned as 215241526476136819398

Contracts

Returns the Contract Application Binary Interface ( ABI ) of a verified smart contract.

https://api.etherscan.io/api
   ?module=contract
   &action=getabi
   &address=0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

address

the contract address that has a verified source code

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":"[{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"proposals\",\"outputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"},{\"name\":\"description\",\"type\":\"string\"},{\"name\":\"votingDeadline\",\"type\":\"uint256\"},{\"name\":\"open\",\"type\":\"bool\"},{\"name\":\"proposalPassed\",\"type\":\"bool\"},{\"name\":\"proposalHash\",\"type\":\"bytes32\"},{\"name\":\"proposalDeposit\",\"type\":\"uint256\"},{\"name\":\"newCurator\",\"type\":\"bool\"},{\"name\":\"yea\",\"type\":\"uint256\"},{\"name\":\"nay\",\"type\":\"uint256\"},{\"name\":\"creator\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_spender\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"minTokensToCreate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"rewardAccount\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"daoCreator\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"divisor\",\"outputs\":[{\"name\":\"divisor\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"extraBalance\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_transactionData\",\"type\":\"bytes\"}],\"name\":\"executeProposal\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"unblockMe\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalRewardToken\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"actualBalance\",\"outputs\":[{\"name\":\"_actualBalance\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"closingTime\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"allowedRecipients\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferWithoutReward\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"refund\",\"outputs\":[],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_recipient\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_description\",\"type\":\"string\"},{\"name\":\"_transactionData\",\"type\":\"bytes\"},{\"name\":\"_debatingPeriod\",\"type\":\"uint256\"},{\"name\":\"_newCurator\",\"type\":\"bool\"}],\"name\":\"newProposal\",\"outputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"DAOpaidOut\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"minQuorumDivisor\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_newContract\",\"type\":\"address\"}],\"name\":\"newContract\",\"outputs\":[],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_owner\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"balance\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_recipient\",\"type\":\"address\"},{\"name\":\"_allowed\",\"type\":\"bool\"}],\"name\":\"changeAllowedRecipients\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"halveMinQuorum\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"paidOut\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_newCurator\",\"type\":\"address\"}],\"name\":\"splitDAO\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"DAOrewardAccount\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"proposalDeposit\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"numberOfProposals\",\"outputs\":[{\"name\":\"_numberOfProposals\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"lastTimeMinQuorumMet\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_toMembers\",\"type\":\"bool\"}],\"name\":\"retrieveDAOReward\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"receiveEther\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isFueled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_tokenHolder\",\"type\":\"address\"}],\"name\":\"createTokenProxy\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"}],\"name\":\"getNewDAOAddress\",\"outputs\":[{\"name\":\"_newDAO\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_supportsProposal\",\"type\":\"bool\"}],\"name\":\"vote\",\"outputs\":[{\"name\":\"_voteID\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"getMyReward\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"rewardToken\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferFromWithoutReward\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_owner\",\"type\":\"address\"},{\"name\":\"_spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"remaining\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalDeposit\",\"type\":\"uint256\"}],\"name\":\"changeProposalDeposit\",\"outputs\":[],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"blocked\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"curator\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_recipient\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_transactionData\",\"type\":\"bytes\"}],\"name\":\"checkProposalCode\",\"outputs\":[{\"name\":\"_codeChecksOut\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"privateCreation\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"inputs\":[{\"name\":\"_curator\",\"type\":\"address\"},{\"name\":\"_daoCreator\",\"type\":\"address\"},{\"name\":\"_proposalDeposit\",\"type\":\"uint256\"},{\"name\":\"_minTokensToCreate\",\"type\":\"uint256\"},{\"name\":\"_closingTime\",\"type\":\"uint256\"},{\"name\":\"_privateCreation\",\"type\":\"address\"}],\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"FuelingToDate\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"CreatedToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Refund\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"proposalID\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"newCurator\",\"type\":\"bool\"},{\"indexed\":false,\"name\":\"description\",\"type\":\"string\"}],\"name\":\"ProposalAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"proposalID\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"position\",\"type\":\"bool\"},{\"indexed\":true,\"name\":\"voter\",\"type\":\"address\"}],\"name\":\"Voted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"proposalID\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"result\",\"type\":\"bool\"},{\"indexed\":false,\"name\":\"quorum\",\"type\":\"uint256\"}],\"name\":\"ProposalTallied\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_newCurator\",\"type\":\"address\"}],\"name\":\"NewCurator\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_recipient\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_allowed\",\"type\":\"bool\"}],\"name\":\"AllowedRecipientChanged\",\"type\":\"event\"}]"
}

Returns the Solidity source code of a verified smart contract.

https://api.etherscan.io/api
   ?module=contract
   &action=getsourcecode
   &address=0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413
   &apikey=YourApiKeyToken 

Query Parameters

Parameter
Description

address

the contract address that has a verified source code

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "SourceCode":"/*\n\n- Bytecode Verification performed was compared on second iteration -\n\nThis file is part of the DAO.\n\nThe DAO is free software: you can redistribute it and/or modify\nit under the terms of the GNU lesser General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThe DAO is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\nGNU lesser General Public License for more details.\n\nYou should have received a copy of the GNU lesser General Public License\nalong with the DAO.  If not, see <http://www.gnu.org/licenses/>.\n*/\n\n\n/*\nBasic, standardized Token contract with no \"premine\". Defines the functions to\ncheck token balances, send tokens, send tokens on behalf of a 3rd party and the\ncorresponding approval process. Tokens need to be created by a derived\ncontract (e.g. TokenCreation.sol).\n\nThank you ConsenSys, this contract originated from:\nhttps://github.com/ConsenSys/Tokens/blob/master/Token_Contracts/contracts/Standard_Token.sol\nWhich is itself based on the Ethereum standardized contract APIs:\nhttps://github.com/ethereum/wiki/wiki/Standardized_Contract_APIs\n*/\n\n/// @title Standard Token Contract.\n\ncontract TokenInterface {\n    mapping (address => uint256) balances;\n    mapping (address => mapping (address => uint256)) allowed;\n\n    /// Total amount of tokens\n    uint256 public totalSupply;\n\n    /// @param _owner The address from which the balance will be retrieved\n    /// @return The balance\n    function balanceOf(address _owner) constant returns (uint256 balance);\n\n    /// @notice Send `_amount` tokens to `_to` from `msg.sender`\n    /// @param _to The address of the recipient\n    /// @param _amount The amount of tokens to be transferred\n    /// @return Whether the transfer was successful or not\n    function transfer(address _to, uint256 _amount) returns (bool success);\n\n    /// @notice Send `_amount` tokens to `_to` from `_from` on the condition it\n    /// is approved by `_from`\n    /// @param _from The address of the origin of the transfer\n    /// @param _to The address of the recipient\n    /// @param _amount The amount of tokens to be transferred\n    /// @return Whether the transfer was successful or not\n    function transferFrom(address _from, address _to, uint256 _amount) returns (bool success);\n\n    /// @notice `msg.sender` approves `_spender` to spend `_amount` tokens on\n    /// its behalf\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @param _amount The amount of tokens to be approved for transfer\n    /// @return Whether the approval was successful or not\n    function approve(address _spender, uint256 _amount) returns (bool success);\n\n    /// @param _owner The address of the account owning tokens\n    /// @param _spender The address of the account able to transfer the tokens\n    /// @return Amount of remaining tokens of _owner that _spender is allowed\n    /// to spend\n    function allowance(\n        address _owner,\n        address _spender\n    ) constant returns (uint256 remaining);\n\n    event Transfer(address indexed _from, address indexed _to, uint256 _amount);\n    event Approval(\n        address indexed _owner,\n        address indexed _spender,\n        uint256 _amount\n    );\n}\n\n\ncontract Token is TokenInterface {\n    // Protects users by preventing the execution of method calls that\n    // inadvertently also transferred ether\n    modifier noEther() {if (msg.value > 0) throw; _}\n\n    function balanceOf(address _owner) constant returns (uint256 balance) {\n        return balances[_owner];\n    }\n\n    function transfer(address _to, uint256 _amount) noEther returns (bool success) {\n        if (balances[msg.sender] >= _amount && _amount > 0) {\n            balances[msg.sender] -= _amount;\n            balances[_to] += _amount;\n            Transfer(msg.sender, _to, _amount);\n            return true;\n        } else {\n           return false;\n        }\n    }\n\n    function transferFrom(\n        address _from,\n        address _to,\n        uint256 _amount\n    ) noEther returns (bool success) {\n\n        if (balances[_from] >= _amount\n            && allowed[_from][msg.sender] >= _amount\n            && _amount > 0) {\n\n            balances[_to] += _amount;\n            balances[_from] -= _amount;\n            allowed[_from][msg.sender] -= _amount;\n            Transfer(_from, _to, _amount);\n            return true;\n        } else {\n            return false;\n        }\n    }\n\n    function approve(address _spender, uint256 _amount) returns (bool success) {\n        allowed[msg.sender][_spender] = _amount;\n        Approval(msg.sender, _spender, _amount);\n        return true;\n    }\n\n    function allowance(address _owner, address _spender) constant returns (uint256 remaining) {\n        return allowed[_owner][_spender];\n    }\n}\n\n\n/*\nThis file is part of the DAO.\n\nThe DAO is free software: you can redistribute it and/or modify\nit under the terms of the GNU lesser General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThe DAO is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\nGNU lesser General Public License for more details.\n\nYou should have received a copy of the GNU lesser General Public License\nalong with the DAO.  If not, see <http://www.gnu.org/licenses/>.\n*/\n\n\n/*\nBasic account, used by the DAO contract to separately manage both the rewards \nand the extraBalance accounts. \n*/\n\ncontract ManagedAccountInterface {\n    // The only address with permission to withdraw from this account\n    address public owner;\n    // If true, only the owner of the account can receive ether from it\n    bool public payOwnerOnly;\n    // The sum of ether (in wei) which has been sent to this contract\n    uint public accumulatedInput;\n\n    /// @notice Sends `_amount` of wei to _recipient\n    /// @param _amount The amount of wei to send to `_recipient`\n    /// @param _recipient The address to receive `_amount` of wei\n    /// @return True if the send completed\n    function payOut(address _recipient, uint _amount) returns (bool);\n\n    event PayOut(address indexed _recipient, uint _amount);\n}\n\n\ncontract ManagedAccount is ManagedAccountInterface{\n\n    // The constructor sets the owner of the account\n    function ManagedAccount(address _owner, bool _payOwnerOnly) {\n        owner = _owner;\n        payOwnerOnly = _payOwnerOnly;\n    }\n\n    // When the contract receives a transaction without data this is called. \n    // It counts the amount of ether it receives and stores it in \n    // accumulatedInput.\n    function() {\n        accumulatedInput += msg.value;\n    }\n\n    function payOut(address _recipient, uint _amount) returns (bool) {\n        if (msg.sender != owner || msg.value > 0 || (payOwnerOnly && _recipient != owner))\n            throw;\n        if (_recipient.call.value(_amount)()) {\n            PayOut(_recipient, _amount);\n            return true;\n        } else {\n            return false;\n        }\n    }\n}\n/*\nThis file is part of the DAO.\n\nThe DAO is free software: you can redistribute it and/or modify\nit under the terms of the GNU lesser General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThe DAO is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\nGNU lesser General Public License for more details.\n\nYou should have received a copy of the GNU lesser General Public License\nalong with the DAO.  If not, see <http://www.gnu.org/licenses/>.\n*/\n\n\n/*\n * Token Creation contract, used by the DAO to create its tokens and initialize\n * its ether. Feel free to modify the divisor method to implement different\n * Token Creation parameters\n*/\n\n\ncontract TokenCreationInterface {\n\n    // End of token creation, in Unix time\n    uint public closingTime;\n    // Minimum fueling goal of the token creation, denominated in tokens to\n    // be created\n    uint public minTokensToCreate;\n    // True if the DAO reached its minimum fueling goal, false otherwise\n    bool public isFueled;\n    // For DAO splits - if privateCreation is 0, then it is a public token\n    // creation, otherwise only the address stored in privateCreation is\n    // allowed to create tokens\n    address public privateCreation;\n    // hold extra ether which has been sent after the DAO token\n    // creation rate has increased\n    ManagedAccount public extraBalance;\n    // tracks the amount of wei given from each contributor (used for refund)\n    mapping (address => uint256) weiGiven;\n\n    /// @dev Constructor setting the minimum fueling goal and the\n    /// end of the Token Creation\n    /// @param _minTokensToCreate Minimum fueling goal in number of\n    ///        Tokens to be created\n    /// @param _closingTime Date (in Unix time) of the end of the Token Creation\n    /// @param _privateCreation Zero means that the creation is public.  A\n    /// non-zero address represents the only address that can create Tokens\n    /// (the address can also create Tokens on behalf of other accounts)\n    // This is the constructor: it can not be overloaded so it is commented out\n    //  function TokenCreation(\n        //  uint _minTokensTocreate,\n        //  uint _closingTime,\n        //  address _privateCreation\n    //  );\n\n    /// @notice Create Token with `_tokenHolder` as the initial owner of the Token\n    /// @param _tokenHolder The address of the Tokens's recipient\n    /// @return Whether the token creation was successful\n    function createTokenProxy(address _tokenHolder) returns (bool success);\n\n    /// @notice Refund `msg.sender` in the case the Token Creation did\n    /// not reach its minimum fueling goal\n    function refund();\n\n    /// @return The divisor used to calculate the token creation rate during\n    /// the creation phase\n    function divisor() constant returns (uint divisor);\n\n    event FuelingToDate(uint value);\n    event CreatedToken(address indexed to, uint amount);\n    event Refund(address indexed to, uint value);\n}\n\n\ncontract TokenCreation is TokenCreationInterface, Token {\n    function TokenCreation(\n        uint _minTokensToCreate,\n        uint _closingTime,\n        address _privateCreation) {\n\n        closingTime = _closingTime;\n        minTokensToCreate = _minTokensToCreate;\n        privateCreation = _privateCreation;\n        extraBalance = new ManagedAccount(address(this), true);\n    }\n\n    function createTokenProxy(address _tokenHolder) returns (bool success) {\n        if (now < closingTime && msg.value > 0\n            && (privateCreation == 0 || privateCreation == msg.sender)) {\n\n            uint token = (msg.value * 20) / divisor();\n            extraBalance.call.value(msg.value - token)();\n            balances[_tokenHolder] += token;\n            totalSupply += token;\n            weiGiven[_tokenHolder] += msg.value;\n            CreatedToken(_tokenHolder, token);\n            if (totalSupply >= minTokensToCreate && !isFueled) {\n                isFueled = true;\n                FuelingToDate(totalSupply);\n            }\n            return true;\n        }\n        throw;\n    }\n\n    function refund() noEther {\n        if (now > closingTime && !isFueled) {\n            // Get extraBalance - will only succeed when called for the first time\n            if (extraBalance.balance >= extraBalance.accumulatedInput())\n                extraBalance.payOut(address(this), extraBalance.accumulatedInput());\n\n            // Execute refund\n            if (msg.sender.call.value(weiGiven[msg.sender])()) {\n                Refund(msg.sender, weiGiven[msg.sender]);\n                totalSupply -= balances[msg.sender];\n                balances[msg.sender] = 0;\n                weiGiven[msg.sender] = 0;\n            }\n        }\n    }\n\n    function divisor() constant returns (uint divisor) {\n        // The number of (base unit) tokens per wei is calculated\n        // as `msg.value` * 20 / `divisor`\n        // The fueling period starts with a 1:1 ratio\n        if (closingTime - 2 weeks > now) {\n            return 20;\n        // Followed by 10 days with a daily creation rate increase of 5%\n        } else if (closingTime - 4 days > now) {\n            return (20 + (now - (closingTime - 2 weeks)) / (1 days));\n        // The last 4 days there is a constant creation rate ratio of 1:1.5\n        } else {\n            return 30;\n        }\n    }\n}\n/*\nThis file is part of the DAO.\n\nThe DAO is free software: you can redistribute it and/or modify\nit under the terms of the GNU lesser General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThe DAO is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\nGNU lesser General Public License for more details.\n\nYou should have received a copy of the GNU lesser General Public License\nalong with the DAO.  If not, see <http://www.gnu.org/licenses/>.\n*/\n\n\n/*\nStandard smart contract for a Decentralized Autonomous Organization (DAO)\nto automate organizational governance and decision-making.\n*/\n\n\ncontract DAOInterface {\n\n    // The amount of days for which people who try to participate in the\n    // creation by calling the fallback function will still get their ether back\n    uint constant creationGracePeriod = 40 days;\n    // The minimum debate period that a generic proposal can have\n    uint constant minProposalDebatePeriod = 2 weeks;\n    // The minimum debate period that a split proposal can have\n    uint constant minSplitDebatePeriod = 1 weeks;\n    // Period of days inside which it's possible to execute a DAO split\n    uint constant splitExecutionPeriod = 27 days;\n    // Period of time after which the minimum Quorum is halved\n    uint constant quorumHalvingPeriod = 25 weeks;\n    // Period after which a proposal is closed\n    // (used in the case `executeProposal` fails because it throws)\n    uint constant executeProposalPeriod = 10 days;\n    // Denotes the maximum proposal deposit that can be given. It is given as\n    // a fraction of total Ether spent plus balance of the DAO\n    uint constant maxDepositDivisor = 100;\n\n    // Proposals to spend the DAO's ether or to choose a new Curator\n    Proposal[] public proposals;\n    // The quorum needed for each proposal is partially calculated by\n    // totalSupply / minQuorumDivisor\n    uint public minQuorumDivisor;\n    // The unix time of the last time quorum was reached on a proposal\n    uint  public lastTimeMinQuorumMet;\n\n    // Address of the curator\n    address public curator;\n    // The whitelist: List of addresses the DAO is allowed to send ether to\n    mapping (address => bool) public allowedRecipients;\n\n    // Tracks the addresses that own Reward Tokens. Those addresses can only be\n    // DAOs that have split from the original DAO. Conceptually, Reward Tokens\n    // represent the proportion of the rewards that the DAO has the right to\n    // receive. These Reward Tokens are generated when the DAO spends ether.\n    mapping (address => uint) public rewardToken;\n    // Total supply of rewardToken\n    uint public totalRewardToken;\n\n    // The account used to manage the rewards which are to be distributed to the\n    // DAO Token Holders of this DAO\n    ManagedAccount public rewardAccount;\n\n    // The account used to manage the rewards which are to be distributed to\n    // any DAO that holds Reward Tokens\n    ManagedAccount public DAOrewardAccount;\n\n    // Amount of rewards (in wei) already paid out to a certain DAO\n    mapping (address => uint) public DAOpaidOut;\n\n    // Amount of rewards (in wei) already paid out to a certain address\n    mapping (address => uint) public paidOut;\n    // Map of addresses blocked during a vote (not allowed to transfer DAO\n    // tokens). The address points to the proposal ID.\n    mapping (address => uint) public blocked;\n\n    // The minimum deposit (in wei) required to submit any proposal that is not\n    // requesting a new Curator (no deposit is required for splits)\n    uint public proposalDeposit;\n\n    // the accumulated sum of all current proposal deposits\n    uint sumOfProposalDeposits;\n\n    // Contract that is able to create a new DAO (with the same code as\n    // this one), used for splits\n    DAO_Creator public daoCreator;\n\n    // A proposal with `newCurator == false` represents a transaction\n    // to be issued by this DAO\n    // A proposal with `newCurator == true` represents a DAO split\n    struct Proposal {\n        // The address where the `amount` will go to if the proposal is accepted\n        // or if `newCurator` is true, the proposed Curator of\n        // the new DAO).\n        address recipient;\n        // The amount to transfer to `recipient` if the proposal is accepted.\n        uint amount;\n        // A plain text description of the proposal\n        string description;\n        // A unix timestamp, denoting the end of the voting period\n        uint votingDeadline;\n        // True if the proposal's votes have yet to be counted, otherwise False\n        bool open;\n        // True if quorum has been reached, the votes have been counted, and\n        // the majority said yes\n        bool proposalPassed;\n        // A hash to check validity of a proposal\n        bytes32 proposalHash;\n        // Deposit in wei the creator added when submitting their proposal. It\n        // is taken from the msg.value of a newProposal call.\n        uint proposalDeposit;\n        // True if this proposal is to assign a new Curator\n        bool newCurator;\n        // Data needed for splitting the DAO\n        SplitData[] splitData;\n        // Number of Tokens in favor of the proposal\n        uint yea;\n        // Number of Tokens opposed to the proposal\n        uint nay;\n        // Simple mapping to check if a shareholder has voted for it\n        mapping (address => bool) votedYes;\n        // Simple mapping to check if a shareholder has voted against it\n        mapping (address => bool) votedNo;\n        // Address of the shareholder who created the proposal\n        address creator;\n    }\n\n    // Used only in the case of a newCurator proposal.\n    struct SplitData {\n        // The balance of the current DAO minus the deposit at the time of split\n        uint splitBalance;\n        // The total amount of DAO Tokens in existence at the time of split.\n        uint totalSupply;\n        // Amount of Reward Tokens owned by the DAO at the time of split.\n        uint rewardToken;\n        // The new DAO contract created at the time of split.\n        DAO newDAO;\n    }\n\n    // Used to restrict access to certain functions to only DAO Token Holders\n    modifier onlyTokenholders {}\n\n    /// @dev Constructor setting the Curator and the address\n    /// for the contract able to create another DAO as well as the parameters\n    /// for the DAO Token Creation\n    /// @param _curator The Curator\n    /// @param _daoCreator The contract able to (re)create this DAO\n    /// @param _proposalDeposit The deposit to be paid for a regular proposal\n    /// @param _minTokensToCreate Minimum required wei-equivalent tokens\n    ///        to be created for a successful DAO Token Creation\n    /// @param _closingTime Date (in Unix time) of the end of the DAO Token Creation\n    /// @param _privateCreation If zero the DAO Token Creation is open to public, a\n    /// non-zero address means that the DAO Token Creation is only for the address\n    // This is the constructor: it can not be overloaded so it is commented out\n    //  function DAO(\n        //  address _curator,\n        //  DAO_Creator _daoCreator,\n        //  uint _proposalDeposit,\n        //  uint _minTokensToCreate,\n        //  uint _closingTime,\n        //  address _privateCreation\n    //  );\n\n    /// @notice Create Token with `msg.sender` as the beneficiary\n    /// @return Whether the token creation was successful\n    function () returns (bool success);\n\n\n    /// @dev This function is used to send ether back\n    /// to the DAO, it can also be used to receive payments that should not be\n    /// counted as rewards (donations, grants, etc.)\n    /// @return Whether the DAO received the ether successfully\n    function receiveEther() returns(bool);\n\n    /// @notice `msg.sender` creates a proposal to send `_amount` Wei to\n    /// `_recipient` with the transaction data `_transactionData`. If\n    /// `_newCurator` is true, then this is a proposal that splits the\n    /// DAO and sets `_recipient` as the new DAO's Curator.\n    /// @param _recipient Address of the recipient of the proposed transaction\n    /// @param _amount Amount of wei to be sent with the proposed transaction\n    /// @param _description String describing the proposal\n    /// @param _transactionData Data of the proposed transaction\n    /// @param _debatingPeriod Time used for debating a proposal, at least 2\n    /// weeks for a regular proposal, 10 days for new Curator proposal\n    /// @param _newCurator Bool defining whether this proposal is about\n    /// a new Curator or not\n    /// @return The proposal ID. Needed for voting on the proposal\n    function newProposal(\n        address _recipient,\n        uint _amount,\n        string _description,\n        bytes _transactionData,\n        uint _debatingPeriod,\n        bool _newCurator\n    ) onlyTokenholders returns (uint _proposalID);\n\n    /// @notice Check that the proposal with the ID `_proposalID` matches the\n    /// transaction which sends `_amount` with data `_transactionData`\n    /// to `_recipient`\n    /// @param _proposalID The proposal ID\n    /// @param _recipient The recipient of the proposed transaction\n    /// @param _amount The amount of wei to be sent in the proposed transaction\n    /// @param _transactionData The data of the proposed transaction\n    /// @return Whether the proposal ID matches the transaction data or not\n    function checkProposalCode(\n        uint _proposalID,\n        address _recipient,\n        uint _amount,\n        bytes _transactionData\n    ) constant returns (bool _codeChecksOut);\n\n    /// @notice Vote on proposal `_proposalID` with `_supportsProposal`\n    /// @param _proposalID The proposal ID\n    /// @param _supportsProposal Yes/No - support of the proposal\n    /// @return The vote ID.\n    function vote(\n        uint _proposalID,\n        bool _supportsProposal\n    ) onlyTokenholders returns (uint _voteID);\n\n    /// @notice Checks whether proposal `_proposalID` with transaction data\n    /// `_transactionData` has been voted for or rejected, and executes the\n    /// transaction in the case it has been voted for.\n    /// @param _proposalID The proposal ID\n    /// @param _transactionData The data of the proposed transaction\n    /// @return Whether the proposed transaction has been executed or not\n    function executeProposal(\n        uint _proposalID,\n        bytes _transactionData\n    ) returns (bool _success);\n\n    /// @notice ATTENTION! I confirm to move my remaining ether to a new DAO\n    /// with `_newCurator` as the new Curator, as has been\n    /// proposed in proposal `_proposalID`. This will burn my tokens. This can\n    /// not be undone and will split the DAO into two DAO's, with two\n    /// different underlying tokens.\n    /// @param _proposalID The proposal ID\n    /// @param _newCurator The new Curator of the new DAO\n    /// @dev This function, when called for the first time for this proposal,\n    /// will create a new DAO and send the sender's portion of the remaining\n    /// ether and Reward Tokens to the new DAO. It will also burn the DAO Tokens\n    /// of the sender.\n    function splitDAO(\n        uint _proposalID,\n        address _newCurator\n    ) returns (bool _success);\n\n    /// @dev can only be called by the DAO itself through a proposal\n    /// updates the contract of the DAO by sending all ether and rewardTokens\n    /// to the new DAO. The new DAO needs to be approved by the Curator\n    /// @param _newContract the address of the new contract\n    function newContract(address _newContract);\n\n\n    /// @notice Add a new possible recipient `_recipient` to the whitelist so\n    /// that the DAO can send transactions to them (using proposals)\n    /// @param _recipient New recipient address\n    /// @dev Can only be called by the current Curator\n    /// @return Whether successful or not\n    function changeAllowedRecipients(address _recipient, bool _allowed) external returns (bool _success);\n\n\n    /// @notice Change the minimum deposit required to submit a proposal\n    /// @param _proposalDeposit The new proposal deposit\n    /// @dev Can only be called by this DAO (through proposals with the\n    /// recipient being this DAO itself)\n    function changeProposalDeposit(uint _proposalDeposit) external;\n\n    /// @notice Move rewards from the DAORewards managed account\n    /// @param _toMembers If true rewards are moved to the actual reward account\n    ///                   for the DAO. If not then it's moved to the DAO itself\n    /// @return Whether the call was successful\n    function retrieveDAOReward(bool _toMembers) external returns (bool _success);\n\n    /// @notice Get my portion of the reward that was sent to `rewardAccount`\n    /// @return Whether the call was successful\n    function getMyReward() returns(bool _success);\n\n    /// @notice Withdraw `_account`'s portion of the reward from `rewardAccount`\n    /// to `_account`'s balance\n    /// @return Whether the call was successful\n    function withdrawRewardFor(address _account) internal returns (bool _success);\n\n    /// @notice Send `_amount` tokens to `_to` from `msg.sender`. Prior to this\n    /// getMyReward() is called.\n    /// @param _to The address of the recipient\n    /// @param _amount The amount of tokens to be transfered\n    /// @return Whether the transfer was successful or not\n    function transferWithoutReward(address _to, uint256 _amount) returns (bool success);\n\n    /// @notice Send `_amount` tokens to `_to` from `_from` on the condition it\n    /// is approved by `_from`. Prior to this getMyReward() is called.\n    /// @param _from The address of the sender\n    /// @param _to The address of the recipient\n    /// @param _amount The amount of tokens to be transfered\n    /// @return Whether the transfer was successful or not\n    function transferFromWithoutReward(\n        address _from,\n        address _to,\n        uint256 _amount\n    ) returns (bool success);\n\n    /// @notice Doubles the 'minQuorumDivisor' in the case quorum has not been\n    /// achieved in 52 weeks\n    /// @return Whether the change was successful or not\n    function halveMinQuorum() returns (bool _success);\n\n    /// @return total number of proposals ever created\n    function numberOfProposals() constant returns (uint _numberOfProposals);\n\n    /// @param _proposalID Id of the new curator proposal\n    /// @return Address of the new DAO\n    function getNewDAOAddress(uint _proposalID) constant returns (address _newDAO);\n\n    /// @param _account The address of the account which is checked.\n    /// @return Whether the account is blocked (not allowed to transfer tokens) or not.\n    function isBlocked(address _account) internal returns (bool);\n\n    /// @notice If the caller is blocked by a proposal whose voting deadline\n    /// has exprired then unblock him.\n    /// @return Whether the account is blocked (not allowed to transfer tokens) or not.\n    function unblockMe() returns (bool);\n\n    event ProposalAdded(\n        uint indexed proposalID,\n        address recipient,\n        uint amount,\n        bool newCurator,\n        string description\n    );\n    event Voted(uint indexed proposalID, bool position, address indexed voter);\n    event ProposalTallied(uint indexed proposalID, bool result, uint quorum);\n    event NewCurator(address indexed _newCurator);\n    event AllowedRecipientChanged(address indexed _recipient, bool _allowed);\n}\n\n// The DAO contract itself\ncontract DAO is DAOInterface, Token, TokenCreation {\n\n    // Modifier that allows only shareholders to vote and create new proposals\n    modifier onlyTokenholders {\n        if (balanceOf(msg.sender) == 0) throw;\n            _\n    }\n\n    function DAO(\n        address _curator,\n        DAO_Creator _daoCreator,\n        uint _proposalDeposit,\n        uint _minTokensToCreate,\n        uint _closingTime,\n        address _privateCreation\n    ) TokenCreation(_minTokensToCreate, _closingTime, _privateCreation) {\n\n        curator = _curator;\n        daoCreator = _daoCreator;\n        proposalDeposit = _proposalDeposit;\n        rewardAccount = new ManagedAccount(address(this), false);\n        DAOrewardAccount = new ManagedAccount(address(this), false);\n        if (address(rewardAccount) == 0)\n            throw;\n        if (address(DAOrewardAccount) == 0)\n            throw;\n        lastTimeMinQuorumMet = now;\n        minQuorumDivisor = 5; // sets the minimal quorum to 20%\n        proposals.length = 1; // avoids a proposal with ID 0 because it is used\n\n        allowedRecipients[address(this)] = true;\n        allowedRecipients[curator] = true;\n    }\n\n    function () returns (bool success) {\n        if (now < closingTime + creationGracePeriod && msg.sender != address(extraBalance))\n            return createTokenProxy(msg.sender);\n        else\n            return receiveEther();\n    }\n\n\n    function receiveEther() returns (bool) {\n        return true;\n    }\n\n\n    function newProposal(\n        address _recipient,\n        uint _amount,\n        string _description,\n        bytes _transactionData,\n        uint _debatingPeriod,\n        bool _newCurator\n    ) onlyTokenholders returns (uint _proposalID) {\n\n        // Sanity check\n        if (_newCurator && (\n            _amount != 0\n            || _transactionData.length != 0\n            || _recipient == curator\n            || msg.value > 0\n            || _debatingPeriod < minSplitDebatePeriod)) {\n            throw;\n        } else if (\n            !_newCurator\n            && (!isRecipientAllowed(_recipient) || (_debatingPeriod <  minProposalDebatePeriod))\n        ) {\n            throw;\n        }\n\n        if (_debatingPeriod > 8 weeks)\n            throw;\n\n        if (!isFueled\n            || now < closingTime\n            || (msg.value < proposalDeposit && !_newCurator)) {\n\n            throw;\n        }\n\n        if (now + _debatingPeriod < now) // prevents overflow\n            throw;\n\n        // to prevent a 51% attacker to convert the ether into deposit\n        if (msg.sender == address(this))\n            throw;\n\n        _proposalID = proposals.length++;\n        Proposal p = proposals[_proposalID];\n        p.recipient = _recipient;\n        p.amount = _amount;\n        p.description = _description;\n        p.proposalHash = sha3(_recipient, _amount, _transactionData);\n        p.votingDeadline = now + _debatingPeriod;\n        p.open = true;\n        //p.proposalPassed = False; // that's default\n        p.newCurator = _newCurator;\n        if (_newCurator)\n            p.splitData.length++;\n        p.creator = msg.sender;\n        p.proposalDeposit = msg.value;\n\n        sumOfProposalDeposits += msg.value;\n\n        ProposalAdded(\n            _proposalID,\n            _recipient,\n            _amount,\n            _newCurator,\n            _description\n        );\n    }\n\n\n    function checkProposalCode(\n        uint _proposalID,\n        address _recipient,\n        uint _amount,\n        bytes _transactionData\n    ) noEther constant returns (bool _codeChecksOut) {\n        Proposal p = proposals[_proposalID];\n        return p.proposalHash == sha3(_recipient, _amount, _transactionData);\n    }\n\n\n    function vote(\n        uint _proposalID,\n        bool _supportsProposal\n    ) onlyTokenholders noEther returns (uint _voteID) {\n\n        Proposal p = proposals[_proposalID];\n        if (p.votedYes[msg.sender]\n            || p.votedNo[msg.sender]\n            || now >= p.votingDeadline) {\n\n            throw;\n        }\n\n        if (_supportsProposal) {\n            p.yea += balances[msg.sender];\n            p.votedYes[msg.sender] = true;\n        } else {\n            p.nay += balances[msg.sender];\n            p.votedNo[msg.sender] = true;\n        }\n\n        if (blocked[msg.sender] == 0) {\n            blocked[msg.sender] = _proposalID;\n        } else if (p.votingDeadline > proposals[blocked[msg.sender]].votingDeadline) {\n            // this proposal's voting deadline is further into the future than\n            // the proposal that blocks the sender so make it the blocker\n            blocked[msg.sender] = _proposalID;\n        }\n\n        Voted(_proposalID, _supportsProposal, msg.sender);\n    }\n\n\n    function executeProposal(\n        uint _proposalID,\n        bytes _transactionData\n    ) noEther returns (bool _success) {\n\n        Proposal p = proposals[_proposalID];\n\n        uint waitPeriod = p.newCurator\n            ? splitExecutionPeriod\n            : executeProposalPeriod;\n        // If we are over deadline and waiting period, assert proposal is closed\n        if (p.open && now > p.votingDeadline + waitPeriod) {\n            closeProposal(_proposalID);\n            return;\n        }\n\n        // Check if the proposal can be executed\n        if (now < p.votingDeadline  // has the voting deadline arrived?\n            // Have the votes been counted?\n            || !p.open\n            // Does the transaction code match the proposal?\n            || p.proposalHash != sha3(p.recipient, p.amount, _transactionData)) {\n\n            throw;\n        }\n\n        // If the curator removed the recipient from the whitelist, close the proposal\n        // in order to free the deposit and allow unblocking of voters\n        if (!isRecipientAllowed(p.recipient)) {\n            closeProposal(_proposalID);\n            p.creator.send(p.proposalDeposit);\n            return;\n        }\n\n        bool proposalCheck = true;\n\n        if (p.amount > actualBalance())\n            proposalCheck = false;\n\n        uint quorum = p.yea + p.nay;\n\n        // require 53% for calling newContract()\n        if (_transactionData.length >= 4 && _transactionData[0] == 0x68\n            && _transactionData[1] == 0x37 && _transactionData[2] == 0xff\n            && _transactionData[3] == 0x1e\n            && quorum < minQuorum(actualBalance() + rewardToken[address(this)])) {\n\n                proposalCheck = false;\n        }\n\n        if (quorum >= minQuorum(p.amount)) {\n            if (!p.creator.send(p.proposalDeposit))\n                throw;\n\n            lastTimeMinQuorumMet = now;\n            // set the minQuorum to 20% again, in the case it has been reached\n            if (quorum > totalSupply / 5)\n                minQuorumDivisor = 5;\n        }\n\n        // Execute result\n        if (quorum >= minQuorum(p.amount) && p.yea > p.nay && proposalCheck) {\n            if (!p.recipient.call.value(p.amount)(_transactionData))\n                throw;\n\n            p.proposalPassed = true;\n            _success = true;\n\n            // only create reward tokens when ether is not sent to the DAO itself and\n            // related addresses. Proxy addresses should be forbidden by the curator.\n            if (p.recipient != address(this) && p.recipient != address(rewardAccount)\n                && p.recipient != address(DAOrewardAccount)\n                && p.recipient != address(extraBalance)\n                && p.recipient != address(curator)) {\n\n                rewardToken[address(this)] += p.amount;\n                totalRewardToken += p.amount;\n            }\n        }\n\n        closeProposal(_proposalID);\n\n        // Initiate event\n        ProposalTallied(_proposalID, _success, quorum);\n    }\n\n\n    function closeProposal(uint _proposalID) internal {\n        Proposal p = proposals[_proposalID];\n        if (p.open)\n            sumOfProposalDeposits -= p.proposalDeposit;\n        p.open = false;\n    }\n\n    function splitDAO(\n        uint _proposalID,\n        address _newCurator\n    ) noEther onlyTokenholders returns (bool _success) {\n\n        Proposal p = proposals[_proposalID];\n\n        // Sanity check\n\n        if (now < p.votingDeadline  // has the voting deadline arrived?\n            //The request for a split expires XX days after the voting deadline\n            || now > p.votingDeadline + splitExecutionPeriod\n            // Does the new Curator address match?\n            || p.recipient != _newCurator\n            // Is it a new curator proposal?\n            || !p.newCurator\n            // Have you voted for this split?\n            || !p.votedYes[msg.sender]\n            // Did you already vote on another proposal?\n            || (blocked[msg.sender] != _proposalID && blocked[msg.sender] != 0) )  {\n\n            throw;\n        }\n\n        // If the new DAO doesn't exist yet, create the new DAO and store the\n        // current split data\n        if (address(p.splitData[0].newDAO) == 0) {\n            p.splitData[0].newDAO = createNewDAO(_newCurator);\n            // Call depth limit reached, etc.\n            if (address(p.splitData[0].newDAO) == 0)\n                throw;\n            // should never happen\n            if (this.balance < sumOfProposalDeposits)\n                throw;\n            p.splitData[0].splitBalance = actualBalance();\n            p.splitData[0].rewardToken = rewardToken[address(this)];\n            p.splitData[0].totalSupply = totalSupply;\n            p.proposalPassed = true;\n        }\n\n        // Move ether and assign new Tokens\n        uint fundsToBeMoved =\n            (balances[msg.sender] * p.splitData[0].splitBalance) /\n            p.splitData[0].totalSupply;\n        if (p.splitData[0].newDAO.createTokenProxy.value(fundsToBeMoved)(msg.sender) == false)\n            throw;\n\n\n        // Assign reward rights to new DAO\n        uint rewardTokenToBeMoved =\n            (balances[msg.sender] * p.splitData[0].rewardToken) /\n            p.splitData[0].totalSupply;\n\n        uint paidOutToBeMoved = DAOpaidOut[address(this)] * rewardTokenToBeMoved /\n            rewardToken[address(this)];\n\n        rewardToken[address(p.splitData[0].newDAO)] += rewardTokenToBeMoved;\n        if (rewardToken[address(this)] < rewardTokenToBeMoved)\n            throw;\n        rewardToken[address(this)] -= rewardTokenToBeMoved;\n\n        DAOpaidOut[address(p.splitData[0].newDAO)] += paidOutToBeMoved;\n        if (DAOpaidOut[address(this)] < paidOutToBeMoved)\n            throw;\n        DAOpaidOut[address(this)] -= paidOutToBeMoved;\n\n        // Burn DAO Tokens\n        Transfer(msg.sender, 0, balances[msg.sender]);\n        withdrawRewardFor(msg.sender); // be nice, and get his rewards\n        totalSupply -= balances[msg.sender];\n        balances[msg.sender] = 0;\n        paidOut[msg.sender] = 0;\n        return true;\n    }\n\n    function newContract(address _newContract){\n        if (msg.sender != address(this) || !allowedRecipients[_newContract]) return;\n        // move all ether\n        if (!_newContract.call.value(address(this).balance)()) {\n            throw;\n        }\n\n        //move all reward tokens\n        rewardToken[_newContract] += rewardToken[address(this)];\n        rewardToken[address(this)] = 0;\n        DAOpaidOut[_newContract] += DAOpaidOut[address(this)];\n        DAOpaidOut[address(this)] = 0;\n    }\n\n\n    function retrieveDAOReward(bool _toMembers) external noEther returns (bool _success) {\n        DAO dao = DAO(msg.sender);\n\n        if ((rewardToken[msg.sender] * DAOrewardAccount.accumulatedInput()) /\n            totalRewardToken < DAOpaidOut[msg.sender])\n            throw;\n\n        uint reward =\n            (rewardToken[msg.sender] * DAOrewardAccount.accumulatedInput()) /\n            totalRewardToken - DAOpaidOut[msg.sender];\n        if(_toMembers) {\n            if (!DAOrewardAccount.payOut(dao.rewardAccount(), reward))\n                throw;\n            }\n        else {\n            if (!DAOrewardAccount.payOut(dao, reward))\n                throw;\n        }\n        DAOpaidOut[msg.sender] += reward;\n        return true;\n    }\n\n    function getMyReward() noEther returns (bool _success) {\n        return withdrawRewardFor(msg.sender);\n    }\n\n\n    function withdrawRewardFor(address _account) noEther internal returns (bool _success) {\n        if ((balanceOf(_account) * rewardAccount.accumulatedInput()) / totalSupply < paidOut[_account])\n            throw;\n\n        uint reward =\n            (balanceOf(_account) * rewardAccount.accumulatedInput()) / totalSupply - paidOut[_account];\n        if (!rewardAccount.payOut(_account, reward))\n            throw;\n        paidOut[_account] += reward;\n        return true;\n    }\n\n\n    function transfer(address _to, uint256 _value) returns (bool success) {\n        if (isFueled\n            && now > closingTime\n            && !isBlocked(msg.sender)\n            && transferPaidOut(msg.sender, _to, _value)\n            && super.transfer(_to, _value)) {\n\n            return true;\n        } else {\n            throw;\n        }\n    }\n\n\n    function transferWithoutReward(address _to, uint256 _value) returns (bool success) {\n        if (!getMyReward())\n            throw;\n        return transfer(_to, _value);\n    }\n\n\n    function transferFrom(address _from, address _to, uint256 _value) returns (bool success) {\n        if (isFueled\n            && now > closingTime\n            && !isBlocked(_from)\n            && transferPaidOut(_from, _to, _value)\n            && super.transferFrom(_from, _to, _value)) {\n\n            return true;\n        } else {\n            throw;\n        }\n    }\n\n\n    function transferFromWithoutReward(\n        address _from,\n        address _to,\n        uint256 _value\n    ) returns (bool success) {\n\n        if (!withdrawRewardFor(_from))\n            throw;\n        return transferFrom(_from, _to, _value);\n    }\n\n\n    function transferPaidOut(\n        address _from,\n        address _to,\n        uint256 _value\n    ) internal returns (bool success) {\n\n        uint transferPaidOut = paidOut[_from] * _value / balanceOf(_from);\n        if (transferPaidOut > paidOut[_from])\n            throw;\n        paidOut[_from] -= transferPaidOut;\n        paidOut[_to] += transferPaidOut;\n        return true;\n    }\n\n\n    function changeProposalDeposit(uint _proposalDeposit) noEther external {\n        if (msg.sender != address(this) || _proposalDeposit > (actualBalance() + rewardToken[address(this)])\n            / maxDepositDivisor) {\n\n            throw;\n        }\n        proposalDeposit = _proposalDeposit;\n    }\n\n\n    function changeAllowedRecipients(address _recipient, bool _allowed) noEther external returns (bool _success) {\n        if (msg.sender != curator)\n            throw;\n        allowedRecipients[_recipient] = _allowed;\n        AllowedRecipientChanged(_recipient, _allowed);\n        return true;\n    }\n\n\n    function isRecipientAllowed(address _recipient) internal returns (bool _isAllowed) {\n        if (allowedRecipients[_recipient]\n            || (_recipient == address(extraBalance)\n                // only allowed when at least the amount held in the\n                // extraBalance account has been spent from the DAO\n                && totalRewardToken > extraBalance.accumulatedInput()))\n            return true;\n        else\n            return false;\n    }\n\n    function actualBalance() constant returns (uint _actualBalance) {\n        return this.balance - sumOfProposalDeposits;\n    }\n\n\n    function minQuorum(uint _value) internal constant returns (uint _minQuorum) {\n        // minimum of 20% and maximum of 53.33%\n        return totalSupply / minQuorumDivisor +\n            (_value * totalSupply) / (3 * (actualBalance() + rewardToken[address(this)]));\n    }\n\n\n    function halveMinQuorum() returns (bool _success) {\n        // this can only be called after `quorumHalvingPeriod` has passed or at anytime\n        // by the curator with a delay of at least `minProposalDebatePeriod` between the calls\n        if ((lastTimeMinQuorumMet < (now - quorumHalvingPeriod) || msg.sender == curator)\n            && lastTimeMinQuorumMet < (now - minProposalDebatePeriod)) {\n            lastTimeMinQuorumMet = now;\n            minQuorumDivisor *= 2;\n            return true;\n        } else {\n            return false;\n        }\n    }\n\n    function createNewDAO(address _newCurator) internal returns (DAO _newDAO) {\n        NewCurator(_newCurator);\n        return daoCreator.createDAO(_newCurator, 0, 0, now + splitExecutionPeriod);\n    }\n\n    function numberOfProposals() constant returns (uint _numberOfProposals) {\n        // Don't count index 0. It's used by isBlocked() and exists from start\n        return proposals.length - 1;\n    }\n\n    function getNewDAOAddress(uint _proposalID) constant returns (address _newDAO) {\n        return proposals[_proposalID].splitData[0].newDAO;\n    }\n\n    function isBlocked(address _account) internal returns (bool) {\n        if (blocked[_account] == 0)\n            return false;\n        Proposal p = proposals[blocked[_account]];\n        if (now > p.votingDeadline) {\n            blocked[_account] = 0;\n            return false;\n        } else {\n            return true;\n        }\n    }\n\n    function unblockMe() returns (bool) {\n        return isBlocked(msg.sender);\n    }\n}\n\ncontract DAO_Creator {\n    function createDAO(\n        address _curator,\n        uint _proposalDeposit,\n        uint _minTokensToCreate,\n        uint _closingTime\n    ) returns (DAO _newDAO) {\n\n        return new DAO(\n            _curator,\n            DAO_Creator(this),\n            _proposalDeposit,\n            _minTokensToCreate,\n            _closingTime,\n            msg.sender\n        );\n    }\n}\n",
         "ABI":"[{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"proposals\",\"outputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"},{\"name\":\"description\",\"type\":\"string\"},{\"name\":\"votingDeadline\",\"type\":\"uint256\"},{\"name\":\"open\",\"type\":\"bool\"},{\"name\":\"proposalPassed\",\"type\":\"bool\"},{\"name\":\"proposalHash\",\"type\":\"bytes32\"},{\"name\":\"proposalDeposit\",\"type\":\"uint256\"},{\"name\":\"newCurator\",\"type\":\"bool\"},{\"name\":\"yea\",\"type\":\"uint256\"},{\"name\":\"nay\",\"type\":\"uint256\"},{\"name\":\"creator\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_spender\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"minTokensToCreate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"rewardAccount\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"daoCreator\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"divisor\",\"outputs\":[{\"name\":\"divisor\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"extraBalance\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_transactionData\",\"type\":\"bytes\"}],\"name\":\"executeProposal\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"unblockMe\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalRewardToken\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"actualBalance\",\"outputs\":[{\"name\":\"_actualBalance\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"closingTime\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"allowedRecipients\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferWithoutReward\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"refund\",\"outputs\":[],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_recipient\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_description\",\"type\":\"string\"},{\"name\":\"_transactionData\",\"type\":\"bytes\"},{\"name\":\"_debatingPeriod\",\"type\":\"uint256\"},{\"name\":\"_newCurator\",\"type\":\"bool\"}],\"name\":\"newProposal\",\"outputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"DAOpaidOut\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"minQuorumDivisor\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_newContract\",\"type\":\"address\"}],\"name\":\"newContract\",\"outputs\":[],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_owner\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"balance\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_recipient\",\"type\":\"address\"},{\"name\":\"_allowed\",\"type\":\"bool\"}],\"name\":\"changeAllowedRecipients\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"halveMinQuorum\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"paidOut\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_newCurator\",\"type\":\"address\"}],\"name\":\"splitDAO\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"DAOrewardAccount\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"proposalDeposit\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"numberOfProposals\",\"outputs\":[{\"name\":\"_numberOfProposals\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"lastTimeMinQuorumMet\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_toMembers\",\"type\":\"bool\"}],\"name\":\"retrieveDAOReward\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"receiveEther\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isFueled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_tokenHolder\",\"type\":\"address\"}],\"name\":\"createTokenProxy\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"}],\"name\":\"getNewDAOAddress\",\"outputs\":[{\"name\":\"_newDAO\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_supportsProposal\",\"type\":\"bool\"}],\"name\":\"vote\",\"outputs\":[{\"name\":\"_voteID\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"getMyReward\",\"outputs\":[{\"name\":\"_success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"rewardToken\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_to\",\"type\":\"address\"},{\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferFromWithoutReward\",\"outputs\":[{\"name\":\"success\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_owner\",\"type\":\"address\"},{\"name\":\"_spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"remaining\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_proposalDeposit\",\"type\":\"uint256\"}],\"name\":\"changeProposalDeposit\",\"outputs\":[],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"address\"}],\"name\":\"blocked\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"curator\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_proposalID\",\"type\":\"uint256\"},{\"name\":\"_recipient\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_transactionData\",\"type\":\"bytes\"}],\"name\":\"checkProposalCode\",\"outputs\":[{\"name\":\"_codeChecksOut\",\"type\":\"bool\"}],\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"privateCreation\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"type\":\"function\"},{\"inputs\":[{\"name\":\"_curator\",\"type\":\"address\"},{\"name\":\"_daoCreator\",\"type\":\"address\"},{\"name\":\"_proposalDeposit\",\"type\":\"uint256\"},{\"name\":\"_minTokensToCreate\",\"type\":\"uint256\"},{\"name\":\"_closingTime\",\"type\":\"uint256\"},{\"name\":\"_privateCreation\",\"type\":\"address\"}],\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"FuelingToDate\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"CreatedToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Refund\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"proposalID\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"newCurator\",\"type\":\"bool\"},{\"indexed\":false,\"name\":\"description\",\"type\":\"string\"}],\"name\":\"ProposalAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"proposalID\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"position\",\"type\":\"bool\"},{\"indexed\":true,\"name\":\"voter\",\"type\":\"address\"}],\"name\":\"Voted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"proposalID\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"result\",\"type\":\"bool\"},{\"indexed\":false,\"name\":\"quorum\",\"type\":\"uint256\"}],\"name\":\"ProposalTallied\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_newCurator\",\"type\":\"address\"}],\"name\":\"NewCurator\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_recipient\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_allowed\",\"type\":\"bool\"}],\"name\":\"AllowedRecipientChanged\",\"type\":\"event\"}]",
         "ContractName":"DAO",
         "CompilerVersion":"v0.3.1-2016-04-12-3ad5e82",
         "OptimizationUsed":"1",
         "Runs":"200",
         "ConstructorArguments":"000000000000000000000000da4a4626d3e16e094de3225a751aab7128e965260000000000000000000000004a574510c7014e4ae985403536074abe582adfc80000000000000000000000000000000000000000000000001bc16d674ec80000000000000000000000000000000000000000000000000a968163f0a57b4000000000000000000000000000000000000000000000000000000000000057495e100000000000000000000000000000000000000000000000000000000000000000",
         "EVMVersion":"Default",
         "Library":"",
         "LicenseType":"",
         "Proxy":"0",
         "Implementation":"",
         "SwarmSource":""
      }
   ]
}

Get Contract Creator and Creation Tx Hash

Returns a contract's deployer address and transaction hash it was created, up to 5 at a time.

https://api.etherscan.io/api
   ?module=contract
   &action=getcontractcreation
   &contractaddresses=0xB83c27805aAcA5C7082eB45C868d955Cf04C337F,0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45,0xe4462eb568E2DFbb5b0cA2D3DbB1A35C9Aa98aad,0xdAC17F958D2ee523a2206206994597C13D831ec7,0xf5b969064b91869fBF676ecAbcCd1c5563F591d0
   &apikey=YourApiKeyToken 

Query Parameters

Parameter
Description

contractaddresses

the contract address , up to 5 at a time

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":[
      {
         "contractAddress":"0x68b3465833fb72a70ecdf485e0e4c7bd8665fc45",
         "contractCreator":"0x6c9fc64a53c1b71fb3f9af64d1ae3a4931a5f4e9",
         "txHash":"0x7299cca7203f60a831756e043f4c2ccb0ee6cb7cf8aed8420f0ae99a16883a2b"
      },
      {
         "contractAddress":"0xb83c27805aaca5c7082eb45c868d955cf04c337f",
         "contractCreator":"0x390dcfddebeff949b9862ec91d7be337b8995553",
         "txHash":"0x0dbad4991b6727df606650635c9e632dad8a92c6363c91652307680efd336c6e"
      },
      {
         "contractAddress":"0xdac17f958d2ee523a2206206994597c13d831ec7",
         "contractCreator":"0x36928500bc1dcd7af6a2b4008875cc336b927d57",
         "txHash":"0x2f1c5c2b44f771e942a8506148e256f94f1a464babc938ae0690c6e34cd79190"
      },
      {
         "contractAddress":"0xe4462eb568e2dfbb5b0ca2d3dbb1a35c9aa98aad",
         "contractCreator":"0xa6d3a33a1c66083859765b9d6e407d095a908193",
         "txHash":"0x785bcd378c8168b63c9fdef64219f8ff69eec1f785f081a74513f21b18072f93"
      },
      {
         "contractAddress":"0xf5b969064b91869fbf676ecabccd1c5563f591d0",
         "contractCreator":"0x435a5760aa360cae8c246039abab7754e80a1af1",
         "txHash":"0x779cceffd0a5b4df6718674f7d88dda3edde9ff0a6fec271eb584f65a56997c6"
      }
   ]
}

Verify Solidity Source Code

Submits a Solidity contract source code to Sepolia Apescan for verification.

https://api.etherscan.io/api
   ?module=contract
   &action=verifysourcecode
   &apikey=YourApiKeyToken 

Query Parameters

Requests must be sent using HTTP POST

Parameter
Description

codeformat

single file, use solidity-single-file JSON file ( recommended ), use solidity-standard-json-input

sourceCode

the Solidity source code

constructorArguements

optional, include if your contract uses constructor arguments

contractaddress

the address your contract is deployed at

contractname

the name of your contract, such as contracts/Verified.sol:Verified

compilerversion

Sample Response

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

Verify Vyper Source Code

Submits a Vyper contract source code to Sepolia Apescan for verification.

https://api.etherscan.io/api
   ?module=contract
   &action=verifysourcecode
   &apikey=YourApiKeyToken 

Query Parameters

Requests must be sent using HTTP POST

Parameter
Description

codeformat

use vyper-json

sourceCode

constructorArguments

optional, include if your contract uses constructor arguments

contractaddress

the address your contract is deployed at

contractname

the name of your contract, such as contracts/Verified.vy:Verified

compilerversion

compiler version used, such as vyper:0.4.0

optimizationUsed

use 0 for no optimisation and 1 for optimisation used

Sample Response

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

Check Source Code Verification Status

Returns the success or error status of a contract verification request.

https://api.etherscan.io/api
   ?module=contract
   &action=checkverifystatus
   &guid=x3ryqcqr1zdknhfhkimqmizlcqpxncqc6nrvp3pgrcpfsqedqi
   &apikey=YourApiKeyToken 

Query Parameters

Parameter
Description

guid

the unique guid received from the verification request

Sample Response

{
    "status": "1",
    "message": "OK",
    "result": "Pass - Verified"
}

Verify Proxy Contract

Submits a proxy contract source code to Apescan for verification.

  1. Requires a valid Apescan API key, it will be rejected otherwise

  2. Current daily limit of 100 submissions per day per user (subject to change)

  3. Only supports HTTP post

  4. Upon successful submission you will receive a GUID (50 characters) as a receipt

  5. You may use this GUID to track the status of your submission

  6. Verified proxy contracts will display the "Read/Write as Proxy" of the implementation contract under the contract address's contract tab

Verifying Proxy Contract using cURL

// example with only the mandatory contract address parameter
curl -d "address=0xcbdcd3815b5f975e1a2c944a9b2cd1c985a1cb7f" "https://api.etherscan.io/api?module=contract&action=verifyproxycontract&apikey=YourApiKeyToken"

// example using the expectedimplementation optional parameter
// the expectedimplementation enforces a check to ensure the returned implementation contract address == address picked up by the verifier
curl -d "address=0xbc46363a7669f6e12353fa95bb067aead3675c29&expectedimplementation=0xe45a5176bc0f2c1198e2451c4e4501d4ed9b65a6" "https://api.etherscan.io/api?module=contract&action=verifyproxycontract&apikey=YourApiKeyToken"
// OK
{"status":"1","message":"OK","result":"gwgrrnfy56zf6vc1fljuejwg6pelnc5yns6fg6y2i6zfpgzquz"}

// NOTOK
{"status":"0","message":"NOTOK","result":"Invalid API Key"}

Checking Proxy Contract Verification Submission Status using cURL

curl "https://api.etherscan.io/api?module=contract&action=checkproxyverification&guid=gwgrrnfy56zf6vc1fljuejwg6pelnc5yns6fg6y2i6zfpgzquz&apikey=YourApiKeyToken"
// OK
{"status":"1","message":"OK","result":"The proxy's (0xbc46363a7669f6e12353fa95bb067aead3675c29) implementation contract is found at 0xe45a5176bc0f2c1198e2451c4e4501d4ed9b65a6 and is successfully updated."}
                                    
// NOTOK
{"status":"0","message":"NOTOK","result":"A corresponding implementation contract was unfortunately not detected for the proxy address."}

Geth/Parity Proxy

For compatibility with Parity, please prefix all hex strings with " 0x ".

eth_blockNumber

Returns the number of most recent block

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_blockNumber
   &apikey=YourApiKeyToken

No parameters required.

Sample response

{
   "jsonrpc":"2.0",
   "result":"0x10a79f",
   "id":83
}

eth_getBlockByNumber

Returns information about a block by block number.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getBlockByNumber
   &tag=0x91b743
   &boolean=true
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

tag

the block number, in hex eg. 0xC36B3C

boolean

the boolean value to show full transaction objects.

when true, returns full transaction objects and their information, when false only returns a list of transactions.

Sample response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":{
      "baseFeePerGas":"0x7",
      "difficulty":"0x1348c54c4",
      "extraData":"0xd883010a11846765746888676f312e31372e37856c696e7578",
      "gasLimit":"0x7a1200",
      "gasUsed":"0x0",
      "hash":"0x2cb5abe6b662c8a676df0c55a8fb01c81fdad7c1e1b7b3e7f8900439fd626c37",
      "logsBloom":"0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
      "miner":"0x45ff5f8723dae09d008dae9462346fd806736390",
      "mixHash":"0x914dac73b89721483a62fb78b7fd1110b91d57752afc84e911c34eedef090519",
      "nonce":"0x6517543e5b8f467c",
      "number":"0x10a79f",
      "parentHash":"0xbccd65c8ad26b21413d4593161c7161ea612033d00dd6887673ab3eab283ff7b",
      "receiptsRoot":"0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
      "sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
      "size":"0x21e",
      "stateRoot":"0xa01ded26f5c6b00bfff7b8e244ec361b521093d07d3ce3db9c7b05f918bc877d",
      "timestamp":"0x627e7d2c",
      "totalDifficulty":"0xbf255bf92df41",
      "transactions":[
         
      ],
      "transactionsRoot":"0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
      "uncles":[
         
      ]
   }
}

eth_getUncleByBlockNumberAndIndex

Returns information about a uncle by block number.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getUncleByBlockNumberAndIndex
   &tag=0x10A7A6
   &index=0x0
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

tag

the block number, in hex eg. 0xC36B3C

index

the position of the uncle's index in the block, in hex eg. 0x5

Sample response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":{
      "baseFeePerGas":"0x7",
      "difficulty":"0x133cb6ea4",
      "extraData":"0xd883010a10846765746888676f312e31372e37856c696e7578",
      "gasLimit":"0x7a1200",
      "gasUsed":"0x0",
      "hash":"0xd5aabf16a6cd972bf33b7656143d1305f24273ca44a47908e2c36d8eb69a2d80",
      "logsBloom":"0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
      "miner":"0xd87def8bbd2c4d59494611ab259a2005c154212a",
      "mixHash":"0x4c2d04e4f691306fcca2f2623cdac968bc1dc90170a1c7104815cebe424c6411",
      "nonce":"0x4c0da4978732561b",
      "number":"0x10a7a5",
      "parentHash":"0xa92a3d6c31cdbed8d40067930f364291063e01946ca40db7cf4e95866bfcd7f1",
      "receiptsRoot":"0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
      "sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
      "size":"0x21e",
      "stateRoot":"0x5c5ca1001e5f6b383a0bcab31823097146aa364158b12888de02bbff707da299",
      "timestamp":"0x627e7da6",
      "transactionsRoot":"0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
      "uncles":[
         
      ]
   }
}

eth_getBlockTransactionCountByNumber

Returns the number of transactions in a block.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getBlockTransactionCountByNumber
   &tag=0x10A70A
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

tag

the block number, in hex eg. 0x10FB78

Sample response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":"0x1"
}

eth_getTransactionByHash

Returns the information about a transaction requested by transaction hash.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getTransactionByHash
   &txhash=0x57be61afdf095899d160003f58e429d3f9b0851fd90db217fc0aa474761f9f34
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

txhash

the string representing the hash of the transaction

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":{
      "blockHash":"0x9329b3b236fb6a60ddec501d9264e587593f7b810fff31c9a2cf1f2deb58ebe2",
      "blockNumber":"0x10a70a",
      "from":"0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd",
      "gas":"0x5208",
      "gasPrice":"0x77359407",
      "maxFeePerGas":"0x77359407",
      "maxPriorityFeePerGas":"0x77359400",
      "hash":"0x57be61afdf095899d160003f58e429d3f9b0851fd90db217fc0aa474761f9f34",
      "input":"0x",
      "nonce":"0x6e",
      "to":"0x97664026bf28d95330dd80174630c287a9c8e2e3",
      "transactionIndex":"0x0",
      "value":"0x35c007914225000",
      "type":"0x2",
      "accessList":[
         
      ],
      "chainId":"0xaa36a7",
      "v":"0x1",
      "r":"0x9c358c4e6ef291967775d0c50e34dbb3a0c602a3d8e616dffb5a513e4ac2018e",
      "s":"0x28dd29246d37f57a35026d315c352042f04afc0709c541a9e0d39df571aa7c67"
   }
}

eth_getTransactionByBlockNumberAndIndex

Returns information about a transaction by block number and transaction index position.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getTransactionByBlockNumberAndIndex
   &tag=0x10A70A
   &index=0x0
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

tag

the block number, in hex eg. 0x10FB78

index

the position of the uncle's index in the block, in hex eg. 0x0

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":{
      "blockHash":"0x9329b3b236fb6a60ddec501d9264e587593f7b810fff31c9a2cf1f2deb58ebe2",
      "blockNumber":"0x10a70a",
      "from":"0x382b4ca2c4a7cd28c1c400c69d81ec2b2637f7dd",
      "gas":"0x5208",
      "gasPrice":"0x77359407",
      "maxFeePerGas":"0x77359407",
      "maxPriorityFeePerGas":"0x77359400",
      "hash":"0x57be61afdf095899d160003f58e429d3f9b0851fd90db217fc0aa474761f9f34",
      "input":"0x",
      "nonce":"0x6e",
      "to":"0x97664026bf28d95330dd80174630c287a9c8e2e3",
      "transactionIndex":"0x0",
      "value":"0x35c007914225000",
      "type":"0x2",
      "accessList":[
         
      ],
      "chainId":"0xaa36a7",
      "v":"0x1",
      "r":"0x9c358c4e6ef291967775d0c50e34dbb3a0c602a3d8e616dffb5a513e4ac2018e",
      "s":"0x28dd29246d37f57a35026d315c352042f04afc0709c541a9e0d39df571aa7c67"
   }
}

eth_getTransactionCount

Returns the number of transactions performed by an address.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getTransactionCount
   &address=0x1d41D6B1091C1a8A334096771bd1776019243d5e
   &tag=latest
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

address

the string representing the address to get transaction count

tag

the string pre-defined block parameter, either earliest, pending or latest

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":"0x6f"
}

eth_sendRawTransaction

Submits a pre-signed transaction for broadcast to the Ethereum network.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_sendRawTransaction
   &hex=0x02f874030185012a05f200852e90edd00082520894eeee7341f206302f2216e39d715b96d8c6901a1c880de0b6b3a764000080c001a0bf61ea5419c7856be4ea2221b721b849d50fec738d10a714e7aaa809d9ad8838a01e59353aa8e567cc0661fb58b047361998df234df6593bf424839bc5ea214a2c
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

hex

the string representing the signed raw transaction data to broadcast.

Sample Response

{
  "id":1,
  "jsonrpc": "2.0",
  "result": "0x84c81fc1e23474e13be0114f94f99b43696830f33292fd1d642f37e87e95acd6"
}

Use eth_getTransactionReceipt to retrieve full details.

eth_getTransactionReceipt

Returns the receipt of a transaction by transaction hash.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getTransactionReceipt
   &txhash=0x50b43f829e0b7044decbac0dc9216de1c7bf9a271999ed978300da1f5dc90c51
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

txhash

the string representing the hash of the transaction

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":{
      "blockHash":"0xd201810e935bed977bdb63ac5e8e7328acaefe3ec5447597f8b2493728a6c1e3",
      "blockNumber":"0x10a574",
      "contractAddress":null,
      "cumulativeGasUsed":"0x5208",
      "effectiveGasPrice":"0x59682f07",
      "from":"0x9907dd452706a9783e241d7b16e6ad0759ae051e",
      "gasUsed":"0x5208",
      "logs":[
         
      ],
      "logsBloom":"0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
      "status":"0x1",
      "to":"0x105083929bf9bb22c26cb1777ec92661170d4285",
      "transactionHash":"0x50b43f829e0b7044decbac0dc9216de1c7bf9a271999ed978300da1f5dc90c51",
      "transactionIndex":"0x0",
      "type":"0x2"
   }
}

eth_call

Executes a new message call immediately without creating a transaction on the block chain.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_call
   &to=0x272c31fc25e4e609cbcc9e7a9e6171b4b39feaca
   &data=0x60fe47b10000000000000000000000000000000000000000000000000000000000010f2c
   &tag=latest
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

to

the string representing the address to interact with

data

the hash of the method signature and encoded parameters

tag

the string pre-defined block parameter, either earliest, pending or latest

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":"0x"
}

eth_getCode

Returns code at a given address.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getCode
   &address=0x272c31fc25e4e609cbcc9e7a9e6171b4b39feaca
   &tag=latest
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

address

the string representing the address to get code

tag

the string pre-defined block parameter, either earliest, pending or latest

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":"0x608060405234801561001057600080fd5b50600436106100365760003560e01c806360fe47b11461003b5780636d4ce63c14610057575b600080fd5b6100556004803603810190610050919061009d565b610075565b005b61005f61007f565b60405161006c91906100d9565b60405180910390f35b8060008190555050565b60008054905090565b60008135905061009781610103565b92915050565b6000602082840312156100b3576100b26100fe565b5b60006100c184828501610088565b91505092915050565b6100d3816100f4565b82525050565b60006020820190506100ee60008301846100ca565b92915050565b6000819050919050565b600080fd5b61010c816100f4565b811461011757600080fd5b5056fea2646970667358221220d7dae2ccb3d6437f2a190839abef6ef723207c70463c87c2b1257d40c938e42564736f6c63430008070033"
}

eth_getStorageAt

Returns the value from a storage position at a given address.

This endpoint is still experimental and may have potential issues

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_getStorageAt
   &address=0x272c31fc25e4e609cbcc9e7a9e6171b4b39feaca
   &position=0x0
   &tag=latest
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

address

the string representing the address to get code

position

the hex code of the position in storage, eg 0x0

tag

the string pre-defined block parameter, either earliest, pending or latest

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":"0x000000000000x0000000000000000000000000000000000000000000000000000000000010f2c00000000000000000000000000000000000000000000000000000"
}

eth_gasPrice

Returns the current price per gas in wei.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_gasPrice
   &apikey=YourApiKeyToken

No parameters required.

Sample Response

{
   "jsonrpc":"2.0",
   "id":73,
   "result":"0x3b9aca07"
}

eth_estimateGas

Makes a call or transaction, which won't be added to the blockchain and returns the used gas.

https://api-curtis.apescan.io/api
   ?module=proxy
   &action=eth_estimateGas
   &data=0x60fe47b10000000000000000000000000000000000000000000000000000000000000004
   &to=0x272c31fC25E4e609CbCC9E7a9e6171b4B39feAca
   &value=0x0
   &gasPrice=0x51da038cc
   &gas=0x186A0
   &apikey=YourApiKeyToken

Query Parameters

Parameter
Description

data

the hash of the method signature and encoded parameters

to

the string representing the address to interact with

value

the value sent in this transaction, in hex eg. 0xff22

gas

the amount of gas provided for the transaction, in hex eg. 0x5f5e0ff

gasPrice

the gas price paid for each unit of gas, in wei

post EIP-1559, the gasPrice has to be higher than the block's baseFeePerGas

Sample Response

{
   "jsonrpc":"2.0",
   "id":1,
   "result":"0x67ea"
}

Stats

Get Total Supply of Ether

Returns the current amount of Ether in circulation.

Get Ether Last Price

Returns the latest price of 1 ETH.

Try this endpoint in your

Query Parameters

Parameter
Description

blockno

the integer block number to check block rewards for eg. 12697906

Sample Response

{
   "status":"1",
   "message":"OK",
   "result":{
      "blockNumber":"1090932",
      "timeStamp":"1652449149",
      "blockMiner":"0xd87def8bbd2c4d59494611ab259a2005c154212a",
      "blockReward":"2000031500000000000",
      "uncles":[
         
      ],
      "uncleInclusionReward":"0"
   }
}

​​ Tip : The timestamp field is denoted in

Try this endpoint in your

Try this endpoint in your

Tip : Convert a regular date-time to a

Try this endpoint in your

Query Parameters

Parameter
Description

contractaddress

the contract address of the ERC-20 token

Sample Response

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

Tip : The result is returned in the token's smallest decimal representation.

Eg. a token with a balance of 215.241526476136819398 and 18 decimal places will be returned as 215241526476136819398

Try this endpoint in your

Tip : The result is returned in the token's smallest decimal representation.

Get Contract ABI for

Find verified contracts on our page.

Try this endpoint in your

Get Contract Source Code for

Tip : You can also download a of which the code publishers have provided a corresponding Open Source license for redistribution.

Try this endpoint in your

Try this endpoint in your

Note : This endpoint is limited to 100 verifications/day, regardless of API PRO tier.

used, such as v0.8.24+commit.e11b9ed9

Note : This endpoint is limited to 100 verifications/day, regardless of API PRO tier.

the Vyper source code, in

Try this endpoint in your

If your encounter an error, reference our

For the full documentation of available parameters and descriptions, please visit the official docs.

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Tip: Send a POST request if your hex string is particularly long.

For more information on creating a signed raw transaction, visit this

Note: The result represents the transaction hash of the submitted raw transaction.

Try this endpoint in your

Try this endpoint in your

Note: The gas parameter is capped at 2x the current block gas limit.

Try this endpoint in your

Try this endpoint in your

Try this endpoint in your

Tip: The result is returned in wei.

Easily convert Ethereum units using our

Try this endpoint in your

Note: The gas parameter is capped at 2x the current block gas limit.

Try this endpoint in your

No parameters required.

Sample Response

Tip : Easily convert Ethereum units using our

Try this endpoint in your

No parameters required.

Sample Response

Tip : The timestamps are represented in

📈
📈
📝
📝
💡
⛏️
⛽
📖
⛽
🔗
browser
⏳
Unix timestamp.
🔗
browser
🔗
browser
⏳
Unix timestamp.
🔗
browser
🔗
browser
Verified Contract Source Codes
✅
Verified Contracts Source Code
🔗
browser
Verified Contract Source Codes
📩
CSV list of verified contracts addresses
🔗
browser
🔗
browser
🔗
browser
error list
Ethereum JSON-RPC
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🖋️
page.
🔗
browser
🔗
browser
🔗
browser
🔗
browser
🔗
browser
unit converter.
🔗
browser
https://api-curtis.apescan.io/api
   ?module=stats
   &action=ethsupply
   &apikey=YourApiKeyToken
https://api-curtis.apescan.io/api
   ?module=stats
   &action=ethprice
   &apikey=YourApiKeyToken
compiler version
JSON format
🔗
browser
{
   "status":"1",
   "message":"OK",
   "result":"77523186686500000000000000"
}
📖
unit converter.
🔗
browser
{
   "status":"1",
   "message":"OK",
   "result":{
      "ethbtc":"0.06906",
      "ethbtc_timestamp":"1652444393",
      "ethusd":"2110.63",
      "ethusd_timestamp":"1652444395"
   }
}
⏳
Unix timestamp.