Documentation
    Preparing search index...
    • Builds a repay transaction for a lending pool debt

      Constructs and adds repayment operations to an existing transaction object. This function handles loan repayments, supporting both standard user repayments and privileged operations via account capabilities.

      Parameters

      • tx: Transaction

        The transaction builder to append repayment operations to

      • identifier: AssetIdentifier

        Unique identifier for the lending pool asset (e.g., "USDC", "SUI")

      • coinObject: CoinObject

        The coin object to use for repayment, or GasCoin for SUI payments

      • Optionaloptions: Partial<EnvOption & AccountCapOption & { amount: number | TransactionResult }>

        Configuration options for the repayment

        • amount - Specific amount to repay (required for SUI gas coin, otherwise uses value of specified coinObject)
        • accountCap - Optional account capability object for privileged repayments
        • env - Environment configuration
        • cacheTime - Cache duration for configuration data

      Returns Promise<Transaction>

      Promise - The modified transaction object with repayment operations added

      When amount is not provided for SUI gas coin repayments

      Will throw if pool doesn't exist or repayment validation fails