@eco-incorp/sauce/svm is the Solana side: the client (createSauceSvmClient), clusters, PDAs, account resolution against the compiler’s account manifest, Kitchen and engine instructions, transactions and sending, token accounts, and compute planning for @sauce/router’s Solana venues. @eco-incorp/sauce/svm/engine exports the engine’s wire format and instruction builders, @eco-incorp/sauce/svm/verify verifies settle programs and engine CPI data, and @eco-incorp/sauce/svm/engine-artifacts (Node only) returns file paths to the packaged engine and Kitchen binaries.
@eco-incorp/sauce.
parseMintExtensions
Function · @eco-incorp/sauce/svm
Parse the Token-2022 TLV extension region of a mint. Returns
{ blocking: [], advisories: [] } for a legacy 82-byte mint (or any non-T22
shape). For a Token-2022 mint, recognizes TransferFeeConfig and TransferHook
(returned as structured fields), the un-routable set (NonTransferable,
DefaultAccountState frozen, Pausable paused), each pushed as a reason string
into blocking, and the routable trust flags (PermanentDelegate,
ConfidentialTransferMint, Pausable not paused, ScaledUiAmount, MemoTransfer),
each pushed into advisories.
associatedTokenAccountLength
Function · @eco-incorp/sauce/svm
The size of the associated token account the Associated Token Account program creates for a
mint, which its rent is for: SPL Token’s 165 bytes; under Token-2022, the account type byte and
every extension the mint requires of an account, with the ImmutableOwner the ATA program adds.
getEpochFee
Function · @eco-incorp/sauce/svm
calcTransferFee
Function · @eco-incorp/sauce/svm
The transfer fee withheld from amount under cfg at epoch, EXACTLY as
spl-token-2022 computes it: 0 when bps or amount is 0, else
min(maximum_fee, ceil(amount * bps / 10_000)).
netTransferAmount
Function · @eco-incorp/sauce/svm
The amount the recipient actually receives: amount - calcTransferFee(...).
grossTransferAmount
Function · @eco-incorp/sauce/svm
The amount to send under cfg at epoch for the recipient to receive exactly received, as
spl-token-2022’s calculate_pre_fee_amount computes it (the formula is in this file’s header):
netTransferAmount(grossTransferAmount(r, cfg, e), cfg, e) === r.
ONE_IN_BASIS_POINTS
Variable · @eco-incorp/sauce/svm
Basis-points denominator (spl-token-2022 ONE_IN_BASIS_POINTS).
EXT_UNINITIALIZED
Variable · @eco-incorp/sauce/svm
EXT_TRANSFER_FEE_CONFIG
Variable · @eco-incorp/sauce/svm
EXT_CONFIDENTIAL_TRANSFER_MINT
Variable · @eco-incorp/sauce/svm
EXT_DEFAULT_ACCOUNT_STATE
Variable · @eco-incorp/sauce/svm
EXT_MEMO_TRANSFER
Variable · @eco-incorp/sauce/svm
EXT_NON_TRANSFERABLE
Variable · @eco-incorp/sauce/svm
EXT_PERMANENT_DELEGATE
Variable · @eco-incorp/sauce/svm
EXT_TRANSFER_HOOK
Variable · @eco-incorp/sauce/svm
EXT_SCALED_UI_AMOUNT
Variable · @eco-incorp/sauce/svm
EXT_PAUSABLE
Variable · @eco-incorp/sauce/svm
TransferFee
Interface · @eco-incorp/sauce/svm
One transfer-fee schedule, valid from epoch onward until superseded.
TransferFeeConfig
Interface · @eco-incorp/sauce/svm
A mint’s TransferFeeConfig: the older and newer fee schedules. A caller picks
the one effective at the current epoch (see getEpochFee) - the config
carries both so a quote computed near an epoch boundary stays exact.
TransferHookInfo
Interface · @eco-incorp/sauce/svm
A mint’s TransferHook extension (non-nil program only).
MintExtensions
Interface · @eco-incorp/sauce/svm
Parsed mint extensions relevant to routing.
