{
"definitions": {
"Block": {
"type": "object",
"properties": {
"blockHeader": {
"$ref": "#/definitions/BlockHeader"
},
"rlp": {
"$ref": "#/definitions/HexData"
},
"transactions": {
"type": "array",
"items": {
"$ref": "#/definitions/Transaction"
}
},
"uncleHeaders": {
"type": "array"
},
"expectExceptionHomestead": {
"type": "string"
},
"expectExceptionFrontier": {
"type": "string"
},
"expectExceptionEIP158": {
"type": "string"
},
"expectExceptionEIP150": {
"type": "string"
},
"expectExceptionALL": {
"type": "string"
},
"expectExceptionByzantium": {
"type": "string"
},
"expectExceptionConstantinople": {
"type": "string"
},
"blocknumber": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"chainname": {
"type": "string"
},
"chainnetwork": {
"type": "string"
},
"comment": {
"type": "string"
}
},
"additionalProperties": false
},
"BlockHeader": {
"properties": {
"bloom": {
"$ref": "#/definitions/HexData"
},
"coinbase": {
"$ref": "#/definitions/AddressMaybePrefixOrEmpty"
},
"difficulty": {
"$ref": "#/definitions/ConfusedHexType"
},
"extraData": {
"$ref": "#/definitions/HexMaybePrefixOrEmpty"
},
"gasLimit": {
"$ref": "#/definitions/ConfusedHexType"
},
"gasUsed": {
"$ref": "#/definitions/ConfusedHexType"
},
"hash": {
"$ref": "#/definitions/ConfusedHexType"
},
"mixHash": {
"$ref": "#/definitions/ConfusedHexType"
},
"nonce": {
"$ref": "#/definitions/ConfusedHexType"
},
"number": {
"$ref": "#/definitions/ConfusedHexType"
},
"parentHash": {
"$ref": "#/definitions/ConfusedHexType"
},
"receiptTrie": {
"$ref": "#/definitions/ConfusedHexType"
},
"stateRoot": {
"$ref": "#/definitions/ConfusedHexType"
},
"timestamp": {
"$ref": "#/definitions/ConfusedHexType"
},
"transactionsTrie": {
"$ref": "#/definitions/ConfusedHexType"
},
"uncleHash": {
"$ref": "#/definitions/ConfusedHexType"
}
}
},
"EmptyString": {
"type": "string",
"pattern": "^$"
},
"HexData": {
"description": "Hex data. see https://github.com/ethereum/wiki/wiki/JSON-RPC#hex-value-encoding",
"pattern": "^0x([0-9a-fA-F][0-9a-fA-F])*$",
"type": "string"
},
"HexQuantity": {
"description": "Hex quantity. see https://github.com/ethereum/wiki/wiki/JSON-RPC#hex-value-encoding",
"pattern": "(^0x0$)|(^0x[1-9a-fA-F][0-9a-fA-F]*$)",
"type": "string"
},
"ConfusedHexType": {
"anyOf": [
{
"$ref": "#/definitions/HexData"
},
{
"$ref": "#/definitions/HexQuantity"
}
]
},
"HexDataOrEmpty": {
"oneOf": [
{
"$ref": "#/definitions/HexData"
},
{
"$ref": "#/definitions/EmptyString"
}
]
},
"HexNoPrefix": {
"pattern": "^([0-9a-fA-F][0-9a-fA-F])+$",
"type": "string"
},
"HexMaybePrefix": {
"oneOf": [
{
"$ref": "#/definitions/HexNoPrefix"
},
{
"$ref": "#/definitions/HexData"
}
]
},
"HexMaybePrefixOrEmpty": {
"oneOf": [
{
"$ref": "#/definitions/HexMaybePrefix"
},
{
"$ref": "#/definitions/EmptyString"
}
]
},
"IntegerString": {
"pattern": "^[0-9]+$",
"type": "string"
},
"IntegerOrEmpty": {
"oneOf": [
{
"$ref": "#/definitions/IntegerString"
},
{
"$ref": "#/definitions/EmptyString"
}
]
},
"IntegerOrNumber": {
"oneOf": [
{
"$ref": "#/definitions/IntegerString"
},
{
"type": "number"
}
]
},
"IntegerOrNumberOrConfusedHex": {
"oneOf": [
{
"$ref": "#/definitions/IntegerOrNumber"
},
{
"$ref": "#/definitions/ConfusedHexType"
}
]
},
"IntegerOrEmptyOrHexQuantity": {
"oneOf": [
{
"$ref": "#/definitions/IntegerOrEmpty"
},
{
"$ref": "#/definitions/HexQuantity"
}
]
},
"IntegerOrHexQuantity": {
"oneOf": [
{
"$ref": "#/definitions/IntegerString"
},
{
"$ref": "#/definitions/HexQuantity"
}
]
},
"IntegerOrConfusedHex": {
"anyOf": [
{
"$ref": "#/definitions/IntegerString"
},
{
"$ref": "#/definitions/ConfusedHexType"
}
]
},
"IntegerOrEmptyOrConfusedHex": {
"oneOf": [
{
"$ref": "#/definitions/IntegerOrEmpty"
},
{
"$ref": "#/definitions/ConfusedHexType"
}
]
},
"PreStateAccount": {
"type": "object",
"additionalproperties": true,
"properties": {
"balance": {
"$ref": "#/definitions/ConfusedHexType"
},
"code": {
"$ref": "#/definitions/HexMaybePrefixOrEmpty"
},
"nonce": {
"$ref": "#/definitions/ConfusedHexType"
},
"storage": {
"type": "object",
"additionalProperties": false,
"patternProperties": {
"^0x[0-9a-f]+": {
"description": "storage key with 0x. data is HexData",
"$ref": "#/definitions/HexData"
}
}
}
},
"required": [
"balance",
"code",
"nonce"
]
},
"TxSigR": {
"oneOf": [
{
"enum": [
"0x00"
]
}
]
},
"TxSigS": {
"oneOf": [
{
"enum": [
"0x00"
]
}
]
},
"TxSigV": {
"description": "a value of 0 is an invalid chainId, but used in a test case",
"oneOf": [
{
"enum": [
"0x00",
"0x01"
]
}
]
},
"HexLen40": {
"pattern": "^0x[0-9a-fA-F]{40}$",
"type": "string"
},
"HexNoPrefixLen40": {
"pattern": "^[0-9a-fA-F]{40}$",
"type": "string"
},
"AddressMaybePrefixOrEmpty": {
"oneOf": [
{
"$ref": "#/definitions/HexLen40"
},
{
"$ref": "#/definitions/HexNoPrefixLen40"
},
{
"$ref": "#/definitions/EmptyString"
}
]
},
"Transaction": {
"type": "object",
"additionalProperties": true,
"not": {
"required": [
"r, s, v"
]
},
"properties": {
"data": {
"$ref": "#/definitions/HexDataOrEmpty"
},
"gasLimit": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"gasPrice": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"nonce": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"secretKey": {
"$ref": "#/definitions/HexMaybePrefix"
},
"to": {
"$ref": "#/definitions/AddressMaybePrefixOrEmpty"
},
"value": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
}
},
"required": [
"data",
"gasLimit",
"gasPrice",
"nonce",
"to",
"value"
]
},
"NullSenderTransaction": {
"type": "object",
"additionalProperties": true,
"not": {
"required": [
"secretKey"
]
},
"properties": {
"data": {
"items": {
"$ref": "#/definitions/HexMaybePrefixOrEmpty"
},
"type": "array"
},
"gasLimit": {
"items": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"type": "array"
},
"gasPrice": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"nonce": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"r": {
"$ref": "#/definitions/TxSigR"
},
"s": {
"$ref": "#/definitions/TxSigS"
},
"to": {
"$ref": "#/definitions/AddressMaybePrefixOrEmpty"
},
"v": {
"$ref": "#/definitions/TxSigV"
},
"value": {
"items": {
"$ref": "#/definitions/IntegerOrEmptyOrConfusedHex"
},
"type": "array"
}
},
"required": [
"data",
"gasLimit",
"gasPrice",
"nonce",
"r",
"s",
"v",
"to",
"value"
]
},
"TransactionResults": {
"items": {
"additionalProperties": false,
"properties": {
"hash": {
"$ref": "#/definitions/HexData"
},
"logs": {},
"indexes": {
"additionalProperties": false,
"properties": {
"data": {
"type": "integer"
},
"gas": {
"type": "integer"
},
"value": {
"type": "integer"
}
},
"required": [
"data",
"gas",
"value"
],
"type": "object"
}
},
"required": [
"hash",
"indexes"
],
"type": "object"
},
"type": "array"
}
},
"patternProperties": {
"^.*$": {
"type": "object",
"properties": {
"genesisBlockHeader": {
"$ref": "#/definitions/BlockHeader"
},
"genesisRLP": {
"$ref": "#/definitions/ConfusedHexType"
},
"blocks": {
"type": "array",
"items": {
"$ref": "#/definitions/Block"
}
}
},
"postState": {
"$ref": "#/definitions/TransactionResults"
},
"pre": {
"$ref": "#/definitions/TransactionResults"
}
},
"required": [
"postState",
"pre",
"network",
"lastblockhash",
"blocks",
"genesisRLP",
"genesisBlockHeader"
]
}
}