bitbadgesjs-sdk - v0.27.2
    Preparing search index...

    Interface iEstimateSwapPayload

    interface iEstimateSwapPayload {
        chainIdsToAddresses: Record<string, string>;
        chainIdsToAffiliates?: Record<
            string,
            { affiliates: { address: string; basis_points_fee: string }[] },
        >;
        forcefulRecheckCompliance?: boolean;
        slippageTolerancePercent: string | number;
        tokenIn: string;
        tokenInChainId?: string;
        tokenOutChainId?: string;
        tokenOutDenom: string;
    }
    Index

    Properties

    chainIdsToAddresses: Record<string, string>

    Mapping of chain IDs to addresses. Must include "bitbadges-1" with a valid BitBadges address. Other chain addresses will be generated automatically from the bitbadges-1 address.

    chainIdsToAffiliates?: Record<
        string,
        { affiliates: { address: string; basis_points_fee: string }[] },
    >

    Optional mapping of chain IDs to affiliate fee recipients. Structure: { [chainId]: { affiliates: Array<{ address: string; basis_points_fee: string }> } }

    forcefulRecheckCompliance?: boolean

    Forcefully recheck compliance and avoid cache (5 minutes)

    slippageTolerancePercent: string | number

    Slippage tolerance as a percentage (0-100). Can be a string or number.

    tokenIn: string

    The token in to swap. Format: "amount:X,denom:Y"

    tokenInChainId?: string

    Optional chain ID for the token in. Defaults to "bitbadges-1" if not provided.

    tokenOutChainId?: string

    Optional chain ID for the token out. Defaults to "bitbadges-1" if not provided.

    tokenOutDenom: string

    The token out denom to swap to.