Function makeAssetTransferTxn

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

    Deprecated

    in version 2.0 this will change to use the "WithSuggestedParams" signature.

    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"

    • fee: number

      integer fee per byte, in microAlgos. for a flat fee, overwrite the fee property on the returned object If the final calculated fee is lower than the protocol minimum fee, the fee will be increased to match the minimum.

    • amount: number | bigint

      integer amount of assets to send

    • firstRound: number

      integer first protocol round on which this txn is valid

    • lastRound: number

      integer last protocol round on which this txn is valid

    • note: Uint8Array

      uint8array of arbitrary data for sender to store

    • genesisHash: string

      string specifies hash genesis block of network in use

    • genesisID: string

      string specifies genesis ID of network in use

    • assetIndex: number

      int asset index uniquely specifying the asset

    • Optional rekeyTo: string

      rekeyTo address, optional

    Returns Transaction

Generated using TypeDoc