CEX Integration Guide
  • Introduction
  • Circular's Public Blockchains
  • SDK Library
  • Networks
  • Local Calls
    • Retrieve Wallet
    • Retrieve Wallet Balance for a Specific Asset
    • Resolve Domain Name
    • Retrieve Asset Supply
    • Retrieve Blockchain Block Height
    • Retrieve a Single Block
    • Retrieve a Set of Blocks
    • Retrieve List of Blockchains
    • Retrieve Transaction by ID
    • Retrieve Transaction by Address
    • Retrieve Transaction by Date
  • Transactions
    • Transaction Composition
    • Calculating a Transaction Hash
    • Submitting a Transaction
    • Transaction Finality
  • Wallet Creation
    • Creating a Wallet
    • Wallet Generation (Read Warning)
  • Appendix
  • Node.js
    • Page 1
Powered by GitBook
On this page
  1. Local Calls

Retrieve a Single Block

var Blockchain = '0x714d2ac07a826b66ac56752eebd7c77b58d2ee842e523d913fd0ef06e6bdfcae';
var BlockNumber = 100;

Circular.GetBlock(Blockchain, BlockNumber)
  .then(data => {
    // do something with the data in JSON format
  });

Output

{
  "Result": 200, // Success
  "Response": {
    "Block": {
      "BlockID": 138, // Block Number
      "Blockchain": "714d2ac07a8...", // Blockchain
      "Nonce": 13977, // Block Nonce
      "Node": "3819259...", // Node Minting the block
      "PreviousBlockHash": "0009ba64e38a...", // Previous Block Hash
      "TimeStamp": "2024:05:01-13:45:28", // Block Timestamp
      "Payload": { // Block payload
        "Transactions": [ // Transactions array
          {
            "ID": "b36112b5...", // Tx ID
            "From": "d5b18d8e...", // Tx From Address
            "To": "d5b18d8e...", // Tx To
            "Timestamp": "2024:05:01-16:45:12", // Tx Timestamp
            "Type": "C_TYPE_REGISTERWALLET", // Tx Type
            "Payload": "7b22416374...", // Tx Payload
            "Nonce": "0", // from Wallet Nonce
            "OSignature": "", // From Signature
            "NodeID": "ca7ff7cc...", // Receiving Node
            "GasLimit": 0, // Gas Limit (Smart Contract)
            "NagFee": 0, // NAG Fee
            "BroadcastFee": 0, // Broadcast Fee
            "ProcessingFee": 0, // Processing Fee
            "DeveloperFee": 0, // Developer Fee
            "ProtocolFee": 0, // Protocol Fee
            "Instructions": 0, // Number of Contract Instructions
            "Status": "Executed" // Tx Status
          }
          // Additional transactions can be added here
        ],
        "BlockReward": 0 // Block Reward
      }
    },
    "Hash": "000544546c3...", // Block Hash
    "Signature": "304602210...", // Minting Node Signature
    "SelectedNode": "02fc8b..." // Next Node Selected by Consensus
  }
}

PreviousRetrieve Blockchain Block HeightNextRetrieve a Set of Blocks

Last updated 7 months ago