Polluxchain
  1. Query The Network
Polluxchain
  • Background
  • API key
    • Rate Limits
    • Security Settings
  • Full Node HTTP API
    • Address Utilities
      • ValidateAddress
    • Transactions
      • BroadcastTransaction
      • BroadcastHex
      • CreateTransaction
    • Accounts
      • CreateAccount
      • GetAccount
      • UpdateAccount
      • AccountPermissionUpdate
      • GetAccountBalance
    • Account Resources
      • GetAccountResource
      • GetAccountNet
      • FreezeBalance
      • UnfreezeBalanceV2
      • CancelAllUnfreezeV2
      • DelegateResource
      • UnDelegateResource
      • WithdrawExpireUnfreeze
      • GetAvailableUnfreezeCount
      • GetCanWithdrawUnfreezeAmount
      • GetCanDelegatedMaxSize
      • GetDelegatedResourceV2
      • GetDelegatedResourceAccountIndexV2
    • Query The Network
      • GetBlock
        POST
      • GetBlockByNum
        POST
      • GetBlockById
        POST
      • GetBlockByLatestNum
        POST
      • GetBlockByLimitNext
        POST
      • GetNowBlock
        POST
      • GetTransactionById
        POST
      • GetTransactionInfoById
        POST
      • GetTransactionInfoByBlockNum
        POST
      • ListNodes
        GET
      • GetNodeInfo
        GET
      • GetChainParameters
        GET
      • GetBlockBalance
        POST
      • GetEnergyPrices
        GET
      • GetBandwidthPrices
        GET
      • GetBurnTRX
        GET
      • GetApprovedList
        POST
    • Smart Contract
      • GetContract
      • GetContractInfo
      • TriggerSmartContract
      • TriggerConstantContract
      • DeployContract
      • UpdateSetting
      • UpdateEnergyLimit
      • ClearAbi
      • EstimateEnergy
    • Voting & SRs
      • ListWitnesses
      • CreateWitness
      • UpdateWitness
      • GetBrokerage
      • UpdateBrokerage
      • VoteWitnessAccount
      • GetReward
      • WithdrawBalance
      • GetNextMaintenanceTime
    • Proposals
      • ListProposals
      • GetProposalById
      • ProposalCreate
      • ProposalApprove
      • ProposalDelete
    • Pending pool
      • GetTransactionListFromPending
      • GetTransactionFromPending
      • GetPendingSize
  • Full Node Solidity HTTP API
    • Transactions
      • GetTransactionById
      • GetTransactionInfoById
      • GetTransactionInfoByBlockNum
      • GetTransactionCountByBlockNum
    • Blocks
      • GetBlock
      • GetNowBlock
      • GetBlockByNum
      • GetBlockById
      • GetBlockByLatestNum
      • GetBlockByLimitNext
    • Account Resources
      • GetAccount
      • GetDelegatedResource
      • GetDelegatedResourceAccountIndex
      • GetCanDelegatedMaxSize
      • GetCanWithdrawUnfreezeAmount
      • GetDelegatedResourceAccountIndexV2
      • GetAvailableUnfreezeCount
    • Node & Chain
      • GetNodeInfo
      • GetBurnPOX
    • Smart Contracts
      • TriggerConstantContract
      • EstimateEnergy
    • Voting & SRs
      • ListWitnesses
      • GetReward
      • GetBrokerage
  • Full Node JSON-RPC API
    • Overview
    • buildTransaction
    • eth
      • eth_accounts
      • eth_blockNumber
      • eth_call
      • eth_chainId
      • eth_coinbase
      • eth_estimateGas
      • eth_gasPrice
      • eth_getBalance
      • eth_getBlockByHash
      • eth_getBlockByNumber
      • eth_getBlockTransactionCountByHash
      • eth_getBlockTransactionCountByNumber
      • eth_getCode
      • eth_getStorageAt
      • eth_getTransactionByBlockHashAndIndex
      • eth_getTransactionByBlockNumberAndIndex
      • eth_getTransactionByHash
      • eth_getTransactionReceipt
      • eth_getWork
      • eth_protocolVersion
      • eth_syncing
      • eth_newFilter
      • eth_newBlockFilter
      • eth_getFilterChanges
      • eth_getFilterLogs
      • eth_uninstallFilter
      • eth_getLogs
    • net
      • net_listening
      • net_peerCount
      • net_version
    • web3
      • web3_clientVersion
      • web3_sha3
  • PolluxWeb
    • address
    • createAccount
    • createRandom
    • fromAscii
    • fromDecimal
    • fromMnemonic
    • fromUtf8
    • getEventByTransactionID
    • getEventResult
    • isAddress
    • isConnected
    • setHeader
    • setDefaultBlock
    • setPrivateKey
    • setAddress
    • sha3
    • toAscii
    • toBigNumber
    • toDecimal
    • toHex
    • toRAM
    • toUtf8
    • BigNumber
    • polluxweb.trx
      • getAccount
      • getAccountResources
      • getApprovedList
      • getAvailableUnfreezeCount
      • getBalance
      • getBandwidth
      • getBlock
      • getBlockByHash
      • getBlockByNumber
      • getBlockRange
      • getBlockTransactionCount
      • getBrokerage
      • getCanDelegatedMaxSize
      • getCanWithdrawUnfreezeAmount
      • getChainParameters
      • getConfirmedTransaction
      • getContract
      • getCurrentBlock
      • getDelegatedResourceV2
      • getDelegatedResourceAccountIndexV2
      • getExchangeByID
      • getNodeInfo
      • getReward
      • getTokenByID
      • getTokenFromID
      • getTokenListByName
      • getTokensIssuedByAddress
      • getTransaction
      • getTransactionFromBlock
      • getTransactionInfo
      • getUnconfirmedBalance
      • getUnconfirmedBrokerage
      • getUnconfirmedReward
      • listExchanges
      • listExchangesPaginated
      • listNodes
      • listProposals
      • listSuperRepresentatives
      • listTokens
      • sendRawTransaction
      • sendHexTransaction
      • sendToken
      • sendTransaction
      • sign
      • signMessageV1
      • signMessageV2
      • timeUntilNextVoteCycle
      • multiSign
      • verifyMessage
      • verifyMessageV2
      • _signTypedData
      • verifyTypedData
    • polluxweb.transactionBuilder
      • addUpdateData
      • applyForSR
      • cancelUnfreezeBalanceV2
      • createAccount
      • createAsset
      • createProposal
      • createSmartContract
      • createToken
      • delegateResource
      • deleteProposal
      • estimateEnergy
      • extendExpiration
      • freezeBalance
      • freezeBalanceV2
      • injectExchangeTokens
      • purchaseAsset
      • purchaseToken
      • sendAsset
      • sendToken
      • sendTrx
      • tradeExchangeTokens
      • triggerConfirmedConstantContract
      • triggerConstantContract
      • triggerSmartContract
      • undelegateResource
      • unfreezeBalance
      • unfreezeBalanceV2
      • updateSetting
      • updateAccountPermissions
      • updateAsset
      • updateBrokerage
      • updateEnergyLimit
      • updateToken
      • vote
      • voteProposal
      • withdrawBlockRewards
      • withdrawExchangeTokens
      • withdrawExpireUnfreeze
    • poxweb.contract
      • polluxweb.contract.new
      • polluxweb.contract()
      • method.call()
      • method.send()
    • polluxweb.utils
      • transaction.txJsonToPb
      • transaction.txPbToTxID
      • message.hashMessage
  • Pollux CLI
    • Pollux CLI
  1. Query The Network

GetBlockById

POST
/wallet/getblockbyid
Query block by ID(block hash).
Returns
Block data, please refer to /wallet/getblock for the content contained in block.

Request

Body Params application/json
object {0}
Example
{
  "value": "00000000000f424013e51b18e0782a32fa079ddafdb2f4c343468cf8896dc887"
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/wallet/getblockbyid' \
--header 'Content-Type: application/json' \
--data-raw '{
  "value": "00000000000f424013e51b18e0782a32fa079ddafdb2f4c343468cf8896dc887"
}'

Responses

🟢200Success
application/json
Body
object {0}
Example
{
    "blockID": "00000000000f424013e51b18e0782a32fa079ddafdb2f4c343468cf8896dc887",
    "block_header": {
        "raw_data": {
            "number": 1000000,
            "txTrieRoot": "e2dd42daa9c853e070df1e4fc927851a7438c601fb12cf945922629d5cec187b",
            "witness_address": "41f16412b9a17ee9408646e2a21e16478f72ed1e95",
            "parentHash": "00000000000f423fbccd9cdb9e410eabdf9f94145cf5b71a678b8b9616619125",
            "version": 9,
            "timestamp": 1578594852000
        },
        "witness_signature": "179caed28b3d129dee6d553ae6761a8c8698f890e5f38e062d56e2d0d0b8c9a20317b7753b3fd1be261935d6182434a6c057f8926f25027b9859cde3da3a655300"
    },
    "transactions": [
        {
            "ret": [
                {
                    "contractRet": "SUCCESS"
                }
            ],
            "signature": [
                "95428ed2e263600933f82bf67f43e15450bc2da3b7b2987a7f46b0b9b9c4aae7ba5ea005b9297fbff5bca5fe5c9b05299433e36e10224c167f9c613b6dded39000"
            ],
            "txID": "7faabd22623eb53467d34b2a417262f6df75433566c104b6c6eec5a227090df6",
            "raw_data": {
                "contract": [
                    {
                        "parameter": {
                            "value": {
                                "data": "ae21db6f0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000051f5e04fa0000000000000000000000000000000000000000000000000000000004a9681c0000000000000000000000000000000000000000000000000000000004a8fe400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000051f5e04f9000000000000000000000000000000000000000000000000000000051f5e04f8000000000000000000000000000000000000000000000000000000051f5e04f7000000000000000000000000000000000000000000000000000000051f5e04f6000000000000000000000000000000000000000000000000000000051f5e04f5000000000000000000000000000000000000000000000000000000051f5e04f4000000000000000000000000000000000000000000000000000000051f5e04f3",
                                "owner_address": "41920bb75dd5751afd68e1d55a8a0bc1bc39b32c78",
                                "contract_address": "417090190c41ba59f763e2cbe7d885e007e94be5d2"
                            },
                            "type_url": "type.googleapis.com/protocol.TriggerSmartContract"
                        },
                        "type": "TriggerSmartContract"
                    }
                ],
                "ref_block_bytes": "423e",
                "ref_block_hash": "5c35fda2f1a9a386",
                "expiration": 1578594906000,
                "fee_limit": 1000000000,
                "timestamp": 1578594849159
            },
            "raw_data_hex": "0a02423e22085c35fda2f1a9a3864090dfdadcf82d5af003081f12eb030a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e747261637412b5030a1541920bb75dd5751afd68e1d55a8a0bc1bc39b32c781215417090190c41ba59f763e2cbe7d885e007e94be5d2228403ae21db6f0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000051f5e04fa0000000000000000000000000000000000000000000000000000000004a9681c0000000000000000000000000000000000000000000000000000000004a8fe400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000051f5e04f9000000000000000000000000000000000000000000000000000000051f5e04f8000000000000000000000000000000000000000000000000000000051f5e04f7000000000000000000000000000000000000000000000000000000051f5e04f6000000000000000000000000000000000000000000000000000000051f5e04f5000000000000000000000000000000000000000000000000000000051f5e04f4000000000000000000000000000000000000000000000000000000051f5e04f37087a3d7dcf82d90018094ebdc03"
        },
        {
            "ret": [
                {
                    "contractRet": "SUCCESS"
                }
            ],
            "signature": [
                "6e3f72c5d8bf433bf98ac3bbcdfbbb179d8cd8f5f6da5f1eb0466bbc80bcebee6dc0e5312796c37c3fe73d49f9b350cf61f4830deb7d846c90570f8afb3f513400"
            ],
            "txID": "98d0f4149bf8023a9df4d2b754f6c728a5b6d021c4497c6cd5452b97f01b0548",
            "raw_data": {
                "contract": [
                    {
                        "parameter": {
                            "value": {
                                "data": "0204b01b000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000db4df489cf3977fbf0d06e47885f3dc85446b4aa",
                                "owner_address": "41ed2f4270fa5a7cae1efd4706ae27a4335406921e",
                                "contract_address": "418d9dd663cf90256fdf2faba2a1be71f8a0147f8c",
                                "call_value": 14000000
                            },
                            "type_url": "type.googleapis.com/protocol.TriggerSmartContract"
                        },
                        "type": "TriggerSmartContract"
                    }
                ],
                "ref_block_bytes": "423f",
                "ref_block_hash": "bccd9cdb9e410eab",
                "expiration": 1578594909000,
                "fee_limit": 1000000000,
                "timestamp": 1578594849385
            },
            "raw_data_hex": "0a02423f2208bccd9cdb9e410eab40c8f6dadcf82d5ad401081f12cf010a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e74726163741299010a1541ed2f4270fa5a7cae1efd4706ae27a4335406921e1215418d9dd663cf90256fdf2faba2a1be71f8a0147f8c1880bfd60622640204b01b000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000db4df489cf3977fbf0d06e47885f3dc85446b4aa70e9a4d7dcf82d90018094ebdc03"
        },
        {
            "ret": [
                {
                    "contractRet": "SUCCESS"
                }
            ],
            "signature": [
                "230b8767e8745d01f38d2b9f742f4037eb81e93bcc9c2d60bedf4bab3b9e0c16692138a112f1610b505cf3109f3a5ff00d6687c09b3c94a734dd8aedfc92d82101"
            ],
            "txID": "17e7321320bb08c40f027cbcca320152c2396c77a910f387849a944ee8aa0cb1",
            "raw_data": {
                "contract": [
                    {
                        "parameter": {
                            "value": {
                                "data": "f6d4ef1a0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000051f5e04fa",
                                "owner_address": "41920bb75dd5751afd68e1d55a8a0bc1bc39b32c78",
                                "contract_address": "4179c23a5666042e40420d6afdc1541e3926205eba"
                            },
                            "type_url": "type.googleapis.com/protocol.TriggerSmartContract"
                        },
                        "type": "TriggerSmartContract"
                    }
                ],
                "ref_block_bytes": "423e",
                "ref_block_hash": "5c35fda2f1a9a386",
                "expiration": 1578594906000,
                "fee_limit": 1000000000,
                "timestamp": 1578594849187
            },
            "raw_data_hex": "0a02423e22085c35fda2f1a9a3864090dfdadcf82d5aae01081f12a9010a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e747261637412740a1541920bb75dd5751afd68e1d55a8a0bc1bc39b32c7812154179c23a5666042e40420d6afdc1541e3926205eba2244f6d4ef1a0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000051f5e04fa70a3a3d7dcf82d90018094ebdc03"
        },
        {
            "ret": [
                {
                    "contractRet": "SUCCESS"
                }
            ],
            "signature": [
                "55124a9bfb733a27fc193b00c9c2ce0c1f969ffd0ec59c295fea00a75501206b0d5333c16c8f6a5aa7a32a03268edd3ca903d41f386001733a7d0199bcedb8bb01"
            ],
            "txID": "4ef51a5760bf98dc2dd752658f48db1445e8ca75f8a6efe14d5a462a15edd3f0",
            "raw_data": {
                "contract": [
                    {
                        "parameter": {
                            "value": {
                                "data": "0204b01b00000000000000000000000000000000000000000000000000000000000000440000000000000000000000000000000000000000000000000000000000000003000000000000000000000000db4df489cf3977fbf0d06e47885f3dc85446b4aa",
                                "owner_address": "41f07e117a4b5f1fda66f8fcedf44065f1dafc5ad7",
                                "contract_address": "418d9dd663cf90256fdf2faba2a1be71f8a0147f8c",
                                "call_value": 1982000000
                            },
                            "type_url": "type.googleapis.com/protocol.TriggerSmartContract"
                        },
                        "type": "TriggerSmartContract"
                    }
                ],
                "ref_block_bytes": "423f",
                "ref_block_hash": "bccd9cdb9e410eab",
                "expiration": 1578594909000,
                "fee_limit": 1000000000,
                "timestamp": 1578594850315
            },
            "raw_data_hex": "0a02423f2208bccd9cdb9e410eab40c8f6dadcf82d5ad501081f12d0010a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e7472616374129a010a1541f07e117a4b5f1fda66f8fcedf44065f1dafc5ad71215418d9dd663cf90256fdf2faba2a1be71f8a0147f8c1880d78bb10722640204b01b00000000000000000000000000000000000000000000000000000000000000440000000000000000000000000000000000000000000000000000000000000003000000000000000000000000db4df489cf3977fbf0d06e47885f3dc85446b4aa708bacd7dcf82d90018094ebdc03"
        },
        {
            "ret": [
                {
                    "contractRet": "SUCCESS"
                }
            ],
            "signature": [
                "153d437be2c417d88bef564a1421d2c3debb9f3828e9276a58578eb566091d6a612d3294c124ba3a5da37815d49b7cc7a91be04c0304a8e9ecee02f4d3dc420901"
            ],
            "txID": "80e07e3f2b92a0e9974b1398964e006288836dee82aa3a81e579a512e6581354",
            "raw_data": {
                "contract": [
                    {
                        "parameter": {
                            "value": {
                                "data": "0204b01b00000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000003000000000000000000000000db4df489cf3977fbf0d06e47885f3dc85446b4aa",
                                "owner_address": "419ac63dd8e80daf0a786bf962860e2209b7fa5fb9",
                                "contract_address": "418d9dd663cf90256fdf2faba2a1be71f8a0147f8c",
                                "call_value": 11000000
                            },
                            "type_url": "type.googleapis.com/protocol.TriggerSmartContract"
                        },
                        "type": "TriggerSmartContract"
                    }
                ],
                "ref_block_bytes": "423f",
                "ref_block_hash": "bccd9cdb9e410eab",
                "expiration": 1578594909000,
                "fee_limit": 1000000000,
                "timestamp": 1578594851357
            },
            "raw_data_hex": "0a02423f2208bccd9cdb9e410eab40c8f6dadcf82d5ad401081f12cf010a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e74726163741299010a15419ac63dd8e80daf0a786bf962860e2209b7fa5fb91215418d9dd663cf90256fdf2faba2a1be71f8a0147f8c18c0b19f0522640204b01b00000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000003000000000000000000000000db4df489cf3977fbf0d06e47885f3dc85446b4aa709db4d7dcf82d90018094ebdc03"
        },
        {
            "ret": [
                {
                    "contractRet": "SUCCESS"
                }
            ],
            "signature": [
                "a2e6784005b0bd9f80dcb92de8f37133e3355a09496bd7467580805226e2ed520e48858456151dc681e423f0041ae877369a16e6d805facc7af9d27b712891bb01"
            ],
            "txID": "ba8e727c03d588619310d7a16a95fcfd31a516dbf8893ddd585e0bbd7e0deae4",
            "raw_data": {
                "contract": [
                    {
                        "parameter": {
                            "value": {
                                "data": "8a157bf900000000000000000000000000000000000000000000000000000000000019be",
                                "owner_address": "4141c910d7942636ae041975616104ef253e5a8371",
                                "contract_address": "41174e91a57d68f5ac1bc485d03a038fe745a3b89b"
                            },
                            "type_url": "type.googleapis.com/protocol.TriggerSmartContract"
                        },
                        "type": "TriggerSmartContract"
                    }
                ],
                "ref_block_bytes": "423f",
                "ref_block_hash": "bccd9cdb9e410eab",
                "expiration": 1578594909000,
                "fee_limit": 10000000,
                "timestamp": 1578594850984
            },
            "raw_data_hex": "0a02423f2208bccd9cdb9e410eab40c8f6dadcf82d5a8e01081f1289010a31747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e54726967676572536d617274436f6e747261637412540a154141c910d7942636ae041975616104ef253e5a8371121541174e91a57d68f5ac1bc485d03a038fe745a3b89b22248a157bf900000000000000000000000000000000000000000000000000000000000019be70a8b1d7dcf82d900180ade204"
        }
    ]
}
Previous
GetBlockByNum
Next
GetBlockByLatestNum
Built with