收藏 分销(赏)

微信小店手册模板.doc

上传人:天**** 文档编号:2951590 上传时间:2024-06-11 格式:DOC 页数:87 大小:946.54KB 下载积分:16 金币
下载 相关 举报
微信小店手册模板.doc_第1页
第1页 / 共87页
微信小店手册模板.doc_第2页
第2页 / 共87页


点击查看更多>>
资源描述
微信小店API手册V1.17 目录 1. 商品管理接口 - 1 - 1.1 增加商品 - 1 - 1.2 删除商品 - 6 - 1.3 修改商品 - 7 - 1.4 查询商品 - 10 - 1.5 获取指定状态全部商品 - 13 - 1.6 商品上下架 - 14 - 1.7 获取指定分类全部子分类 - 15 - 1.8 获取指定子分类全部SKU - 16 - 1.9 获取指定分类全部属性 - 18 - 2. 库存管理接口 - 21 - 2.1 增加库存 - 21 - 2.2 降低库存 - 22 - 3. 邮费模板管理接口 - 24 - 3.1 增加邮费模板 - 24 - 3.2 删除邮费模板 - 35 - 3.3 修改邮费模板 - 36 - 3.4 获取指定ID邮费模板 - 37 - 3.5 获取全部邮费模板 - 39 - 4. 分组管理接口 - 41 - 4.1 增加分组 - 41 - 4.2 删除分组 - 42 - 4.3 修改分组属性 - 43 - 4.4 修改分组商品 - 44 - 4.5 获取全部分组 - 45 - 4.6 依据分组ID获取分组信息 - 46 - 5. 货架管理接口 - 48 - 5.1 增加货架 - 48 - 5.2 删除货架 - 56 - 5.3 修改货架 - 57 - 5.4 获取全部货架 - 58 - 5.5 依据货架ID获取货架信息 - 60 - 5.6 开发者将自己页面作为货架 - 61 - 6. 订单管理接口 - 63 - 6.1 订单付款通知 - 63 - 6.2 依据订单ID获取订单详情 - 63 - 6.3 依据订单状态/创建时间获取订单详情 - 65 - 6.4 设置订单发货信息 - 68 - 6.5 关闭订单 - 69 - 7. 功效接口 - 71 - 7.1 上传图片 - 71 - 1. 商品管理接口 1.1 增加商品 1.1.1 接口调用请求说明 协议 https http请求方法 POST 请求Url POST数据格式 json 1.1.2 请求参数说明 参数 是否必需 说明 access_token 是 公众号调用接口凭证,由access_token生成接口取得 POST数据 是 商品具体信息 1.1.3 POST数据 数据示例: { "product_base": { "category_id": [ "" ], "property": [ { "id": "", "vid": "" }, { "id": "", "vid": "" }, { "id": "", "vid": "" } ], "name": "testaddproduct", "sku_info": [ { "id": "", "vid": [ "", "" ] } ], "main_img": "", "img": [ "" ], "detail": [ { "text": "test first" }, { "img": "" }, { "text": "test again" } ], "buy_limit": 10 }, "sku_list": [ { "sku_id": ":", "price": 30, "icon_url": "", "product_code": "testing", "ori_price": 9000000, "quantity": 800 }, { "sku_id": ":", "price": 30, "icon_url": "", "product_code": "testingtesting", "ori_price": 9000000, "quantity": 800 } ], "attrext": { "location": { "country": "中国", "province": "广东省", "city": "广州市", "address": "T.I.T创意园" }, "isPostFree": 0, "isHasReceipt": 1, "isUnderGuaranty": 0, "isSupportReplace": 0 }, "delivery_info": { "delivery_type": 0, "template_id": 0, "express": [ { "id": 10000027, "price": 100 }, { "id": 10000028, "price": 100 }, { "id": 10000029, "price": 100 } ] } } 字段 是否必选 说明 base_attr 基础属性 name 必选 商品名称 category 必选 商品分类id,商品分类列表请经过《获取指定分类全部子分类》获取 main_img 必选 商品主图(图片需调用图片上传接口取得图片Url填写至此,不然无法添加商品。图片分辨率推荐尺寸为640×600) img 必选 商品图片列表(图片需调用图片上传接口取得图片Url填写至此,不然无法添加商品。图片分辨率推荐尺寸为640×600) detail 必选 商品详情列表,显示在用户端商品详情页内 text 文字描述 img 图片(图片需调用图片上传接口取得图片Url填写至此,不然无法添加商品) property 商品属性列表,属性列表请经过《获取指定分类全部属性》获取 id 属性id vid 属性值id sku_info 商品sku定义,SKU列表请经过《获取指定子分类全部SKU》获取 id sku属性(SKU列表中id, 支持自定义SKU,格式为"$xxx",xxx即为显示在用户端中字符串) vid sku值(SKU列表中vid, 如需自定义SKU,格式为"$xxx",xxx即为显示在用户端中字符串) buy_limit 用户商品限购数量 sku_list sku信息列表(可为多个),每个sku信息串即为一个确定商品,比如白色37码鞋子 sku_id sku信息, 参考上述sku_table定义; 格式 : "id1:vid1;id2:vid2" 规则 : id_info组合个数必需和sku_table个数一致(若商品无sku信息, 即商品为统一规格,则此处赋值为空字符串即可) ori_price sku原价(单位 : 分) price sku微信价(单位 : 分, 微信价必需比原价小, 不然添加商品失败) icon_url sku iconurl(图片需调用图片上传接口取得图片Url) quantity sku库存 product_code 商家商品编码 attrext 商品其它属性 isPostFree 是否包邮(0-否, 1-是), 假如包邮delivery_info字段可省略 isHasReceipt 是否提供发票(0-否, 1-是) isUnderGuaranty 是否保修(0-否, 1-是) isSupportReplace 是否支持退换货(0-否, 1-是) location 商品所在地地址 country 国家(详见《地域列表》说明) province 省份(详见《地域列表》说明) city 城市(详见《地域列表》说明) address 地址 delivery_info 必选 运费信息 delivery_type 运费类型(0-使用下面express字段默认模板, 1-使用template_id代表邮费模板, 详见邮费模板相关API) template_id 邮费模板ID express id 快递ID price 运费(单位 : 分) 1.1.4 返回数听说明 数据示例: { "errcode": 0, "errmsg": "success", "product_id": "pDF3iYwktviE3BzU3BKiSWWi9Nkw" } 字段 说明 errcode 错误码 errmsg 错误信息 product_id 商品ID 1.1.5 附:快递列表 id 说明 10000027 平邮 10000028 快递 10000029 EMS 1.2 删除商品 1.2.1 接口调用请求说明 协议 https http请求方法 POST 请求Url POST数据格式 json 1.2.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品信息 1.2.3 POST数据 数据示例: { "product_id": "pDF3iYwktviE3BzU3BKiSWWi9Nkw" } 字段 说明 product_id 商品ID 1.2.4 返回数听说明 数据示例: { "errcode":0, "errmsg":"success" } 字段 说明 errcode 错误码 errmsg 错误信息 1.3 修改商品 1.3.1 接口调用请求说明 协议 https http请求方法 POST 请求Url POST数据格式 json 1.3.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品详情信息 1.3.3 POST数据 数据示例: { "product_id": "pDF3iY6Kr_BV_CXaiYysoGqJhppQ", "product_base": { "category_id": [ "" ], "property": [ { "id": "", "vid": "" }, { "id": "", "vid": "" }, { "id": "", "vid": "" } ], "name": "testaddproduct", "sku_info": [ { "id": "", "vid": [ "", "" ] } ], "main_img": "", "img": [ "" ], "detail": [ { "img": "" } ], "buy_limit": 3 }, "sku_list": [ { "sku_id": ":", "price": 30, "icon_url": "", "product_code": "testing", "ori_price": 9000000, "quantity": 800 }, { "sku_id": ":", "price": 30, "icon_url": "", "product_code": "testingtesting", "ori_price": 9000000, "quantity": 800 } ], "attrext": { "location": { "country": "中国", "province": "广东省", "city": "广州市", "address": "T.I.T创意园" }, "isPostFree": 0, "isHasReceipt": 1, "isUnderGuaranty": 0, "isSupportReplace": 0 }, "delivery_info": { "delivery_type": 0, "template_id": 0, "express": [ { "id": 10000027, "price": 100 }, { "id": 10000028, "price": 100 }, { "id": 10000029, "price": 100 } ] } } 备注: product_id表示要更新商品ID,其它字段说明请参考增加商品接口。 从未上架商品全部信息均可修改,不然商品名称(name)、商品分类(category)、商品属性(property)这三个字段不可修改。 1.3.4 返回数听说明 数据示例: { "errcode":0, "errmsg":"success" } 字段 说明 errcode 错误码 errmsg 错误信息 1.4 查询商品 1.4.1 接口调用请求说明 协议 https http请求方法 GET 请求Url 1.4.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 1.4.3 POST数据 数据示例: { "product_id": "pDF3iYwktviE3BzU3BKiSWWi9Nkw" } 字段 说明 product_id 商品ID 1.4.4 返回数听说明 数据示例: { "errcode": 0, "errmsg": "success", "product_info": { "product_id": "pDF3iY6Kr_BV_CXaiYysoGqJhppQ", "product_base": { "name": "testaddproduct", "category_id": [ ], "img": [ "" ], "property": [ { "id": "品牌", "vid": "Fujifilm/富士" }, { "id": "屏幕尺寸", "vid": "1.8英寸" }, { "id": "防抖性能", "vid": "CCD防抖" } ], "sku_info": [ { "id": "", "vid": [ "", "" ] } ], "buy_limit": 10, "main_img": "", "detail_html": "<div class=\"item_pic_wrp\" style=\"margin-bottom:8px;font-size:0;\"><img class=\"item_pic\" style=\"width:100%;\" alt=\"\" src=\"\" ></div><p style=\"margin-bottom:11px;margin-top:11px;\">test</p><div class=\"item_pic_wrp\" style=\"margin-bottom:8px;font-size:0;\"><img class=\"item_pic\" style=\"width:100%;\" alt=\"\" src=\"\" ></div><p style=\"margin-bottom:11px;margin-top:11px;\">test again</p>" }, "sku_list": [ { "sku_id": ":", "price": 30, "icon_url": "", "quantity": 800, "product_code": "testing", "ori_price": 9000000 }, { "sku_id": ":", "price": 30, "icon_url": "", "quantity": 800, "product_code": "testingtesting", "ori_price": 9000000 } ], "attrext": { "isPostFree": 0, "isHasReceipt": 1, "isUnderGuaranty": 0, "isSupportReplace": 0, "location": { "country": "中国", "province": "广东省", "city": "广州市", "address": "T.I.T创意园" } }, "delivery_info": { "delivery_type": 1, "template_id": } } } 字段 说明 errcode 错误码 errmsg 错误信息 product_info 商品详情(字段说明详见增加商品) 1.5 获取指定状态全部商品 1.5.1 接口调用请求说明 协议 https http请求方法 POST 请求Url 1.5.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品详情信息 1.5.3 POST数据 数据示例: { "status": 0 } 字段 说明 status 商品状态(0-全部, 1-上架, 2-下架) 1.5.4 返回数听说明 数据示例: { "errcode": 0, "errmsg": "success", "products_info": [ { "product_base": ..., "sku_list": ..., "attrext": ..., "delivery_info": ..., "product_id": "pDF3iY-mql6CncpbVajaB_obC3Bk", "status": 1 }, { "product_base": ..., "sku_list": ..., "attrext": ..., "delivery_info": ..., "product_id": "pDF3iY-mql6CncpbVajaB_obC321", "status": 1 } ] } 字段 说明 errcode 错误码 errmsg 错误信息 products_info 指定状态下全部商品集合 1.6 商品上下架 1.6.1 接口调用请求说明 协议 https http请求方法 POST 请求Url 1.6.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品详情信息 1.6.3 POST数据 数据示例: { "product_id": "p0FfkjnSNm4NQj0_4a9l9MtRRxzA", "status": 0 } 字段 说明 product_id 商品ID status 商品上下架标识(0-下架, 1-上架) 1.6.4 返回数听说明 数据示例: { "errcode":0, "errmsg":"success" } 字段 说明 errcode 错误码 errmsg 错误信息 1.7 获取指定分类全部子分类 1.7.1 接口调用请求说明 协议 https http请求方法 POST 请求Url 1.7.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品大分类信息 1.7.3 POST数据 数据示例: { "cate_id": } 字段 说明 cate_id 大分类ID(根节点分类id为1) 1.7.4 返回数听说明 数据示例: { "errcode": 0, "errmsg": "success", "cate_list": [ { "id": "", "name": "数码相机" }, { "id": "", "name": "家用摄像机" }, { "id": "", "name": "单反相机" }, { "id": "", "name": "镜头" }, { "id": "53710", "name": "单电/微单" } ] } 字段 说明 errcode 错误码 errmsg 错误信息 cate_list 子分类列表 id 子分类ID name 子分类名称 1.8 获取指定子分类全部SKU 1.8.1 接口调用请求说明 协议 https http请求方法 POST 请求Url 1.8.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品子分类信息 1.8.3 POST数据 数据示例: { "cate_id": } 字段 说明 cate_id 商品子分类ID 1.8.4 返回数听说明 数据示例: { "errcode": 0, "errmsg": "success", "sku_table": [ { "id": "", "name": "颜色", "value_list": [ { "id": "", "name": "撞色" }, { "id": "", "name": "桔色" } ] } ] } 字段 说明 errcode 错误码 errmsg 错误信息 sku_table sku列表 id sku id name sku 名称 value_list sku vid列表 id vid name vid名称 1.9 获取指定分类全部属性 1.9.1 接口调用请求说明 协议 https http请求方法 POST 请求Url 1.9.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品分类信息 1.9.3 POST数据 数据示例: { "cate_id": } 字段 说明 cate_id 分类ID 1.9.4 返回数听说明 数据示例: { "errcode": 0, "errmsg": "success", "properties": [ { "id": "", "name": "品牌", "property_value": [ { "id": "50867", "name": "VIC&#38" }, { "id": "50868", "name": "Kate&#38" }, { "id": "50971", "name": "M&#38" }, { "id": "50972", "name": "Black&#38" } ] }, { "id": "", "name": "颜色", "property_value": ... } ] } 字段 说明 errcode 错误码 errmsg 错误信息 properties 属性列表 id 属性id name 属性名称 property_value 属性值 id 属性值id name 属性值名称 2. 库存管理接口 2.1 增加库存 2.1.1 接口调用请求说明 协议 https http请求方法 POST 请求Url POST数据格式 json 2.1.2 请求参数说明 参数 是否必需 说明 access_token 是 公众号调用接口凭证 POST数据 是 商品库存信息 2.1.3 POST数据 数据示例: { "product_id": "pDF3iY5EYkMxs4-tF8xedyES5GQI", "sku_info": "10000983:10000995;10001007:10001010", "quantity": 20 } 字段 说明 product_id 商品ID sku_info sku信息,格式"id1:vid1;id2:vid2",如商品为统一规格,则此处赋值为空字符串即可 quantity 增加库存数量 2.1.4 返回数听说明 数据示例: { "errcode":0, "errmsg":"success" } 字段 说明 errcode 错误码 errmsg 错误信息 2.2 降低库存 2.2.1 接口调用请求说明 协议 https http请求方法 POST 请求Url POST数据格式 json 2.2.2 请求参数说明 参数 是否必需 说明 access_token 是 调用接口凭证 POST数据 是 商品库存信息 2.2.3 POST数据 数据示例: { "product_id": "pDF3iY5EYkMxs4-tF8xedyES5GQI", "sku_info": "10000983:10000995;10001007:10001010", "quantity": 20 } 字段 说明 product_id 商品ID sku_info sku信息, 格式"id1:vid1;id2:vid2" quantity 降低库存数量 2.2.4 返回数听说明 数据示例: { "errcode":0, "errmsg":"success" } 字段 说明 errcode 错误码 errmsg 错误信息 3. 邮费模板管理接口 3.1 增加邮费模板 3.1.1 接口调用请求说明 协议 https http请求方法 POST 请求Url POST数据格式 json 3.1.2 请求参数说明 参数 是否必需 说明 access_token 是 公众号调用接口凭证 POST数据 是 邮费信息 3.1.3 POST数据 数据示例: { "delivery_template": { "Name": "testexpress", "Assumer": 0, "Valuation": 0, "TopFee": [ { "Type": 10000027, "Normal": { "StartStandards": 1, "StartFees": 2, "AddStandards": 3, "AddFees": 1 }, "Custom": [{ "StartStandards": 1, "StartFees": 100, "AddStandards": 1, "AddFees": 3, "DestCountry": "中国", "DestProvince": "广东省", "DestCity": "广州市" }] }, { "Type": 10000028, "Normal": { "StartStandards": 1, "StartFees": 3, "AddStandards": 3, "AddFees": 2 }, "Custom": [{ "StartStandards": 1, "StartFees": 10, "AddStandards": 1, "AddFees": 30, "DestCountry": "中国", "DestProvince": "广东省", "DestCity": "广州市" }] }, { "Type": 10000029, "Normal": { "StartStandards": 1, "StartFees": 4, "AddStandards": 3, "AddFees": 3 }, "Custom": [{ "StartStandards": 1, "StartFees": 8, "AddStandards": 2, "AddFees": 11, "DestCountry": "中国", "DestProvince": "广东省", "DestCity": "广州市" }] } ] } } 字段 说明 Name 邮费模板名称 Assumer 支付方法(0-买家负担运费, 1-卖家负担运费) Valuation 计费单位(0-按件计费, 1-按重量计费, 2-按体积计费,现在只支持按件计费,默认为0) TopFee 具体运费计算 Type 快递类型ID(参见增加商
展开阅读全文

开通  VIP会员、SVIP会员  优惠大
下载10份以上建议开通VIP会员
下载20份以上建议开通SVIP会员


开通VIP      成为共赢上传

当前位置:首页 > 包罗万象 > 大杂烩

移动网页_全站_页脚广告1

关于我们      便捷服务       自信AI       AI导航        抽奖活动

©2010-2026 宁波自信网络信息技术有限公司  版权所有

客服电话:0574-28810668  投诉电话:18658249818

gongan.png浙公网安备33021202000488号   

icp.png浙ICP备2021020529号-1  |  浙B2-20240490  

关注我们 :微信公众号    抖音    微博    LOFTER 

客服