How to add multiple products to Basket

Hi,

According to the documentation the code below will add one product to the basket.

Is it possible to add multiple products to the basket by calling basketAddProduct only once?If so could you please let me know how the mutation would look like?

mutation {
     basketAddProduct(
         basketId: "310e50a2b1be309b255d70462cd75507",
         productId:"05848170643ab0deb9914566391c0c63",
         amount: 1
     ) {
         items {
             amount
             product {
                 id
                 title
             }
         }
     }
 }

Thanks in advance

David

Hi David :slight_smile:

No, this mutation is missing.

You have to create your own module with your own mutation.

You can find more information under Modules and use cases — OXID eSales GraphQL Documentation and the sekelton module GitHub - OXID-eSales/graphql-module-skeleton: Skeleton for creating a GraphQL module for the OXID eShop to start programming.

Best,
Tim