KashierDevelopersKashier Developers

Replace the categories on products

curl -X PUT "https://test-api.kashier.io/v2/products/categories/change" \  -H "Content-Type: application/json" \  -d '{    "categoryIds": [      "507f1f77bcf86cd799439011"    ],    "productIds": [      "507f1f77bcf86cd799439012"    ]  }'
{  "body": {    "updatedCount": 0,    "message": "string"  },  "message": "string"}

Replaces the full category set on the given products with categoryIds, rather than adding to it. Use this when your ERP is the source of truth and you want Kashier to match it exactly.

Authorization

secretKey
Authorization<token>

Your secret key from the Kashier dashboard. Send the raw key value in the Authorization header, without a Bearer prefix.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

PUT
/v2/products/categories/change