Documentation
    Preparing search index...

    Options for swap operations

    This type configures various aspects of the swap process including DEX selection, routing depth, and fee handling.

    type SwapOptions = {
        baseUrl?: string;
        byAmountIn?: boolean;
        depth?: number;
        dexList?: Dex[];
        feeOption?: FeeOption;
        ifPrint?: boolean;
        serviceFee?: FeeOption;
    }
    Index

    Properties

    baseUrl?: string

    Custom base URL for the aggregator API

    byAmountIn?: boolean

    Whether the amount is input amount (true) or output amount (false)

    depth?: number

    Maximum routing depth for finding optimal paths

    dexList?: Dex[]

    List of DEXes to use for routing

    feeOption?: FeeOption

    Fee configuration for the swap

    ifPrint?: boolean

    Whether to print debug information

    serviceFee?: FeeOption

    Service fee configuration