Log In

cfx_getTransactionReceipt - Conflux

Returns a transaction receipt, identified by the corresponding transaction hash.

Parameters

  • DATA, 32 Bytes - hash of a transaction

Returns

Object - a transaction receipt object, or null when no transaction was found or the transaction was not executed yet:

  • transactionHash: DATA, 32 Bytes - Hash of the given transaction.
  • index: QUANTITY - Transaction index within the block.
  • blockHash: DATA, 32 Bytes - Hash of the block where this transaction was in and got executed.
  • epochNumber: QUANTITY - Epoch number of the block where this transaction was in and got executed.
  • from: BASE32 - Address of the sender.
  • to: BASE32 - Address of the receiver. null when it is a contract deployment transaction.
  • gasUsed: QUANTITY - Gas used for executing the transaction.
  • gasFee: QUANTITY - Gas charged to the sender's account. If the provided gas (gas limit) is larger than the gas used, at most 1/4 of it is refunded.
  • gasCoveredBySponsor: Boolean, true if this transaction's gas fee was covered by the sponsor.
  • storageCollateralized: QUANTITY, the amount of storage collateral this transaction required.
  • storageCoveredBySponsor: Boolean, true if this transaction's storage collateral was covered by the sponsor.
  • storageReleased: Array, array of storage change objects, each specifying an address and the corresponding amount of storage collateral released, e.g., [{ 'address': 'CFX:TYPE.USER:AARC9ABYCUE0HHZGYRR53M6CXEDGCCRMMYYBJGH4XG', 'collaterals': '0x280' }]
  • contractCreated: BASE32 - Address of the contract created. null when it is not a contract deployment transaction.
  • stateRoot: DATA, 32 Bytes - Hash of the state root after the execution of the corresponding block. 0 if the state root is not available.
  • outcomeStatus: QUANTITY - The outcome status code. 0x0 means success. 0x1 means failed. 0x2 means skipped
  • logsBloom: DATA, 256 Bytes - Bloom filter for light clients to quickly retrieve related logs.
  • logs: Array - Array of log objects that this transaction generated, see cfx_getLogs.
  • txExecErrorMsg: String, tx exec fail message, if transaction exec success this will be null.

Example

Request

curl -X POST \
--data '{"jsonrpc":"2.0","method": "cfx_getTransactionReceipt",
    "params":  [
        "0x53fe995edeec7d241791ff32635244e94ecfd722c9fe90f34ddf59082d814514"
    ],"id":1}' \
-H "Content-Type: application/json" \
https://cfx-core.unifra.io/v1/ad2eb3c7a9404cc6a35a6641eaf70577 


Result

{
    "jsonrpc": "2.0",
    "result": {
        "blockHash": "0xf0375f56bd6fd2b5a470836644764e3eeaa9e5e3dc2efbc41316edf4003003f7",
        "contractCreated": null,
        "epochNumber": "0x12dd1ec",
        "from": "CFX:TYPE.USER:AAPDBVJR18YW0MNPM11XBNK5BV118RCM7U5JJ9V7BN",
        "gasCoveredBySponsor": true,
        "gasFee": "0x25477",
        "gasUsed": "0x25477",
        "index": "0x0",
        "logs": [
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x0000000000000000000000008531b4bd1662b7ca943a3d27794203c7ace53e7200000000000000000000000000000000000000000000008368a98cc8902bb80000000000000000000000000000000000000000000000008368a98cc8902bb800",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x000000000000000000000000821c636dfc85d0612fb8ebf34acf84771ba4c3440000000000000000000000000000000000000000000006b823988244bf96e0000000000000000000000000000000000000000000000006b823988244bf96e000",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x00000000000000000000000086d2fb177eff4be03a342951269096265b98ac4600000000000000000000000000000000000000000000006a5ded38ba0fc7800000000000000000000000000000000000000000000000006a5ded38ba0fc78000",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x000000000000000000000000817cba144f54134e5fa664142ff11df3c74a1c760000000000000000000000000000000000000000000000000de096de94d2d0000000000000000000000000000000000000000000000000000de096de94d2d000",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x0000000000000000000000008ddae69c9f99522b11e31749c28e5f7cc89a19420000000000000000000000000000000000000000000006b7deb81845bd982acc0000000000000000000000000000000000000000000006b7deb81845bd982acc",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x0000000000000000000000008e2f2e68eb75bb8b18caafe9607242d4748f8d9800000000000000000000000000000000000000000000000005565a5b5edaa2cc00000000000000000000000000000000000000000000000005565a5b5edaa2cc",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x00000000000000000000000087929dda85a959f52cab6083a2fba1b9973f15e00000000000000000000000000000000000000000000000000de2c6356d5c40000000000000000000000000000000000000000000000000000de2c6356d5c4000",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x000000000000000000000000875e9cb14c3c55591e4db9b835d85efe9b13395b00000000000000000000000000000000000000000000000000c795237bde980000000000000000000000000000000000000000000000000000c795237bde9800",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            },
            {
                "address": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
                "data": "0x0000000000000000000000008d7df9316faa0586e175b5e6d03c6bda76e3d95000000000000000000000000000000000000000000000000002db8c846af26b9800000000000000000000000000000000000000000000000002db8c846af26b98",
                "topics": [
                    "0x4d624906ce6fd4e4b8b649463516ff505029a1903a8cc34bd82b4ca0f9a479de"
                ]
            }
        ],
        "logsBloom": "0x00000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000020000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000",
        "outcomeStatus": "0x0",
        "stateRoot": "0x5fdaee2d854fb25e762923c835a2970dd287a5f05b51b190828c83886ac0a94d",
        "storageCollateralized": "0x0",
        "storageCoveredBySponsor": true,
        "storageReleased": [],
        "to": "CFX:TYPE.CONTRACT:ACC7UAWF5UBTNMEZVHU9DHC6SGHEA0403Y2DGPYFJP",
        "transactionHash": "0xd78742724603bf5ea32b8ecb5c2a212bc8a93e906bd9991136bf5f784cbb4d08",
        "txExecErrorMsg": null
    },
    "id": 0
}
Language
Click Try It! to start a request and see the response here!