编辑更新SPU
接口描述
通过该接口更新SPU模块信息,请注意更新时请求body中的所有字段必填做替换资源操作。
URL
/ark/open_api/v1/spu/{spu_id}
URL Parameter
名称 | 类型 | 必填 | 说明 |
---|---|---|---|
spu_id | String | Yes | 已存在的SPU ID |
Method
PUT
Request Body (content-type:application/json;charset=utf8)
请务必按以下字段要求添加数据,以免系统报错。
{
"brand_id":"52d0deb1b4c4d655316b7d4b",
"category_id":"572dd173939e250d08ec59f2",
"name":"testupdatespu",
"ename":"testupdatespu",
"short_name":"testupdatespu"
}
Request Body Parameters
Field Name | Type | Description |
---|---|---|
name | String | SPU中文名称 |
ename | String | SPU英文名称 |
brand_id | String | 品牌ID |
short_name | String | 商品简称(不超过15个字符) |
category_id | String | 分类ID (必须是最末级分类ID) |
Response 200 (application/json;charset=utf-8)
{
"error_code": 0,
"data": {
"spvs": [],
"items": [],
"spls": [],
"spus": [
{
"pending_changes": null,
"ename": "testupdatespu",
"name": "testupdatespu",
"short_name": "testupdatespu",
"brand": {
"ename": "GUCCI",
"id": "52d0deb1b4c4d655316b7d4b",
"name": "古驰"
},
"brand_id": "52d0deb1b4c4d655316b7d4b",
"category_id": "572dd173939e250d08ec59f2",
"id": "58e5b5f5af0a672afacf4564",
"categories": [
{
"ename": "Shoes",
"id": "52ce1c02b4c4d649b58b892f",
"name": "鞋子"
},
{
"ename": "Women's shoes",
"id": "56a6eecd8e7989cd56fcea7f",
"name": "女鞋"
},
{
"ename": "Women's high heels",
"id": "572dd173939e250d08ec59f2",
"name": "女士高跟鞋"
}
]
}
],
"spl_items": []
},
"error_msg": null,
"success": true
}
Response parameters
名称 | 类型 | 说明 |
---|---|---|
pending_changes | Array | 待审核的更改信息 |
spus | Array | SPU模块信息 |
id | String | SPU ID |
categories | Array | 分类列表,从一级分类到末级分类 |
spls | Array | SPL模块信息 |
id | String | SPV ID |
spl_items | Array | SPL ITEM模块信息 |
id | String | SPL ID |
spvs | Array | SPV模块信息 |
items | Array | ITEM模块信息 |
补充说明
- state & status 具体状态码请参考商品状态码
Copyright © 2014-2018 行吟信息科技(上海)有限公司