Skip to content
Esc
↑↓navigate↵open⌘Jpreview

Upsert products bundle-products

Bulk-adds products to bundles, or updates their quantity. A bundle is a product with product_type bundle and can’t contain another bundle.

PUT/api/v2/{team_slug}/{app_slug}/products/bundle-products
Authorization
AuthorizationBearer token · headerrequired

Management API token, sent as Authorization: Bearer <token>.

Path parameters
team_slugstringrequired
app_slugstringrequired
Request body
requiredapplication/json
bundle_productsBundleProduct[]required
min items 1 · max items 20
Show properties
Array of BundleProduct
bundle_idUUIDrequired
product_idUUIDrequired
quantityintegerrequired
min 1
Responses
200

OK (partial success possible)

dataBundleProduct[]required
Show properties
Array of BundleProduct
bundle_idUUIDrequired
product_idUUIDrequired
quantityintegerrequired
min 1
errorsBundleProductLinkError[]required
Show properties
Array of BundleProductLinkError
bundle_idUUID
product_idUUID
messagestringrequired
400

Request-level failure

errorErrorBodyrequired
Show properties
messagestringrequired
detailsstring[]required
401

Request-level failure

errorErrorBodyrequired
Show properties
messagestringrequired
detailsstring[]required
403

Request-level failure

errorErrorBodyrequired
Show properties
messagestringrequired
detailsstring[]required
500

Request-level failure

errorErrorBodyrequired
Show properties
messagestringrequired
detailsstring[]required
Try it
Server
Authorization
Parameters
Bodyapplication/json
Request
curl -X PUT 'https://api.enad.io/api/v2/string/string/products/bundle-products' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "bundle_products": [
    {
      "bundle_id": "fc6f5a67-caa1-4339-9c14-a67826143b60",
      "product_id": "0d012afa-f885-4e65-aeca-37e27701e2d1",
      "quantity": 1
    }
  ]
}'
Response
{
  "data": [
    {
      "bundle_id": "fc6f5a67-caa1-4339-9c14-a67826143b60",
      "product_id": "0d012afa-f885-4e65-aeca-37e27701e2d1",
      "quantity": 1
    }
  ],
  "errors": [
    {
      "bundle_id": "fc6f5a67-caa1-4339-9c14-a67826143b60",
      "product_id": "0d012afa-f885-4e65-aeca-37e27701e2d1",
      "message": "string"
    }
  ]
}