/erp/sc/routing/storage/spu/set{
"operation": {
"method": "POST",
"path": "/erp/sc/routing/storage/spu/set"
},
"protocol": "HTTPS",
"host": "https://openapi.lingxing.com",
"rateLimit": {
"tokenBucketCapacity": 5,
"text": ""
},
"requestExample": {
"spu": "AAAAAABBB",
"spu_name": "AAAAAAAAA",
"model": "",
"unit": "",
"status": 0,
"cid": "",
"bid": "",
"create_uid": 0,
"developer_uid": "",
"product_duty_uids": [],
"description": "",
"use_spu_template": 0,
"sku_list": [
{
"sku": "CWZS20A-S",
"product_name": "儿童沙滩罩衫",
"picture_list": [
{
"pic_url": "http://hhjskbnd.png",
"is_primary": 1
}
],
"attribute": [
{
"pa_id": "",
"pai_id": ""
}
]
}
],
"purchase_info": {
"cg_uid": 1,
"purchase_remark": "",
"cg_delivery": 0,
"cg_product_length": 0,
"cg_product_width": 0,
"cg_product_height": 0,
"cg_product_net_weight": 0,
"cg_product_gross_weight": 0,
"cg_package_length": 0,
"cg_package_width": 0,
"cg_package_height": 0,
"cg_box_length": 0,
"cg_box_width": 0,
"cg_box_height": 0,
"cg_box_weight": 0,
"cg_box_pcs": "",
"cg_product_material": ""
},
"logistics": {
"declaration": {
"customs_export_name": "",
"customs_import_name": "",
"customs_import_price_currency": "",
"customs_import_price": 0,
"customs_declaration_unit": "",
"customs_declaration_spec": "",
"customs_declaration_origin_produce": "",
"customs_declaration_inlands_source": "",
"customs_declaration_exempt": ""
},
"clearance": {
"customs_clearance_material": "",
"customs_clearance_usage": "",
"customs_clearance_internal_code": "",
"customs_clearance_preferential": "",
"customs_clearance_brand_type": "",
"customs_clearance_product_pattern": "",
"allocation_remark": "",
"customs_clearance_pic_url": ""
},
"base": {
"bg_export_hs_code": "",
"special_attr": []
},
"fee": {
"US_cg_transport_costs": 0,
"US_currency": "",
"US_clearance_price": 0,
"US_clearance_price_currency": "",
"US_bg_import_hs_code": 0,
"US_bg_tax_rate": 0
}
},
"attribute_skc_list": [
{
"pa_id": "",
"skc": ""
}
]
},
"responseExample": {
"code": 0,
"message": "success",
"error_details": [],
"request_id": "6D1422D5-B767-675D-42F6-F604319C2333",
"response_time": "2023-03-09 14:45:40",
"total": 0,
"data": {
"ps_id": 113,
"sku_list": [
{
"product_id": 48528,
"sku": "CWZS20A-S"
},
{
"product_id": 48529,
"sku": "CWZS20A-M"
},
{
"product_id": 48530,
"sku": "CWZS20A-L"
}
]
}
}
}| No. | Field | Name | Type | Default | Required | Description |
|---|---|---|---|---|---|---|
| 1 | spu | SPU(添加时必填) | string | — | Required | SPU(添加时必填) |
| 2 | spu_name | 款名(添加时必填) | string | — | Required | 款名(添加时必填) |
| 3 | model | 型号 | string | — | Optional | 型号 |
| 4 | unit | 单位 | string | — | Optional | 单位 |
| 5 | status | 状态【默认1】 | integer | — | Optional | 状态【默认1】:0 停售,1 在售,2 开发中,3 清仓 |
| 6 | cid | 分类id | integer | — | Optional | 分类id |
| 7 | bid | 品牌id | integer | — | Optional | 品牌id |
| 8 | create_uid | 创建人id | integer | — | Optional | 创建人id |
| 9 | developer_uid | 开发人id | integer | — | Optional | 开发人id |
| 10 | product_duty_uids | 产品负责人id | array<any> | — | Optional | 产品负责人id |
| 11 | description | 产品描述 | string | — | Optional | 产品描述 |
| 12 | use_spu_template | 是否应用SPU信息至新生成的SKU | integer | — | Optional | 是否应用SPU信息至新生成的SKU:0 否,1 是 |
| 13 | sku_list | 产品列表【提交的sku不存在时系统会自动创建】 | array<object> | — | Required | 产品列表【提交的sku不存在时系统会自动创建】 |
| 13.1 | sku | 本地产品SKU | string | — | Required | 本地产品SKU |
| 13.2 | product_name | 产品名称【提交的sku不存在时为必填项】 | string | — | Optional | 产品名称【提交的sku不存在时为必填项】 |
| 13.3 | attribute | 属性列表 | array<object> | — | Required | 属性列表 |
| 13.3.1 | pa_id | 属性id | integer | — | Required | 属性id |
| 13.3.2 | pai_id | 属性值id | integer | — | Required | 属性值id |
| 13.4 | picture_list | 产品图片信息 | array<object> | — | Optional | 产品图片信息 |
| 13.4.1 | is_primary | 是否产品主图 | integer | — | Required | 是否产品主图:0否,1是 |
| 14 | purchase_info | 采购相关信息 | object | — | Optional | 采购相关信息 |
| 14.1 | cg_uid | 采购 | integer | — | Optional | 采购:采购员id |
| 14.2 | purchase_remark | 采购 | string | — | Optional | 采购:采购备注 |
| 14.3 | cg_delivery | 采购 | integer | — | Optional | 采购:采购交期(天) |
| 14.4 | cg_product_length | 采购 | number | — | Optional | 采购:单品规格-长(CM) |
| 14.5 | cg_product_width | 采购 | number | — | Optional | 采购:单品规格-宽(CM) |
| 14.6 | cg_product_height | 采购 | number | — | Optional | 采购:单品规格-高(CM) |
| 14.7 | cg_product_net_weight | 采购 | number | — | Optional | 采购:单品净重(G) |
| 14.8 | cg_product_gross_weight | 采购 | number | — | Optional | 采购:单品毛重(G) |
| 14.9 | cg_package_length | 采购 | number | — | Optional | 采购:包装规格-长(CM) |
| 14.10 | cg_package_width | 采购 | number | — | Optional | 采购:包装规格-宽(CM) |
| 14.11 | cg_package_height | 采购 | number | — | Optional | 采购:包装规格-高(CM) |
| 14.12 | cg_box_length | 采购 | number | — | Optional | 采购:外箱规格-长(CM) |
| 14.13 | cg_box_width | 采购 | number | — | Optional | 采购:外箱规格-宽(CM) |
| 14.14 | cg_box_height | 采购 | number | — | Optional | 采购:外箱规格-高(CM) |
| 14.15 | cg_box_weight | 采购 | number | — | Optional | 采购:单箱重量(KG) |
| 14.16 | cg_box_pcs | 采购 | string | — | Optional | 采购:单箱数量(包装数量) |
| 14.17 | cg_product_material | 采购 | string | — | Optional | 采购:产品材质 |
| 15 | logistics | 物流报关相关信息 | object | — | Optional | 物流报关相关信息 |
| 15.1 | declaration | 报关数据 | object | — | Optional | 报关数据 |
| 15.1.1 | customs_export_name | 报关 | string | — | Optional | 报关:申报品名(中文) |
| 15.1.2 | customs_import_name | 报关 | string | — | Optional | 报关:申报品名(英文) |
| 15.1.3 | customs_import_price_currency | 报关 | string | — | Optional | 报关:申报单价的币种 |
| 15.1.4 | customs_import_price | 报关 | number | — | Optional | 报关:申报单价 |
| 15.1.5 | customs_declaration_unit | 报关单位 | string | — | Optional | 报关单位 |
| 15.1.6 | customs_declaration_spec | 规格型号 | string | — | Optional | 规格型号 |
| 15.1.7 | customs_declaration_origin_produce | 报关 | string | — | Optional | 报关:原厂国(地区) |
| 15.1.8 | customs_declaration_inlands_source | 报关 | string | — | Optional | 报关:境内货源地 |
| 15.1.9 | customs_declaration_exempt | 报关 | string | — | Optional | 报关:征免 |
| 15.2 | clearance | 清关数据 | object | — | Optional | 清关数据 |
| 15.2.1 | customs_clearance_material | 清关 | string | — | Optional | 清关:材质 |
| 15.2.2 | customs_clearance_usage | 清关 | string | — | Optional | 清关:用途 |
| 15.2.3 | customs_clearance_internal_code | 清关 | string | — | Optional | 清关:内部编码 |
| 15.2.4 | customs_clearance_preferential | 清关 | string | — | Optional | 清关:出口享惠情况: 1 不享惠 2 享惠 3 不确定享惠情况 |
| 15.2.5 | customs_clearance_brand_type | 清关 | string | — | Optional | 清关:品牌类型: 1 无品牌 2 境内自主品牌 3 境内收购品牌 4 境外品牌(贴牌生产) 5 境外品牌(其他) |
| 15.2.6 | customs_clearance_product_pattern | 清关 | string | — | Optional | 清关:产品型号 |
| 15.2.7 | allocation_remark | 清关 | string | — | Optional | 清关:配货备注 |
| 15.2.8 | customs_clearance_pic_url | 清关 | string | — | Optional | 清关:清关图片 |
| 15.3 | base | 物流基础信息 | object | — | Optional | 物流基础信息 |
| 15.3.1 | bg_export_hs_code | 报关 | string | — | Optional | 报关:HS Code(中国) |
| 15.3.2 | special_attr | 产品特殊属性 | array<any> | — | Optional | 产品特殊属性:1 含电 2 纯电 3 液体 4 粉末 5 膏体 6 带磁 |
| 15.4 | fee | 头程费用 | object | — | Optional | 头程费用,支持国家:US、CA、MX、JP、UK、DE、FR、ES、IT、NL、AU、SG、IN、AE、SA、BR、SE、PL、BE、TR、UA、HU、PK、LB、AT、CH、CZ、DK、IE、LU、NO、PT、SK、RU、KZ、BY、CL、KR |
| 15.4.1 | 国家简码_cg_transport_costs | 默认头程费用(含税) | number | — | Optional | 默认头程费用(含税) |
| 15.4.2 | 国家简码_currency | 默认头程费用币种 | string | — | Optional | 默认头程费用币种 |
| 15.4.3 | 国家简码_clearance_price | 清关价格 | number | — | Optional | 清关价格 |
| 15.4.4 | 国家简码_clearance_price_currency | 清关价格币种 | string | — | Optional | 清关价格币种 |
| 15.4.5 | 国家简码_bg_import_hs_code | HS Code | string | — | Optional | HS Code |
| 15.4.6 | 国家简码_bg_tax_rate | 税率 | number | — | Optional | 税率 |
| 16 | aux_relation_list | 辅料列表 | array<object> | — | Optional | 辅料列表 |
| 16.1 | aux_sku | 辅料sku | string | — | Required | 辅料sku |
| 16.2 | sku_qty | 辅料比例(主料) | string | — | Required | 辅料比例(主料) |
| 16.3 | aux_qty | 辅料比例(辅料) | string | — | Required | 辅料比例(辅料) |
| 17 | attribute_skc_list | skc列表 | array<object> | — | Optional | skc列表 |
| 17.1 | pa_id | 属性id | integer | — | Required | 属性id |
| 17.2 | skc | skc | string | — | Required | skc,新增时根据skc业务配置规则自动生成 |
| 18 | sku_lis | sku_lis | object | — | Optional | |
| 18.1 | picture_list | picture_list | object | — | Optional | |
| 18.1.1 | pic_url | 产品图片链接 | string | — | Required | 产品图片链接 |
| No. | Field | Name | Type | Default | Required | Description |
|---|---|---|---|---|---|---|
| 1 | code | 状态码 | integer | 0 | Required | 状态码,0 成功 |
| 2 | message | 提示消息 | string | success | Required | 提示消息 |
| 3 | error_details | 错误信息 | array<any> | — | Required | 错误信息 |
| 4 | request_id | 请求链路id | string | 6D1422D5-B767-675D-42F6-F604319C2333 | Required | 请求链路id |
| 5 | response_time | 响应时间 | string | 2023-03-09 14:45:40 | Required | 响应时间 |
| 6 | total | 总数 | integer | 0 | Required | 总数 |
| 7 | data | 响应数据 | array<object> | — | Required | 响应数据 |
| 7.1 | ps_id | spu唯一id | integer | 113 | Required | spu唯一id |
| 7.2 | sku_list | spu下对应的sku数据 | array<object> | — | Required | spu下对应的sku数据 |
| 7.2.1 | product_id | 本地产品id | integer | 48528 | Required | 本地产品id |
| 7.2.2 | sku | 本地产品sku | string | CWZS20A-S | Required | 本地产品sku |
The 添加/编辑多属性产品 API (/erp/sc/routing/storage/spu/set) of 领星ERP is curated by the API asset management module of the Qeasy Cloud data integration platform and kept in sync with 领星ERP version updates.
Qeasy ships with prebuilt adaptation for this API — contact us to start configuring data integration.