轻易云
注册体验

领星ERP添加/编辑本地产品接口

所属平台
领星ERP
类型
WebAPI
作用
EXECUTE
接口版本
1.0
适配器
\Adapter\LingXing\LXExecuteAdapter
授权方式
OTHER
描述
产品 · POST · 请求参数 145 个(必填 21) · 响应参数 9 个 · 限流令牌桶容量 10
更新日期
2026-11-21

添加/编辑本地产品

POST/erp/sc/routing/storage/product/set
加工厂
{
  "operation": {
    "method": "POST",
    "path": "/erp/sc/routing/storage/product/set"
  },
  "protocol": "HTTPS",
  "host": "https://openapi.lingxing.com",
  "rateLimit": {
    "tokenBucketCapacity": 10,
    "text": ""
  },
  "requestExample": {
    "sku": "SKU2986DFA",
    "product_name": "钢化玻璃膜2",
    "picture_list": [
      {
        "pic_url": "https://xxxx.com/123.jpg",
        "is_primary": 1
      }
    ],
    "unit": "个",
    "category_id": 2,
    "category": "分类5",
    "model": "",
    "brand_id": 0,
    "brand": "",
    "status": 0,
    "description": "",
    "group_list": [
      {
        "sku": "CWZS20A-L",
        "quantity": 1
      }
    ],
    "cg_opt_uid": 0,
    "cg_opt_username": "",
    "product_developer_uid": 0,
    "product_developer": "",
    "purchase_remark": "",
    "cg_price": "",
    "is_related": 0,
    "cg_delivery": 0,
    "cg_product_material": "",
    "cg_product_length": "",
    "cg_product_width": "",
    "cg_product_height": "",
    "cg_product_net_weight": "",
    "cg_product_gross_weight": "",
    "cg_package_length": "",
    "cg_package_width": "",
    "cg_package_height": "",
    "cg_box_length": "",
    "cg_box_width": "",
    "cg_box_height": "",
    "cg_box_weight": "",
    "cg_box_pcs": 0,
    "bg_customs_export_name": "",
    "bg_export_hs_code": "",
    "bg_customs_import_name": "",
    "currency": "CNY",
    "bg_customs_import_price": "",
    "product_creator_uid": 0,
    "product_duty_uids": [],
    "is_append_product_duty": 0,
    "qc_standard": {
      "custom_qc_template": {
        "qc_image": [
          {
            "file_id": "",
            "customer_url": ""
          }
        ]
      }
    },
    "product_logistics_list": {
      "US_cg_transport_costs": 0,
      "US_currency": "",
      "US_clearance_price": 0,
      "US_clearance_price_currency": "",
      "US_bg_import_hs_code": "",
      "US_bg_tax_rate": 0,
      "US_clearance_remark": ""
    },
    "supplier_quote": [
      {
        "erp_supplier_id": 1,
        "supplier_id": 0,
        "supplier_product_url": [],
        "quote_remark": "",
        "is_primary": 1,
        "quotes": [
          {
            "currency": "CNY",
            "is_tax": 0,
            "tax_rate": 0,
            "step_prices": [
              {
                "moq": 0,
                "price_with_tax": 10
              }
            ]
          }
        ]
      }
    ],
    "special_attr": [
      1,
      2,
      3
    ],
    "declaration": {
      "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": 0,
      "customs_clearance_brand_type": 0,
      "customs_clearance_product_pattern": "",
      "allocation_remark": "",
      "weaving_mode": 0,
      "customs_clearance_pic_url": ""
    },
    "aux_relation_list": [
      {
        "aux_sku": "AUX-GLUE-01",
        "sku_qty": 1,
        "aux_qty": 2
      }
    ],
    "spec_pack_list": [
      {
        "spec_title": "小箱包装",
        "cg_box_pcs": 50,
        "cg_box_length": "25.0",
        "cg_box_width": "15.0",
        "cg_box_height": "10.0",
        "cg_package_length": "12.0",
        "cg_package_width": "6.0",
        "cg_package_height": "1.0",
        "cg_box_weight": "6.0",
        "cg_product_gross_weight": "25.0"
      }
    ],
    "api_spu": "SPU001",
    "api_spu_attribute": [
      {
        "pa_id": 1,
        "pai_id": 101
      }
    ],
    "custom_fields": [
      {
        "id": "207663076879646721",
        "val": "测试ceshi",
        "character": ""
      }
    ]
  },
  "responseExample": {
    "code": 0,
    "message": "success",
    "error_details": [],
    "request_id": "CCF38623-DE1A-004F-0961-90A6AF265013",
    "response_time": "2021-11-11 11:14:33",
    "data": {
      "product_id": 1010,
      "sku": "SKU2986DFA1",
      "sku_identifier": "SKU2986DFA1"
    },
    "total": 0
  }
}

接口请求参数

序号字段名称类型默认值必填描述
1skuskustring—必填SKU
2product_name品名【添加时必填】string—必填品名【添加时必填】
3sku_identifierSKU识别码string—可选SKU识别码
4picture_list产品图片信息array<object>—可选产品图片信息
4.1pic_url产品图片链接string—可选产品图片链接
4.2is_primary是否产品主图integer—可选是否产品主图:0 否,1 是
5unit_process_fee单位加工费integer—可选单位加工费
6unit单位(商品单位string—可选单位(商品单位:套、个、台)
7category_id分类idinteger—可选分类id,与分类同时存在时,优先取分类id
8category分类string—可选分类
9model型号string—可选型号
10brand_id品牌idinteger—可选品牌id,与品牌同时存在时,优先取品牌id
11brand品牌string—可选品牌
12open_status开启状态integer—可选开启状态:0 停用,1 启用
13status状态【默认1】integer—可选状态【默认1】:0 停售,1 在售,2 开发中,3 清仓
14description商品描述string—可选商品描述
15group_list组合商品列表array<object>—可选组合商品列表
15.1sku子商品string—可选子商品
15.2quantity商品比例数integer—可选商品比例数
16cg_opt_uid采购integer—可选采购:采购员id,与采购员名同时填写时,以采购员id为准
17cg_opt_username采购string—可选采购:采购员名
18product_developer_uid开发者idinteger—可选开发者id,与开发者名称同时填写时,以开发者id为准
19product_developer开发者名称string—可选开发者名称
20product_creator_uid创建人idinteger—可选创建人id,默认API账号id
21product_duty_uids负责人idarray<any>—可选负责人id
22is_append_product_duty负责人是否追加创建人integer—可选负责人是否追加创建人:0 否,1 是;默认1,只有编辑SKU时才生效
23purchase_remark采购备注string—可选采购备注
24cg_price采购string—可选采购:采购成本(RMB)
25is_related是否关联单品成本integer—可选是否关联单品成本:0 否,1 是
26cg_delivery采购integer—可选采购:采购交期
27cg_product_material采购string—可选采购:商品材质
28cg_product_length采购string—可选采购:单品规格-长(CM)
29cg_product_width采购string—可选采购:单品规格-宽(CM)
30cg_product_height采购string—可选采购:单品规格-高(CM)
31cg_product_net_weight采购string—可选采购:单品净重(G)
32cg_product_gross_weight采购string—可选采购:单品毛重(G)
33cg_package_length采购string—可选采购:包装规格-长(CM)
34cg_package_width采购string—可选采购:包装规格-宽(CM)
35cg_package_height采购string—可选采购:包装规格-高(CM)
36cg_box_length采购string—可选采购:外箱规格-长(CM)
37cg_box_width采购string—可选采购:外箱规格-宽(CM)
38cg_box_height采购string—可选采购:外箱规格-高(CM)
39cg_box_weight采购string—可选采购:单箱重量(KG)
40cg_box_pcs采购integer—可选采购:单箱数量(包装数量)
41bg_customs_export_name报关string—可选报关:申报品名(中文)
42bg_export_hs_code报关string—可选报关:HS Code(中国)
43bg_customs_import_name报关string—可选报关:申报品名(英文)
44currency报关string—可选报关:申报金额的币种
45bg_customs_import_price报关string—可选报关:申报金额
46qc_standard质检标准object—可选质检标准
46.1custom_qc_template自定义质检标准object—可选自定义质检标准
46.1.1qc_image质检图片【最多十张图】array<object>—可选质检图片【最多十张图】
46.1.1.1file_id质检图片文件idstring—可选质检图片文件id
46.1.1.2customer_url客户的质检图片URLstring—可选客户的质检图片URL
47new_qc_standard新质检标准object—可选新质检标准;可选,可与旧qc_standard同时传入
47.1qc_method质检方式integer—必填质检方式:1抽检,2全检,3免检;编辑不传则保留,新增不传默认1
47.2pqt_id系统质检模板IDstring—可选系统质检模板ID;只关联已有模板
47.3custom_qc_template自定义质检标准object—必填自定义质检标准
47.3.1template_item自定义质检项完整列表array<object>—必填自定义质检项完整列表,最多30项;编辑时未回传的原质检项会删除
47.3.1.1pqti_id自定义质检项IDstring—可选自定义质检项ID;编辑已有项时传入,新增项传空字符串或不传
47.3.1.2qc_item质检项名称string—必填质检项名称,最多100个字符
47.3.1.3sort排序integer—可选排序,取值0至255
47.3.1.4qc_content质检内容object—必填质检内容,非空字符串数组,可包含HTML
48product_logistics_list报关清关费用信息object—可选报关清关费用信息 支持国家: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
48.1US_cg_transport_costs默认头程费用(含税)string—可选默认头程费用(含税)
48.2US_currency默认头程费用币种string—可选默认头程费用币种
48.3US_clearance_price清关价格string—可选清关价格
48.4US_clearance_price_currency清关价格币种string—可选清关价格币种,默认CNY
48.5US_bg_import_hs_codeHS Codestring—可选HS Code
48.6US_bg_tax_rate税率string—可选税率
48.7US_clearance_remark备注string—可选备注
49supplier_quotesupplier_quotearray<object>—可选供应商报价信息(该参数传空值则清空产品供应商报价)
49.1erp_supplier_id领星ERP供应商idinteger—必填领星ERP供应商id,查询本地产品详情接口对应字段【supplier_id】,与supplier_id必填其一
49.2supplier_id客户系统供应商idinteger—可选客户系统供应商id,没有填这个值或者对应供应商不存在,则取erp_supplier_id,与erp_supplier_id必填其一
49.3supplier_product_url采购链接array<any>—可选采购链接,字符串数组,最多20个,没有则传空数组
49.4quote_remark报价备注string—可选报价备注
49.5quote_cg_delivery供应商交期integer—可选供应商交期
49.6is_primary首选供应商integer—必填首选供应商:0 否,1 是
49.7quotes报价信息array<object>—必填报价信息,传供应商报价时必传
49.7.1currency报价币种string—必填报价币种,目前只有CNY和USD
49.7.2is_tax是否含税integer—必填是否含税:0 否,1 是
49.7.3tax_rate税率string—必填税率,为空则表示为0
49.7.4step_prices阶梯价信息array<object>—必填阶梯价信息
49.7.4.1moq最小起订量integer—必填最小起订量,最小值为1
49.7.4.2price_with_tax含税单价string—必填含税单价,4位小数
50special_attr产品特殊属性array<any>—可选产品特殊属性:1 含电,2 纯电,3 液体,4 粉末,5 膏体,6 带磁,7 纺织品,8普货(普货于其他选项互斥)
51declaration报关数据object—可选报关数据
51.1customs_import_price报关integer—可选报关:报关单价
51.2customs_import_price_currency报关string—可选报关:报关单价币种
51.3customs_export_name报关string—可选报关:中文报关名
51.4customs_import_name报关string—可选报关:英文报关名
51.5customs_declaration_unit报关string—可选报关:报关单位
51.6customs_declaration_spec报关string—可选报关:规格型号
51.7customs_declaration_origin_produce报关string—可选报关:原厂国(地区)
51.8customs_declaration_inlands_source报关string—可选报关:境内货源地
51.9customs_declaration_hs_code报关string—可选报关:报关HSCODE
51.10other_declare_element报关string—可选报关:其他申报要素
51.11customs_declaration_exempt报关string—可选报关:征免
51.12production_and_sales_enterprise_name报关string—可选报关:生产销售企业名称
51.13production_and_sales_enterprise_code报关string—可选报关:生产销售企业代码
51.14customs_declaration_first_unit报关string—可选报关:第一法定单位
51.15customs_declaration_first_unit_rate报关number—可选报关:第一法定单位转换率
51.16customs_declaration_second_unit报关string—可选报关:第二法定单位
51.17customs_declaration_second_unit_rate报关number—可选报关:第二法定单位转换率
51.18customs_declaration_extra_quarantine_code报关string—可选报关:附加检疫码
52clearance清关数据object—可选清关数据
52.1customs_clearance_material清关string—可选清关:中文材质
52.2customs_clearance_en_material清关string—可选清关:英文材质
52.3customs_clearance_usage清关string—可选清关:中文用途
52.4customs_clearance_en_usage清关string—可选清关:英文用途
52.5customs_clearance_internal_code清关string—可选清关:内部编码
52.6customs_clearance_preferential清关integer—可选清关:出口享惠情况:1 不享惠,2 享惠,3 不确定享惠情况
52.7customs_clearance_brand_type清关integer—可选清关:品牌类型:1 无品牌,2 境内自主品牌,3 境内收购品牌,4 境外品牌(贴牌生产),5 境外品牌(其他)
52.8customs_clearance_product_pattern清关string—可选清关:产品型号
52.9allocation_remark清关string—可选清关:配货备注
52.10weaving_mode织造方式integer—可选织造方式:1 针织,2 梭织
52.11customs_clearance_pic_url清关string—可选清关:清关图片
52.12customs_clearance_price默认清关单价number—可选默认清关单价
52.13customs_clearance_price_currency默认清关单价币种string—可选默认清关单价币种
52.14customs_clearance_hs_code默认清关HSCODEstring—可选默认清关HSCODE
52.15customs_clearance_tax_rate默认清关税率string—可选默认清关税率
52.16customs_clearance_remark默认清关备注string—可选默认清关备注
53aux_relation_list辅料列表array<object>—可选辅料列表
53.1aux_sku辅料skustring—必填辅料sku
53.2sku_qty辅料比例(主料)integer—可选辅料比例(主料)
53.3aux_qty辅料比例(辅料)integer—可选辅料比例(辅料)
54spec_pack_list采购array<object>—可选采购:更多箱规(非默认箱规)
54.1spec_title采购string—必填采购:更多箱规-箱规名称
54.2cg_box_pcs采购integer—可选采购:更多箱规-单箱数量
54.3cg_box_length采购string—可选采购:更多箱规-外箱规格-长(CM)
54.4cg_box_width采购string—可选采购:更多箱规-外箱规格-宽(CM)
54.5cg_box_height采购string—可选采购:更多箱规-外箱规格-高(CM)
54.6cg_package_length采购string—可选采购:更多箱规-包装规格-长(CM)
54.7cg_package_width采购string—可选采购:更多箱规-包装规格-宽(CM)
54.8cg_package_height采购string—可选采购:更多箱规-包装规格-高(CM)
54.9cg_box_weight采购string—可选采购:更多箱规-单箱重量(KG)
54.10cg_product_gross_weight采购string—可选采购:更多箱规-单品毛重(G)
55api_spuSPU(填写时属性列表必填string—可选SPU(填写时属性列表必填,同时填写且为空时取消关联)
56api_spu_attribute属性列表(填写时spu必填array<object>—可选属性列表(填写时spu必填,同时填写且为空时取消关联)
56.1pa_id属性IDinteger—必填属性ID
56.2pai_id属性值IDinteger—必填属性值ID
57custom_fieldscustom_fieldsstring—可选[array]
57.1ididstring—可选[string]
57.2valvalstring—必填[string]
57.3charactercharacterstring—可选[string]

接口响应参数

序号字段名称类型默认值必填描述
1code状态码integer0必填状态码,0 成功
2message消息提示stringsuccess必填消息提示
3error_details错误信息array<any>—必填错误信息
4request_id请求链路idstring&nbsp;必填请求链路id
5response_time响应时间string2020-04-30 17:33:32必填响应时间
6data响应数据object—必填响应数据
6.1product_id本地产品idinteger1010必填本地产品id
6.2sku本地产品skustringSKU2986DFA1必填本地产品sku
6.3sku_identifierSKU识别码stringSKU2986DFA1必填SKU识别码

领星ERP的接口:添加/编辑本地产品(/erp/sc/routing/storage/product/set),由轻易云数据集成平台 API 资产管理模块整理收纳,并随领星ERP版本更新同步更新。

需要对接这个接口?

轻易云已预置该接口的适配能力,联系我们即可开始配置数据集成。