Better Payment 0.11.1 API
    Preparing search index...

    Interface BuildBasketOptions

    interface BuildBasketOptions {
        discount?: string | number | { percent: number };
        items: BasketBuilderItem[];
        quantity?: "expand" | "multiply";
        shipping?: BasketShipping;
    }
    Index
    discount?: string | number | { percent: number }

    Discount on the items (not on shipping): a fixed amount such as '13.48', or { percent: 10 }. It is spread over the items in proportion to their totals.

    quantity?: "expand" | "multiply"

    How quantity is sent: 'expand' (default) adds one item per unit, with ids A-1, A-2, ...; 'multiply' adds one item priced at unit price × quantity.

    shipping?: BasketShipping

    Shipping fee, added as the last item. A zero fee adds no item.