Zopping

Sync your catalog

This guide walks a channel or ERP integration through publishing an assortment to Zopping and keeping price and stock current. It mirrors how Zopping's own channel connectors work.

The model

  • A product is the master record (name, brand, category, barcodes).
  • Each product has one or more variants. A simple product has a single variant; a product sold in multiple sizes/packs has several.
  • Price and stock are per store, attached to a variant as an item. You read them on the variant's storeSpecificData, and you write them through the Inventory API — not the Catalog API.

Keep your own identifiers on the records (clientItemId / clientId) so you can map between your system and Zopping without storing Zopping ids.

1. Create the classification first

Products reference a brand and a category, so create those up front (idempotently — look up by name/clientId before creating).

curl -X POST https://zopping.com/api/catalogue-service/brand \
  -H "Authorization: Bearer $ZOPPING_TOKEN" -H "Content-Type: application/json" \
  -d '{"organizationId":"<org-id>","name":"Tata","status":"ENABLED"}'

curl -X POST https://zopping.com/api/catalogue-service/category \
  -H "Authorization: Bearer $ZOPPING_TOKEN" -H "Content-Type: application/json" \
  -d '{"organizationId":"<org-id>","name":"Staples","status":"ENABLED"}'

2. Create products with variants

Send the product with its variants in one call. Store your SKU in clientItemId.

curl -X POST https://zopping.com/api/catalogue-service/product \
  -H "Authorization: Bearer $ZOPPING_TOKEN" -H "Content-Type: application/json" \
  -d '{
    "organizationId": "<org-id>",
    "name": "Tata Salt",
    "brandId": 55,
    "primaryCategoryId": 1201,
    "clientItemId": "SKU-TATA-SALT",
    "hasVariants": 1,
    "variants": [
      { "name": "1kg", "clientItemId": "SKU-TATA-SALT-1KG", "barcodes": ["8901030865278"] },
      { "name": "2kg", "clientItemId": "SKU-TATA-SALT-2KG", "barcodes": ["8901030865285"] }
    ]
  }'

3. Set price and stock per store

Price and availability are store-scoped. Upsert them through the Inventory API for each productId + storeId:

curl -X POST https://zopping.com/api/inventory-service/item \
  -H "Authorization: Bearer $ZOPPING_TOKEN" -H "Content-Type: application/json" \
  -d '{ "organizationId": "<org-id>", "storeId": "<store-id>", "productId": 88120,
        "mrp": 28.0, "discount": 2.0, "stock": 240, "status": "ENABLED" }'

4. Keep it in sync

  • Read back with store context. GET /api/catalogue-service/product?organizationId=<org-id>&storeId=<store-id> returns each variant's live storeSpecificData so you can reconcile.
  • Update, don't recreate. Look up by clientId / clientItemId, then PUT the product or push a fresh inventory item. Re-POSTing the same SKU creates a duplicate.
  • Hide instead of delete for temporary outages — set status: "HIDDEN".

Where to go next

  • Catalog reference — every field and endpoint.
  • Inventory, Orders and Pricing references are being curated to the same standard.