BlockchainBlockData (for Cardano)

BlockchainBlockData["blockid"]

gives information about the block with the specified block ID on the Cardano blockchain.

BlockchainBlockData[n]

gives information about block n on the Cardano blockchain.

BlockchainBlockData[-n]

gives information about the block n elements from the end of the Cardano blockchain.

BlockchainBlockData[bspec,prop]

gives the specified property of the block.

Details

  • BlockchainBlockData[-1] gives information on the latest Cardano block.
  • Properties include:
  • "BlockHash"hash of this block
    "BlockNumber"number (height) of this block in the Cardano blockchain
    "Confirmations"number of confirmations
    "PreviousBlockHash"hash of the previous block
    "Timestamp"time when this block was produced
    "TotalFee"sum of all the fees in this block's transactions
    "ByteCount"size of block in bytes
    "VerificationKey"block producer verification key
    "OperationalCertificate"block producer operational certificate
    "ProtocolVersionEndorsement"version of the protocol that this particular block producer is prepared to move to
    "EpochNumber"epoch number for this block
    "SlotNumber"slot number for this block
    "SlotInEpoch"slot number for this block relative to the beginning of the epoch
    "SlotLeader"block producer information
    "TotalTransactions"total number of operations in this block
    "TransactionList"list of operation hashes in this block
  • "SlotLeader" gives an association with the following properties as its keys:
  • "Hash"hash of the pool that produced this block
    "Description"description of the pool that produced this block
  • Possible options include:
  • BlockchainBase Automaticsets the blockchain and its network
    MaxItems Allthe maximum number of items to return
  • BlockchainBlockData can access the Cardano mainnet (default) and testnet "preprod", which is a new network for testing purposes. To specify these networks, use the BlockchainBase option.
  • The setting for MaxItems specifies the maximum number of transactions to include in the result.

Examples

open allclose all

Basic Examples  (6)

Get information about a block from the Cardano blockchain using its height:

Use a block hash to get information about a Cardano block:

Get the latest block of the Cardano testnet blockchain:

Get multiple Cardano blocks by providing a list of heights or hashes:

Get a property from a Cardano block:

Get multiple properties from a Cardano block:

Scope  (15)

BlockHash  (1)

Get the hash of a Cardano block:

BlockNumber  (1)

Get the height of a Cardano block:

ByteCount  (1)

Get the byte count of a Cardano block:

Confirmations  (1)

Get the number of confirmations of a Cardano block:

EpochNumber  (1)

Get the epoch number of a Cardano block:

OperationalCertificate  (1)

Get the operation certificate of a Cardano block:

ProtocolVersionEndorsement  (1)

Get the protocol version endorsement of a Cardano block:

SlotInEpoch  (1)

Get the slot in epoch of a Cardano block:

SlotLeader  (1)

Get the slot leader of a Cardano block:

SlotNumber  (1)

Get the slot number of a Cardano block:

Timestamp  (1)

Get the time when a Cardano block was minted:

TotalFee  (1)

Get the total fee included in a Cardano block:

TotalTransactions  (1)

Get the total number of transactions included in a Cardano block:

TransactionList  (1)

Get the list of transactions included in a Cardano block:

VerificationKey  (1)

Get the verification key of a Cardano block:

Options  (3)

BlockchainBase  (2)

Mainnet  (1)

Get information from a random Cardano mainnet block:

Testnet  (1)

Get information from a random Cardano testnet block:

MaxItems  (1)

Get the first 5 transactions from a Cardano block:

Applications  (1)

Get the fees included in a Cardano block:

Convert the result to fiat currency:

Possible Issues  (2)

Nonexistent Hashes  (1)

Using a block ID from one blockchain in another blockchain will return a Missing output:

Incorrect Hashes  (1)

Providing an invalid block ID will return a $Failed output:

Neat Examples  (1)

Generate sounds from a Cardano block:

Wolfram Research (2021), BlockchainBlockData, Wolfram Language function, https://reference.wolfram.com/language/ref/blockchain/BlockchainBlockData-Cardano.html.

Text

Wolfram Research (2021), BlockchainBlockData, Wolfram Language function, https://reference.wolfram.com/language/ref/blockchain/BlockchainBlockData-Cardano.html.

CMS

Wolfram Language. 2021. "BlockchainBlockData." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/blockchain/BlockchainBlockData-Cardano.html.

APA

Wolfram Language. (2021). BlockchainBlockData. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/blockchain/BlockchainBlockData-Cardano.html

BibTeX

@misc{reference.wolfram_2024_blockchainblockdata, author="Wolfram Research", title="{BlockchainBlockData}", year="2021", howpublished="\url{https://reference.wolfram.com/language/ref/blockchain/BlockchainBlockData-Cardano.html}", note=[Accessed: 21-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_blockchainblockdata, organization={Wolfram Research}, title={BlockchainBlockData}, year={2021}, url={https://reference.wolfram.com/language/ref/blockchain/BlockchainBlockData-Cardano.html}, note=[Accessed: 21-November-2024 ]}