BlockchainTransaction (for Tezos)

BlockchainTransaction[assoc]

represents a Tezos blockchain operation built from the components in the association assoc.

Details

  • Gives a symbolic representation of a Tezos blockchain operation; it does not submit the operation, and the operation is not signed.
  • BlockchainTransaction[][prop] gives the value of the property prop for the operation.
  • The following Tezos operation types are supported. The type is specified using the "Type" element of the association assoc:
  • "Transaction"operation to transfer tez between two accounts, or to run the code of a smart contract
    "Delegation"operation in which an account balance is lent to a delegate
    "Origination"operation to create a smart contract
    "Reveal"operation to reveal an account's public key
  • For operations of type "Transaction", the following elements must be given:
  • "BlockchainBase"blockchain base to use
    "Sender"address of the sender
    "Target"address of the receiver
    "Amount"amount of mutez to be transferred
  • The following additional elements can also be given for type "Transaction":
  • "Type"type of operation
    "Branch"hash of the branch (block)
    "TransactionCount"current sender's transaction count plus one
    "BakerFee"fee to be included in mutez
    "GasLimit"maximum amount of gas for execution
    "StorageLimit"maximum amount of storage to be used
    "Parameters"parameters to be sent to the contract
  • For operations of type "Delegation", the following elements must be given:
  • "BlockchainBase"blockchain base to use
    "Type"type of operation
    "Sender"address of the sender
    "Delegate"address of the delegate (None for delegation withdraw)
  • The following additional elements can also be given for type "Delegation":
  • "Branch"hash of the branch (block)
    "TransactionCount"current sender's transaction count plus one
    "BakerFee"fee to be included in mutez
    "GasLimit"maximum amount of gas for execution
    "StorageLimit"maximum amount of storage to be used
  • For operations of type "Origination", the following elements must be given:
  • "BlockchainBase"blockchain base to use
    "Type"type of operation
    "Sender"address of the sender
    "Balance"initial balance of the contract
    "Contract"contract details
  • The following additional elements can also be given for type "Origination":
  • "Branch"hash of the branch (block)
    "TransactionCount"current sender's transaction count plus one
    "BakerFee"fee to be included in mutez
    "GasLimit"maximum amount of gas for execution
    "StorageLimit"maximum amount of storage to be used
    "Delegate"address of the delegate the contract is staking for
  • For operations of type "Reveal", the following elements must be given:
  • "BlockchainBase"blockchain base to use
    "Type"type of operation
    "Sender"address of the sender
    "SenderPublicKey"public key of the sender to be revealed
  • The following additional elements can also be given for type "Reveal":
  • "Branch"hash of the branch (block)
    "TransactionCount"current sender's transaction count plus one
    "BakerFee"fee to be included in mutez
    "GasLimit"maximum amount of gas for execution
    "StorageLimit"maximum amount of storage to be used
  • The value of "Parameters" is an association with the following keys:
  • "EntryPoint"name of the contract's function to be called
    "Value"function arguments as a rule-based representation of a Micheline JSON expression
  • The value of "Contract" is an association with the following keys:
  • "Storage"initial storage value as a rule-based representation of a Micheline JSON expression
    "Code"contract code
  • The value of "Code" can be a rule-based representation of a Micheline JSON expression, a file containing a Micheline JSON script or a file containing a LIGO script.
  • BlockchainTransaction can represent Tezos mainnet (default), testnet and voting process testing period chain fork operations. To specify these networks, use the "BlockchainBase" value inside the required association or the BlockchainBase option.

Examples

open allclose all

Basic Examples  (1)

Create a Tezos transaction object representing a "Transaction" operation:

Scope  (30)

Transaction Operations  (7)

Create a "Transaction" operation to send funds to a target account. The elements that are not specified use automatic values:

Create a "Transaction" operation and specify a branch:

Create a "Transaction" operation and specify a transaction count:

Create a "Transaction" operation and specify a baker fee:

Create a "Transaction" operation and specify a gas limit:

Create a "Transaction" operation and specify a storage limit:

Create a "Transaction" operation to interact with a contract:

Delegation Operations  (8)

Create a "Delegation" operation to register as a delegate. Both the "Sender" and "Delegate" values are the same. The elements that are not specified use automatic values:

Create a "Delegation" operation to stake for a delegate. The elements that are not specified use automatic values:

Create a "Delegation" operation to cancel your stake by withdrawing a delegation. This requires the "Delegate" value to be None. The elements that are not specified use automatic values:

Create a "Delegation" operation and specify a branch:

Create a "Delegation" operation and specify a transaction count:

Create a "Delegation" operation and specify a baker fee:

Create a "Delegation" operation and specify a gas limit:

Create a "Delegation" operation and specify a storage limit:

Origination Operations  (9)

Create an "Origination" operation to create a contract by providing the code as a rule-based representation of a Micheline JSON expression. The elements that are not specified use automatic values:

Create an "Origination" operation to create a contract by providing a Micheline file. The elements that are not specified use automatic values:

Create an "Origination" operation to create a contract by providing a LIGO file. The elements that are not specified use automatic values:

Create an "Origination" operation and specify a branch:

Create an "Origination" operation and specify a transaction count:

Create an "Origination" operation and specify a baker fee:

Create an "Origination" operation and specify a gas limit:

Create an "Origination" operation and specify a storage limit:

Create an "Origination" operation to stake the contract's balance to the specified delegate:

Reveal Operations  (6)

Create a "Reveal" operation to reveal the sender's public key. The elements that are not specified use automatic values:

Create a "Reveal" operation and specify a branch:

Create a "Reveal" operation and specify a transaction count:

Create a "Reveal" operation and specify a baker fee:

Create a "Reveal" operation and specify a gas limit:

Create a "Reveal" operation and specify a storage limit:

Options  (2)

BlockchainBase  (2)

Mainnet  (1)

Create a mainnet transaction:

Testnet  (1)

Create a testnet transaction:

Applications  (1)

Create a Tezos BlockchainTransaction:

Sign the transaction object using a private key object:

Send the signed operation to the Tezos blockchain:

Wolfram Research (2020), BlockchainTransaction, Wolfram Language function, https://reference.wolfram.com/language/ref/blockchain/BlockchainTransaction-Tezos.html.

Text

Wolfram Research (2020), BlockchainTransaction, Wolfram Language function, https://reference.wolfram.com/language/ref/blockchain/BlockchainTransaction-Tezos.html.

BibTeX

@misc{reference.wolfram_2021_blockchaintransaction, author="Wolfram Research", title="{BlockchainTransaction}", year="2020", howpublished="\url{https://reference.wolfram.com/language/ref/blockchain/BlockchainTransaction-Tezos.html}", note=[Accessed: 28-July-2021 ]}

BibLaTeX

@online{reference.wolfram_2021_blockchaintransaction, organization={Wolfram Research}, title={BlockchainTransaction}, year={2020}, url={https://reference.wolfram.com/language/ref/blockchain/BlockchainTransaction-Tezos.html}, note=[Accessed: 28-July-2021 ]}

CMS

Wolfram Language. 2020. "BlockchainTransaction." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/blockchain/BlockchainTransaction-Tezos.html.

APA

Wolfram Language. (2020). BlockchainTransaction. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/blockchain/BlockchainTransaction-Tezos.html