AccountInvokeBuilder
Defined in: ootle/src/builtin-templates.ts:28
Fluent builder for common account component invocations.
Mirrors AccountInvokeBuilder from the Rust ootle-rs crate.
Example
Section titled “Example”const tx = new AccountInvokeBuilder(network) .feeTransactionPayFromComponent(accountAddress, 1000n) .publicTransfer(accountAddress, resourceAddress, 500n, recipientAddress) .build();Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new AccountInvokeBuilder(
network):AccountInvokeBuilder
Defined in: ootle/src/builtin-templates.ts:31
Parameters
Section titled “Parameters”network
Section titled “network”number
Returns
Section titled “Returns”AccountInvokeBuilder
Methods
Section titled “Methods”build()
Section titled “build()”build():
UnsignedTransactionWithBlobs
Defined in: ootle/src/builtin-templates.ts:92
Returns
Section titled “Returns”feeTransactionPayFromComponent()
Section titled “feeTransactionPayFromComponent()”feeTransactionPayFromComponent(
componentAddress,maxFee):this
Defined in: ootle/src/builtin-templates.ts:47
Adds a fee instruction paying from the account’s default vault.
Parameters
Section titled “Parameters”componentAddress
Section titled “componentAddress”string
maxFee
Section titled “maxFee”bigint
Returns
Section titled “Returns”this
publicTransfer()
Section titled “publicTransfer()”publicTransfer(
sourceAccount,resourceAddress,amount,destinationAddress):this
Defined in: ootle/src/builtin-templates.ts:56
Transfers amount of resource from sourceAccount to destinationAddress.
Mirrors AccountInvokeBuilder::public_transfer from ootle-rs.
Parameters
Section titled “Parameters”sourceAccount
Section titled “sourceAccount”string
resourceAddress
Section titled “resourceAddress”string
amount
Section titled “amount”bigint
destinationAddress
Section titled “destinationAddress”string
Returns
Section titled “Returns”this
publishTemplate()
Section titled “publishTemplate()”publishTemplate(
_sourceAccount,templateBinaryBase64,workspaceBucket?):this
Defined in: ootle/src/builtin-templates.ts:80
Publishes a compiled template WASM blob (standard-base64 encoded).
Mirrors AccountInvokeBuilder::publish_template from ootle-rs.
sourceAccount is the fee payer; declare it via feeTransactionPayFromComponent
and withInputs. Pass workspaceBucket to capture the new template address
for a follow-up instruction.
Parameters
Section titled “Parameters”_sourceAccount
Section titled “_sourceAccount”string
templateBinaryBase64
Section titled “templateBinaryBase64”string
workspaceBucket?
Section titled “workspaceBucket?”string
Returns
Section titled “Returns”this
withInputs()
Section titled “withInputs()”withInputs(
inputs):this
Defined in: ootle/src/builtin-templates.ts:39
Declares the transaction’s substate inputs (e.g. the source account and its vaults) so the indexer resolves their versions before submission.
Parameters
Section titled “Parameters”inputs
Section titled “inputs”SubstateRequirement[]
Returns
Section titled “Returns”this