QuoteApi - object-oriented interface

Export

QuoteApi

Hierarchy

  • BaseAPI
    • QuoteApi

Constructors

Properties

axios: AxiosInstance = globalAxios
basePath: string = BASE_PATH
configuration: undefined | Configuration

Methods

  • Provide a quote estimate for the provided saver withdraw.

    Parameters

    • Optional height: number

      optional block height, defaults to current tip

    • Optional asset: string

      the asset to withdraw

    • Optional address: string

      the address for the position

    • Optional withdrawBps: number

      the basis points of the existing position to withdraw

    • Optional options: AxiosRequestConfig<any>

      Override http request option.

    Returns Promise<AxiosResponse<QuoteSaverWithdrawResponse, any>>

    Throws

    Memberof

    QuoteApi

  • Provide a quote estimate for the provided swap.

    Parameters

    • Optional height: number

      optional block height, defaults to current tip

    • Optional fromAsset: string

      the source asset

    • Optional toAsset: string

      the target asset

    • Optional amount: number

      the source asset amount in 1e8 decimals

    • Optional destination: string

      the destination address, required to generate memo

    • Optional toleranceBps: number

      the maximum basis points from the current feeless swap price to set the limit in the generated memo

    • Optional affiliateBps: number

      the affiliate fee in basis points

    • Optional affiliate: string

      the affiliate (address or mayaname)

    • Optional options: AxiosRequestConfig<any>

      Override http request option.

    Returns Promise<AxiosResponse<QuoteSwapResponse, any>>

    Throws

    Memberof

    QuoteApi

Generated using TypeDoc