Import
Signature
extra.feePayer is present in the requirement:
Creates a two-transaction atomic group:
- Transaction [0]: Fee payer self-payment of 0 ALGO with pooled flat fee equal to
2 * minFee(2,000 microALGO). - Transaction [1]: Payer transfer of
amountwith flat fee of 0. SetspaymentIndex = 1andsignIndexes = [1].
extra.feePayer is absent:
Creates a single transaction where the payer pays the standard fee:
Sets paymentIndex = 0 and signIndexes = [0].
Handles both native ALGO (asset ID “0”) and Algorand Standard Assets (ASAs).
Parameters
Spend controls checked before anything is built. Without
maxAmount, amounts above {@link DEFAULT_MAX_AMOUNT} (1,000,000 base units) are refused.Returns
Object containing the transaction group, payment transaction index, and indexes requiring signature.
Throws
SpendLimitExceededError: If the amount is above the cap.PaymentNotAllowedError: If the asset, network or recipient is not allowed.NetworkMismatchError: Ifextra.genesisHashorextra.genesisIddisagrees withsuggestedParams.InvalidPaymentRequiredError: If the amount, asset, payTo or feePayer is malformed.