import { C } from "https://deno.land/x/lucid@0.10.10/src/core/core.ts";
const { TransactionBuilder } = C;
Methods
Add certificate via a Certificates object
This automatically selects and adds inputs from {inputs} consisting of just enough to cover the outputs that have already been added. This should be called after adding all certs/outputs/etc and will be an error otherwise. Adding a change output must be called after via TransactionBuilder::balance() inputs to cover the minimum fees. This does not, however, set the txbuilder's fee.
change_address is required here in order to determine the min ada requirement precisely
Add a single JSON metadatum using a TransactionMetadatumLabel and a String It will be securely added to existing or new metadata in this builder
Add a single JSON metadatum using a TransactionMetadatumLabel, a String, and a MetadataJsonSchema object It will be securely added to existing or new metadata in this builder
Add a single metadatum using TransactionMetadatumLabel and TransactionMetadatum objects It will be securely added to existing or new metadata in this builder
Add a mint entry to this builder using a PolicyID and MintAssets object It will be securely added to existing or new Mint in this builder It will securely add assets to an existing PolicyID But it will replace/overwrite any existing mint assets with the same PolicyID first redeemer applied to a PolicyID is taken for all further assets added to the same PolicyID
Add native scripts via a NativeScripts object
Add explicit output via a TransactionOutput object
Add plutus data via a PlutusData object
Add plutus scripts via a PlutusScripts object
Add plutus v2 scripts via a PlutusScripts object
Warning: this function will mutate the /fee/ field Make sure to call this function last after setting all other tx-body properties Editing inputs, outputs, mint, etc. after change been calculated might cause a mismatch in calculated fee versus the required fee
Returns full Transaction object with the body and the auxiliary data NOTE: witness_set will contain all mint_scripts if any been added or set NOTE: is_valid set to true
Returns full Transaction object with the body and the auxiliary data
NOTE: witness_set will contain all mint_scripts if any been added or set
takes fetched ex units into consideration
add collateral utxos and collateral change receiver in case you redeem from plutus script utxos
async call
NOTE: is_valid set to true
calculates how much the fee would increase if you added a given output
calculates how much the fee would increase if you added a given output
does not include refunds or withdrawals
does not include fee
withdrawals and refunds
Return explicit input plus implicit input plus mint
Return explicit output plus implicit output plus burn (does not consider fee directly)
warning: sum of all parts of a transaction must equal 0. You cannot just set the fee to the min value and forget about it warning: min_fee may be slightly larger than the actual minimum fee (ex: a few lovelaces) this is done to simplify the library code, but can be fixed later
Returns a copy of the current mint state in the builder
Returns a copy of the current witness native scripts in the builder
Set explicit auxiliary data via an AuxiliaryData object It might contain some metadata plus native or Plutus scripts
Set metadata using a GeneralTransactionMetadata object It will be set to the existing or new auxiliary data in this builder
Returns the TransactionBody.