You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 19 Next »
url
http://test.birdsystem.com/client/Consignment-Product
接口功能
添加产品
支持格式
JSON
开发人员
请求方式
POST
发布日期
参数
必选
类型
说明
product_id
必填
INT(10)
产品id
consignment_id
BINGINT(16)
订单ID
product_type
选填
VARCHAR
产品类型,默认“NORMAL”product_type=[“NORMAL”,“DIRECTIONAL”]product_type[0]=“当前用户产品”product_type[1]="普通共享产品"
quantity
INT
数量
is_directional_shared_product
BOOL
是否定向共享产品
ebay_transaction_id
eBay订单交易号
ebay_item_no
eBay产品ID
sold_quantity
出售数量
count
产品数量
product_customs_name
海关属性名称
product_weight
float(‘%.2f’)
产品重量
total_price_customs_export
float(‘%.3f’)
总出口报关价
product_client_ref
产品SKU
id
订单产品列表ID
产品ID
unit_product_price
产品单价
unit_product_cost
产品成本
unit_product_length
产品长
unit_product_width
产品宽
unit_product_depth
产品高
unit_product_weight
产品重
price_customs_export
出口报关价
price_customs_export_internal
内部出口报关价
price_customs_export_origin
出口报关价来源
price_customs_export_internal_origin
内部出口报关价来源
sn
SN唯一码(sn !=product_id && sn != product_client_ref)
产品类型:[“NORMAL”||“DIRECTIONAL”]
primary_keys
主键:[“id”]
URL:http://test.birdsystem.com/client/Consignment-Product
#api_key和company_id和提交数据中consignment_id &product_id需要替换成实际数据 -Headers 'api_key: {{bs.default_api_key}}' \ #所需登录站点company_id -Headers 'company_id: {{bs.default_company_id}}' \ #所需登录账号的api_key -Headers 'content-type: application/x-www-form-urlencoded' \
(一次请求只能推送一次产品,多件产品需推送多次)
consignment_id:2012140360000997 product_id:2989354 quantity:1
{ "data": { "sold_quantity": null, "count": null, "product_customs_name": null, "product_weight": null, "total_price_customs_export": null, "product_client_ref": null, "id": 71525956, "product_id": 2989354, "consignment_id": 2012140360000997, "quantity": "2", "unit_product_price": "2.00", "unit_product_cost": "0.00", "unit_product_weight": "50.00", "unit_product_length": "50.00", "unit_product_width": "50.00", "unit_product_depth": "50.00", "price_customs_export": "5.000", "price_customs_export_internal": "1.000", "price_customs_export_origin": "0.000", "price_customs_export_internal_origin": "0.000", "sn": null, "product_type": "NORMAL", "primary_keys": [ "id" ] }, "success": true, "moduleName": "client" }
返回异常示例(检查产品ID是否允许添加产品或检查产品是否正常,库存是否充足)
{ "success": false, "message": "Can not find product by id [2989352222]." }