id of the contract to call
entry point of the contract to call
arguments of the contract to call
Uint8Array | null
Check authority for an account
type of authority required
account to check
bool true if the account has authority
Emit an event
name of the event
data associated to the event
accounts impacted by the event
Exit a contract
Fail the transaction in progress
Optional failure message
Optional error code, must be < 0, else code -1 is used (failure exit code)
if (!System.checkAuthority(authority.authorization_type.transaction_application, Base58.decode('1DQzuCcTKacbs9GGScRTU1Hc8BsyARTPqe)))
System.fail("contract is not authorized");
Get arguments that were used when calling the contract
Uint8Array
Get the current block
protocol.block
Get a field from the current block
field to get (i.e.: 'id', 'header.signer')
value.value_type | null
Get bytes (Uint8Array)
space where to get the object
key of object to get
Uint8Array | null
Get the contract caller information
chain.caller_data
Get the address for a given system contract name
The name of the system contract
Uint8Array The contract's address
Get the id of the contract
Uint8Array
Get the name of a system contract for a given address
The address of the system contract
string The contract's name
Gets a stored error message after a system call that can return an error.
string
Get the blockchain head information (head block time, height, last irreversible block, etc...)
chain.head_info
Get the last irreversible block height
u64
Get next bytes (Uint8Array)
key of object
system_calls.database_object
Get next proto object
key of object
proto object (TMessage)
Get proto object
space where to get the object
key of object to get
proto object (TMessage) or null
Get the current operation
protocol.operation
Get next bytes (Uint8Array)
key of object
system_calls.database_object
Get previous proto object
key of object
proto object (TMessage)
Get the current transaction
protocol.transaction
Get a field from the current transaction
field to get (i.e.: 'id', 'header.payer')
value.value_type | null
Hash an object
a Crypto.multicodec code
object to hash
size of the object to hash
Uint8Array | null
Log a string
string to log
Store bytes (Uint8Array)
space where to put the byets
key of the bytes to store (string or Uint8Array)
bytes to store (Uint8Array)
number of bytes that were put in the database
Store proto object
space where to put the object
key of the object to store (string or Uint8Array)
object to store (string or Uint8Array)
number of bytes that were put in the database
Recover a publick key given a signature and a digest that was signed by the public key
the signature of the digest
digest that was signed by the public key
type of signature
whether the public key should be compressed
Uint8Array | null
Remove an object
space where to put the byets
key of the bytes to store (string or Uint8Array)
Require an expression to be true, log a message and exit the contract otherise
T it is Trueish, will exit the contract with exitCode
otherwise
Require authority for an account
type of authority required
account to check
Revert the transaction in progress
Optional reversion message
Optional error code, must be > 0, else code 1 is used (reverted exit code)
if (!System.checkAuthority(authority.authorization_type.transaction_application, Base58.decode('1DQzuCcTKacbs9GGScRTU1Hc8BsyARTPqe)))
System.revert("contract is not authorized");
Verify a merkle root
merkle root to verify
hashes to verify
bool
Verify that a public key signed a digest
public key that signed the digest
signature of the digest
digest that was signed
type of signature
whether or not the public key is compressed
bool
Verifies a VRF proof
public key that generated the proof
the VRF proof itself
the hash of the proof
the original message input
type of signature
Generated using TypeDoc
Call a contract