NodeChain EN
  • NodeChain
  • Learn
    • About NodeChain
    • Infrastructure
      • Connector
        • Wrapper APIs
      • Nodes
      • Startup script
    • License
    • Ecosystem
      • Supported APIs
      • Integrations
      • Acknowledgments
  • Develop
    • Quick start
      • Initial setup
      • Using command-line script
        • Commands
    • How-to
      • Run tests locally
      • Lint automatically with hooks
      • Integrate a new Blockchain/API
      • Connect to a public node
    • Wrapper API definition file
    • Contributing
  • Reference
    • API Reference
      • Admin
      • General Endpoints
      • REST Wrapper API
        • Bitcoin Cash
        • Bitcoin
        • Ethereum
          • ERC-20
      • JSON-RPC Wrapper API
        • Bitcoin Cash
        • Bitcoin
        • Ethereum
          • ERC-20
      • Real-Time Wrapper API
        • Bitcoin
        • Ethereum
Powered by GitBook
On this page
  1. Reference
  2. API Reference
  3. JSON-RPC Wrapper API

Ethereum

Ethereum endpoints

PreviousBitcoinNextERC-20

Last updated 3 years ago

Ethereum JSON-RPC methods share the same endpoint, by protocol definition, the payload methodparameter is the one used to know which method is the one to be called. To call this methods, is mandatory to specify the currency, eth in this case and the network in which to executed the request. Bitcoin JSON-RPC methods are exposed in the following endpoint http://server/eth/{network}/rpc where network has to be replace by the network name in which make the request

  • POSTReturn the balance of any address
  • POSTReturn the balance of an array of addresses
  • POSTReturns latest block hash and index
  • POSTReturns the current price per gas in wei.
  • POSTReturns if blockchain is syncing
  • POSTBroadcast a transaction to the network
  • POSTGenerates and returns an estimate of how much gas is necessary to allow the transaction to complete
  • POSTReturns the information of any block giving its hash
  • POSTReturns the information of any block giving its height
  • POSTReturns the number of success/pending transactions of any address
  • POSTReturns the number of success/pending transactions of an array of address
  • POSTReturns the receipt of a transaction by transaction hash
  • POSTReturns the transaction info given its hash
  • POSTReturns the transactions info given an array of transaction hashes
  • POSTExecutes a new message call immediately without creating a transaction on the block chain
  • POSTGet transaction history of an address
  • POSTGet transaction history of an array of address
  • POSTReturns the status of the transaction indexing process.

Return the balance of any address

post

Return the balance of any address

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getAddressBalance

Example: getAddressBalance
Responses
200
Successful response
application/json
post
POST /getAddressBalance HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 124

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getAddressBalance",
  "params": {
    "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd"
  }
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
    "balance": {
      "confirmed": "10000",
      "unconfirmed": "0"
    }
  }
}

Return the balance of an array of addresses

post

Return the balance of an array of addresses

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getAddressesBalance

Example: getAddressesBalance
Responses
200
Successful response
application/json
post
POST /getAddressesBalance HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 130

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getAddressesBalance",
  "params": {
    "addresses": [
      "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd"
    ]
  }
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": [
    {
      "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "balance": {
        "confirmed": "10000",
        "unconfirmed": "0"
      }
    }
  ]
}

Returns latest block hash and index

post

Returns latest block hash and index

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getHeight

Example: getHeight
paramsobjectRequired
Responses
200
Successful response
application/json
post
POST /getHeight HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 62

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getHeight",
  "params": {}
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "latestBlockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
    "latestBlockIndex": "1"
  }
}

Returns the current price per gas in wei.

post

Returns the current price per gas in wei.

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getGasPrice

Example: getGasPrice
paramsobjectRequired
Responses
200
Successful response
application/json
post
POST /getGasPrice HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 64

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getGasPrice",
  "params": {}
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "gasPrice": "7982291"
  }
}

Returns if blockchain is syncing

post

Returns True if blocks are syncing and returns False if theres no synchronization or is fully sychronize

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be syncing

Example: syncing
paramsobjectRequired
Responses
200
Successful response
application/json
post
POST /syncing HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 60

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "syncing",
  "params": {}
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "syncing": false,
    "syncPercentage": "6.905658629231632%",
    "currentBlockIndex": "1",
    "latestBlockIndex": "1"
  }
}

Broadcast a transaction to the network

post

Broadcast a transaction to the network

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be broadcastTransaction

Example: broadcastTransaction
Responses
200
Successful response
application/json
post
POST /broadcastTransaction HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 176

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "broadcastTransaction",
  "params": {
    "rawTransaction": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
  }
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "broadcasted": "0xe670ec64341771606e55d6b4ca35a1a6b75ee3d5145a99d05921026d1527331"
  }
}

Generates and returns an estimate of how much gas is necessary to allow the transaction to complete

post

The transaction will not be added to the blockchain. Note that the estimate may be significantly more than the amount of gas actually used by the transaction, for a variety of reasons including EVM mechanics and node performance.

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be estimateGas

Example: estimateGas
Responses
200
Successful response
application/json
post
POST /estimateGas HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 325

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "estimateGas",
  "params": {
    "tx": {
      "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "gas": "0x79ccd3",
      "gasPrice": "7982291",
      "value": "0x9184e72a",
      "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
    }
  }
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "estimatedGas": "7982291"
  }
}

Returns the information of any block giving its hash

post

Returns the information of any block giving its hash

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getBlockByHash

Example: getBlockByHash
Responses
200
Successful response
application/json
post
POST /getBlockByHash HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 159

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getBlockByHash",
  "params": {
    "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
    "verbose": 2
  }
}
200

Successful response

{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "block": {
      "number": "0x1",
      "hash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
      "parentHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
      "nonce": "0x4db7a1c01d8a8072",
      "miner": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "size": "0x41c7",
      "mixHash": "0x3d1fdd16f15aeab72e7db1013b9f034ee33641d92f71c0736beab4e67d34c7a7",
      "sha3Uncles": "0x8a562e7634774d3e3a36698ac4915e37fc84a2cd0044cb84fa5d80263d2af4f6",
      "logsBloom": "0x4848112002a2020aaa0812180045840210020005281600c80104264300080008000491220144461026015300100000128005018401002090a824a4150015410020140400d808440106689b29d0280b1005200007480ca950b15b010908814e01911000054202a020b05880b914642a0000300003010044044082075290283516be82504082003008c4d8d14462a8800c2990c88002a030140180036c220205201860402001014040180002006860810ec0a1100a14144148408118608200060461821802c081000042d0810104a8004510020211c088200420822a082040e10104c00d010064004c122692020c408a1aa2348020445403814002c800888208b1",
      "transactionsRoot": "0xf98631e290e88f58a46b7032f025969039aa9b5696498efc76baf436fa69b262",
      "difficulty": "0x12ac11391a2f3872fcd",
      "gasLimit": "0x79ccd3",
      "gasUsed": "0x79ccd3",
      "extraData": "0x737061726b706f6f6c2d636e2d6e6f64652d3132",
      "timestamp": "0x5b541449",
      "totalDifficulty": "0x12ac11391a2f3872fcd",
      "stateRoot": "0xf5208fffa2ba5a3f3a2f64ebd5ca3d098978bedd75f335f56b705d8715ee2305",
      "transactions": [
        {
          "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "gas": "0x79ccd3",
          "gasPrice": "7982291",
          "value": "0x9184e72a",
          "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
          "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
          "blockNumber": "0x1",
          "hash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
          "input": "0x6ea056a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000bd8d7fa6f8cc00",
          "nonce": "0x4db7a1c01d8a8072",
          "r": "0xd1556332df97e3bd911068651cfad6f975a30381f4ff3a55df7ab3512c78b9ec",
          "s": "0x66b51cbb10cd1b2a09aaff137d9f6d4255bf73cb7702b666ebd5af502ffa4410",
          "v": "0x25",
          "transactionIndex": "0x1"
        }
      ],
      "uncles": [
        {
          "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "gas": "0x79ccd3",
          "gasPrice": "7982291",
          "value": "0x9184e72a",
          "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
          "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
          "blockNumber": "0x1",
          "hash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
          "input": "0x6ea056a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000bd8d7fa6f8cc00",
          "nonce": "0x4db7a1c01d8a8072",
          "r": "0xd1556332df97e3bd911068651cfad6f975a30381f4ff3a55df7ab3512c78b9ec",
          "s": "0x66b51cbb10cd1b2a09aaff137d9f6d4255bf73cb7702b666ebd5af502ffa4410",
          "v": "0x25",
          "transactionIndex": "0x1"
        }
      ]
    }
  }
}

Returns the information of any block giving its height

post

Returns the information of any block giving its height

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getBlockByNumber

Example: getBlockByNumber
Responses
200Success
application/json
post
POST /getBlockByNumber HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 100

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getBlockByNumber",
  "params": {
    "blockNumber": "0x1",
    "verbose": 2
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "block": {
      "number": "0x1",
      "hash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
      "parentHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
      "nonce": "0x4db7a1c01d8a8072",
      "miner": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "size": "0x41c7",
      "mixHash": "0x3d1fdd16f15aeab72e7db1013b9f034ee33641d92f71c0736beab4e67d34c7a7",
      "sha3Uncles": "0x8a562e7634774d3e3a36698ac4915e37fc84a2cd0044cb84fa5d80263d2af4f6",
      "logsBloom": "0x4848112002a2020aaa0812180045840210020005281600c80104264300080008000491220144461026015300100000128005018401002090a824a4150015410020140400d808440106689b29d0280b1005200007480ca950b15b010908814e01911000054202a020b05880b914642a0000300003010044044082075290283516be82504082003008c4d8d14462a8800c2990c88002a030140180036c220205201860402001014040180002006860810ec0a1100a14144148408118608200060461821802c081000042d0810104a8004510020211c088200420822a082040e10104c00d010064004c122692020c408a1aa2348020445403814002c800888208b1",
      "transactionsRoot": "0xf98631e290e88f58a46b7032f025969039aa9b5696498efc76baf436fa69b262",
      "difficulty": "0x12ac11391a2f3872fcd",
      "gasLimit": "0x79ccd3",
      "gasUsed": "0x79ccd3",
      "extraData": "0x737061726b706f6f6c2d636e2d6e6f64652d3132",
      "timestamp": "0x5b541449",
      "totalDifficulty": "0x12ac11391a2f3872fcd",
      "stateRoot": "0xf5208fffa2ba5a3f3a2f64ebd5ca3d098978bedd75f335f56b705d8715ee2305",
      "transactions": [
        {
          "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "gas": "0x79ccd3",
          "gasPrice": "7982291",
          "value": "0x9184e72a",
          "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
          "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
          "blockNumber": "0x1",
          "hash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
          "input": "0x6ea056a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000bd8d7fa6f8cc00",
          "nonce": "0x4db7a1c01d8a8072",
          "r": "0xd1556332df97e3bd911068651cfad6f975a30381f4ff3a55df7ab3512c78b9ec",
          "s": "0x66b51cbb10cd1b2a09aaff137d9f6d4255bf73cb7702b666ebd5af502ffa4410",
          "v": "0x25",
          "transactionIndex": "0x1"
        }
      ],
      "uncles": [
        {
          "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "gas": "0x79ccd3",
          "gasPrice": "7982291",
          "value": "0x9184e72a",
          "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
          "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
          "blockNumber": "0x1",
          "hash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
          "input": "0x6ea056a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000bd8d7fa6f8cc00",
          "nonce": "0x4db7a1c01d8a8072",
          "r": "0xd1556332df97e3bd911068651cfad6f975a30381f4ff3a55df7ab3512c78b9ec",
          "s": "0x66b51cbb10cd1b2a09aaff137d9f6d4255bf73cb7702b666ebd5af502ffa4410",
          "v": "0x25",
          "transactionIndex": "0x1"
        }
      ]
    }
  }
}

Returns the number of success/pending transactions of any address

post

Returns the number of success/pending transactions of any address

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getAddressTransactionCount

Example: getAddressTransactionCount
Responses
200Success
application/json
post
POST /getAddressTransactionCount HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 148

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getAddressTransactionCount",
  "params": {
    "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
    "pending": true
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "transactionCount": 0
  }
}

Returns the number of success/pending transactions of an array of address

post

Returns the number of success/pending transactions of an array of any address

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getAddressesTransactionCount

Example: getAddressesTransactionCount
Responses
200Success
application/json
post
POST /getAddressesTransactionCount HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 166

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getAddressesTransactionCount",
  "params": {
    "addresses": [
      {
        "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
        "pending": true
      }
    ]
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "transactionCount": "0"
  }
}

Returns the receipt of a transaction by transaction hash

post

Returns the receipt of a transaction by transaction hash

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getTransactionReceipt

Example: getTransactionReceipt
Responses
200Success
application/json
post
POST /getTransactionReceipt HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 151

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getTransactionReceipt",
  "params": {
    "txHash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f"
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "transactionHash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
    "transactionIndex": "0x1",
    "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
    "blockNumber": "0x1",
    "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
    "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
    "cumulativeGasUsed": "0x79ccd3",
    "gasUsed": "0x79ccd3",
    "contractAddress": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
    "logs": {
      "removed": true,
      "logIndex": "0x1",
      "transactionIndex": "0x1",
      "transactionHash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
      "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
      "blockNumber": "0x1",
      "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "data": "0x000000000000000000000000398137383b3d25c92898c656696e41950e47316b00000000000000000000000000000000000000000000000000000000000cee6100000000000000000000000000000000000000000000000000000000000ac3e100000000000000000000000000000000000000000000000000000000005baf35",
      "topics": [
        "0x241ea03ca20251805084d27d4440371c34a0b85ff108f6bb5611248f73818b80"
      ]
    },
    "logsBloom": "0x4848112002a2020aaa0812180045840210020005281600c80104264300080008000491220144461026015300100000128005018401002090a824a4150015410020140400d808440106689b29d0280b1005200007480ca950b15b010908814e01911000054202a020b05880b914642a0000300003010044044082075290283516be82504082003008c4d8d14462a8800c2990c88002a030140180036c220205201860402001014040180002006860810ec0a1100a14144148408118608200060461821802c081000042d0810104a8004510020211c088200420822a082040e10104c00d010064004c122692020c408a1aa2348020445403814002c800888208b1"
  }
}

Returns the transaction info given its hash

post

Returns the transaction info given its hash

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getTransaction

Example: getTransaction
Responses
200Success
application/json
post
POST /getTransaction HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 144

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getTransaction",
  "params": {
    "txHash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f"
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "transaction": {
      "txHash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
      "fee": "7982291",
      "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
      "blockNumber": "1",
      "timestamp": "1653156295",
      "inputs": [
        {
          "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "amount": "1000000000000000000"
        }
      ],
      "outputs": [
        {
          "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "amount": "1000000000000000000"
        }
      ],
      "data": {
        "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
        "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
        "gas": "0x79ccd3",
        "gasPrice": "7982291",
        "value": "0x9184e72a",
        "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
        "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
        "blockNumber": "0x1",
        "hash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
        "input": "0x6ea056a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000bd8d7fa6f8cc00",
        "nonce": "0x4db7a1c01d8a8072",
        "r": "0xd1556332df97e3bd911068651cfad6f975a30381f4ff3a55df7ab3512c78b9ec",
        "s": "0x66b51cbb10cd1b2a09aaff137d9f6d4255bf73cb7702b666ebd5af502ffa4410",
        "v": "0x25",
        "transactionIndex": "0x1"
      }
    }
  }
}

Returns the transactions info given an array of transaction hashes

post

Returns the transactions info given an array of transaction hashes

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getTransaction

Example: getTransaction
Responses
200Success
application/json
post
POST /getTransactions HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 148

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getTransaction",
  "params": {
    "txHashes": [
      "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f"
    ]
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "transactions": [
      {
        "txHash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
        "fee": "7982291",
        "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
        "blockNumber": "1",
        "timestamp": "1653156295",
        "inputs": [
          {
            "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
            "amount": "1000000000000000000"
          }
        ],
        "outputs": [
          {
            "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
            "amount": "1000000000000000000"
          }
        ],
        "data": {
          "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
          "gas": "0x79ccd3",
          "gasPrice": "7982291",
          "value": "0x9184e72a",
          "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675",
          "blockHash": "0x6403b287ab8bd587cd9e07c3d2ca62269f19dfb7c195892980f14d71fefa7cdd",
          "blockNumber": "0x1",
          "hash": "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f",
          "input": "0x6ea056a9000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000bd8d7fa6f8cc00",
          "nonce": "0x4db7a1c01d8a8072",
          "r": "0xd1556332df97e3bd911068651cfad6f975a30381f4ff3a55df7ab3512c78b9ec",
          "s": "0x66b51cbb10cd1b2a09aaff137d9f6d4255bf73cb7702b666ebd5af502ffa4410",
          "v": "0x25",
          "transactionIndex": "0x1"
        }
      }
    ]
  }
}

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

post

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

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be call

Example: call
Responses
200Success
application/json
post
POST /call HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 350

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "call",
  "params": {
    "transaction": {
      "from": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "to": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "gas": "0x79ccd3",
      "gasPrice": "7982291",
      "value": "0x9184e72a",
      "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
    },
    "blockNumber": "latest"
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
  }
}

Get transaction history of an address

post

Get transaction history of aaddresses

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getAddressHistory

Example: getAddressHistory
Responses
200Success
application/json
post
POST /getAddressHistory HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 124

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getAddressHistory",
  "params": {
    "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd"
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
    "txHashes": [
      "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f"
    ]
  }
}

Get transaction history of an array of address

post

Get transaction history of an array of addresses

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be getAddressesHistory

Example: getAddressesHistory
Responses
200Success
application/json
post
POST /getAddressesHistory HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 130

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "getAddressesHistory",
  "params": {
    "addresses": [
      "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd"
    ]
  }
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": [
    {
      "address": "0x625ACaEdeF812d2842eFd2Fb0294682A868455bd",
      "txHashes": [
        "0x8784d99762bccd03b2086eabccee0d77f14d05463281e121a62abfebcf0d2d5f"
      ]
    }
  ]
}

Returns the status of the transaction indexing process.

post

Returns the status of the transaction indexing process.

Body
idinteger · int32Required

Request ID

Example: 160907
jsonrpcstringRequired

JSON-RPC Version

Example: 2.0
methodstringRequired

Method name to be called. For this operation, the field value must be indexing

Example: indexing
paramsobjectRequired
Responses
200Success
application/json
post
POST /indexing HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 61

{
  "id": 160907,
  "jsonrpc": "2.0",
  "method": "indexing",
  "params": {}
}
200Success
{
  "id": 160907,
  "jsonrpc": "2.0",
  "result": {
    "indexing": true,
    "indexingPercentage": "6.905658629231632%",
    "currentBlockIndex": "1",
    "latestBlockIndex": "1"
  }
}