Type Alias SingleAddToCartHandler

SingleAddToCartHandler: {
    single: ((articleNumber: string, quantity: number, configurationId?: string) => Promise<boolean>);
}

Handler for adding a single item to the cart. It assumes that TECSAFE layout articles as well as saleschannel native articles can be handed over, e.g. when item-lists have been selected by customer for upselling.

Type declaration

  • single: ((articleNumber: string, quantity: number, configurationId?: string) => Promise<boolean>)

    Adds a single item to the cart.

      • (articleNumber, quantity, configurationId?): Promise<boolean>
      • Parameters

        • articleNumber: string

          The article number of the product to add.

        • quantity: number

          The quantity of the product to add.

        • OptionalconfigurationId: string

          The configuration ID of the product to add, if not provided this is an up-selling and not a custom made product.

        Returns Promise<boolean>

        A promise that resolves to true if the item was successfully added, false otherwise.