Edit Product Category
# Description
Edit product category
# Request Specification
Request Method: POST + application/json
Request Path: https://${cloud domain}/cgi/crm/data/editProductCategory?thirdTraceId=${random string}
Request Headers: Refer to Common Parameters
# Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| data | Map | Yes | API parameter map |
| editFlag | int | Yes | Operation type; 1: create, 2: update, 3: delete |
| id | String | Required for edit and delete | Unique ID of the product category |
| name | String | Required for create | Single-select label of the product category, corresponding to the single-select label in the CRM description |
| pid | String | No | Parent category node ID of the product category |
| orderField | int | Required for create | Order number of the product unit at this level |
| category_code | String | Required for create | Product category |
# Request Example
{
"data": {
"editFlag": 1.0,
"id": "123",
"name": "Vegetable 1",
"pid": "2c188941cded4c74b348338a4415f265",
"category_code": "123",
"orderField": 3.0
}
}
# Response Parameters
| Parameter | Type | Description |
|---|---|---|
| traceId | string | Unique request ID |
| errorDescription | string | Error description |
| errorMessage | string | Error message |
| errorCode | Int | View error codes |
# Response Example
{
"traceId": "E-O.827xxxxxx",
"errorDescription": "success",
"errorMessage": "OK",
"errorCode": 0
}
# Notes
- Do not use the message field in the response for logical judgment as errorMessage may change;