Function makeAssetTransferTxnWithSuggestedParams

  • makeAssetTransferTxnWithSuggestedParams allows for the creation of an asset transfer transaction. Special case: to begin accepting assets, set amount=0 and from=to.

    Parameters

    • from: string

      string representation of Algorand address of sender

    • to: string

      string representation of Algorand address of asset recipient

    • closeRemainderTo: string

      optional - string representation of Algorand address - if provided, send all remaining assets after transfer to the "closeRemainderTo" address and close "from"'s asset holdings

    • revocationTarget: string

      optional - string representation of Algorand address - if provided, and if "from" is the asset's revocation manager, then deduct from "revocationTarget" rather than "from"

    • amount: number | bigint

      integer amount of assets to send

    • note: Uint8Array

      uint8array of arbitrary data for sender to store

    • assetIndex: number

      int asset index uniquely specifying the asset

    • suggestedParams: SuggestedParams

      a dict holding common-to-all-txns args: fee - integer fee per byte, in microAlgos. for a flat fee, set flatFee to true flatFee - bool optionally set this to true to specify fee as microalgos-per-txn If true, txn fee may fall below the ALGORAND_MIN_TX_FEE

      • flatFee - bool optionally set this to true to specify fee as microalgos-per-txn If true, txn fee may fall below the ALGORAND_MIN_TX_FEE firstRound - integer first protocol round on which this txn is valid lastRound - integer last protocol round on which this txn is valid genesisHash - string specifies hash genesis block of network in use genesisID - string specifies genesis ID of network in use
    • Optional rekeyTo: string

      rekeyTo address, optional

    Returns Transaction

Generated using TypeDoc