These are the data models you will encounter throughout Ark Core and their representations as returned in the core-api.
Keep in mind that the data structures are kept consistent as much as possible for the sake of backward and forwards compatibility. As such, these data hierarchies are not necessarily the same as the object's internal representation.
This is something to keep in mind when accessing these models through the Event API, for example, as the correct way to obtain information might be different from following the structure listed here.
Where possible, these discrepancies are noted below. The transformers directories in the core-api module help to paint a complete picture; they can be found in their respective v1 and v2 repositories.
Blocks are the core unit of any given blockchain. In ARK, blocks contain a group of transactions and are signed by a delegate to validate their authenticity.
id
version the version of ARK active on the network when the block was forged
heightthe height of the block
previousthe ID of the previous block in the chain
forged:
rewardtotal reward for mining block
fee total fee paid by users for this block
totaltotal reward + total fee
payload fields holding metadata on the block's transactions:
hashThe SHA256 hash of the block's content
lengththe length of the payload hash in bytes
generatorthe delegate who generated the block:
username
address
publicKey
signaturethe signature of the delegate who forged the block
confirmationsthe amount of times the network has declared this block as valid
transactionsthe amount of transactions in the block
Transactions are the heart of any blockchain, cryptocurrency or otherwise. They represent a transfer of value from one network participant to another. In ARK, transactions can be of one of multiple types, specified in AIP11, which can affect the content and data structure of each transaction's payload.
id
blockIdthe ID of the block in which this transaction is included
typethe AIP11 type of the transaction
amountthe transaction value in arktoshis
feethe fee paid to include the transaction in its block
senderthe address of the transaction sender
recipientthe address of the transaction recipient
signaturethe signature of the sending party
signSignatureif secondSignature is enabled, the second signature is stored here
signaturesan array of the transaction's signatures, used in multisignature transactions to validate more than two signatures
vendorFieldan optional text field written by the sender and associated with the transaction
assetthe type-specific transaction payload
confirmationsthe amount of times this transaction's block has been confirmed
Wallets are individual accounts on the ARK ledger. Each wallet has a balance that grows and shrinks as the wallet sends and receives transactions on the network. Additionally, each wallet can cast exactly one vote for one delegate to forge on their behalf.
Note in particular that private keys and passphrases are not included on this model, as they are never stored in memory at any point during the operation of Ark Core nodes.
addressthe wallet's address, derived from public key
publicKeythe wallet's public key, derived from private key
secondPublicKeyif the wallet has enabled a second key, that second key is stored here
votethe delegate username of this wallet's vote recipient
Though delegates are treated as their own data type in the ARK Public API, in their implementation delegates are nothing more than wallets whose owners have registered a delegate username.
They share all fields in common with the Wallet data structure, with a few extra fields:
usernamethe delegate username of this wallet
voteBalancethe sum of balances of all wallets voting for the delegate
producedBlocksthe total number of blocks produced by the delegate
missedBlocksthe total number of blocks missed by the delegate
Peers are nodes in the Ark network that work together to relay transactions and form consent. Each node keeps a list of current peers, regularly pruning and updating the list as new peers join and leave the network.
ipthe IP address of the peer
portthe port on which the peer has enabled its P2P connection
versionthe network version this peer is operating on
heightthe total height of the blockchain as reported by the peer
statusthe operational status of the peer
osthe operating system running on the peer
latencythe average delay between contacting the peer and receiving a response