微唯宝供应链API接口文档

v4.0.1

接口使用流程

权限认证

获取token

POST /api/noAuth/access_token

token用于后续接口的调用,token有效期为24小时。

请求参数

名称 位置 类型 必选 说明
app_id query string true 从系统后台管理获取
sign query string true 签名: 按照以下顺序将字符串拼接起来 app_id+mobile+timestamp+app_secret 再用md5加密
mobile query string false 系统后台设置的手机号
timestamp query string false 时间戳

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634726044,
  "result": {
    "access_token": "51fde1886546401484ceabd2bf890943", //用于调用接口的凭证
    "expire_time": "2021-10-23 18:33:41" //到期时间
  }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

商品相关

获取商品是否有货

POST /api/goods/stock

Body 请求参数

{
  "type": "object",
  "properties": {}
}

请求参数

名称 位置 类型 必选 说明
access_token query string true 访问口令
sku_id query string true 商品sku
address_id query string false 地址id(传四级地址,没有四级传三级)
goods_num query string false 商品数量
body body object false none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634900876,
  "result": "有货"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

获取商品详情

POST /api/goods/get_spuId_info

请求参数

名称 位置 类型 必选 说明
access_token query string true 访问口令
spu_id query string true 商品spuid

返回示例

{
    "error_code": 0,
    "error_msg": "",
    "time": 1646816620,
    "result": {
        "id": 193027,
        "spu_id": "X1465949206730567682",
        "source_type": 2,
        "band_name": "艾贝丽",
        "cate_ids": "4244,4501,7392", //分类id(一级分类,二级分类,三级分类)
        "tag_ids": null,
        "title": "NLP+仁人肽营养代餐固体饮料+225g(25gX9)",
        "cover_url": "https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/f381233bba2b4c0d88b22a53a1f2053d.jpg",
        "detail_img_list": "[\"https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/f381233bba2b4c0d88b22a53a1f2053d.jpg\", \"https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/03f2214e95a345b1b996122615137429.jpg\", \"https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/61a6f5020ff040b3a17cf12b55919861.jpg\", \"https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/9ff264d74c4c48d7b952fec7e6bbd5cb.jpg\", \"https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/5fc1c9fdd2f34121adcb521feddd19af.jpg\"]",
        "limit_num": 0,//限购数量,每次下单限制数量
        "lowest_num": 1,//起购数量
        "market_price": "498.00",
        "cost_price": "76.74",
        "is_limit_area": 1,//是否限购地区 1是 0否
        "limit_area_type": 0,//0 : 可销售地区,1: 不可销售地区
        "limit_area": "[463, 462, 469, 477, 474, 473, 475, 470, 476, 471, 478, 468, 467, 464, 472, 466, 465, 479, 130, 125, 121, 128, 129, 115, 123, 116, 131, 120, 119, 114, 126, 132, 134, 133, 124, 118, 127, 122, 117, 182, 190, 188, 181, 187, 183, 180, 189, 185, 184, 191, 186, 483, 486, 490, 481, 482, 487, 491, 480, 489, 492, 488, 485, 484, 113, 104, 93, 100, 101, 105, 111, 112, 94, 98, 110, 96, 95, 106, 102, 109, 107, 103, 97, 108, 99, 360, 364, 356, 358, 352, 354, 362, 359, 348, 361, 351, 350, 363, 357, 353, 349, 355, 248, 246, 254, 250, 255, 257, 247, 256, 252, 253, 245, 249, 244, 251, 453, 451, 447, 445, 450, 457, 458, 452, 446, 460, 454, 455, 461, 449, 448, 459, 239, 237, 242, 235, 243, 236, 234, 241, 238, 240, 27, 225, 229, 228, 226, 233, 232, 227, 231, 230, 2, 322, 324, 327, 328, 325, 326, 323, 216, 213, 220, 212, 210, 221, 219, 223, 217, 218, 224, 211, 209, 215, 214, 222, 338, 330, 336, 337, 333, 331, 335, 332, 334, 425, 420, 419, 417, 426, 421, 424, 422, 429, 430, 418, 427, 428, 423, 400, 411, 406, 414, 412, 416, 403, 407, 410, 401, 415, 413, 398, 402, 409, 399, 405, 408, 404, 306, 300, 310, 309, 308, 299, 307, 298, 303, 304, 305, 302, 301, 269, 276, 274, 271, 275, 273, 270, 272, 168, 166, 179, 178, 174, 177, 175, 169, 173, 172, 176, 170, 171, 167, 193, 196, 192, 195, 194, 207, 200, 201, 206, 199, 205, 202, 204, 198, 203, 197, 139, 144, 141, 140, 138, 142, 145, 143, 137, 135, 136, 314, 315, 311, 316, 312, 318, 321, 319, 317, 313, 320, 439, 435, 442, 444, 431, 432, 433, 434, 436, 441, 437, 443, 440, 438, 282, 277, 279, 293, 278, 296, 286, 290, 280, 289, 285, 287, 295, 291, 284, 297, 281, 283, 288, 292, 294, 6, 261, 267, 266, 258, 259, 260, 268, 264, 262, 263, 265, 396, 386, 395, 387, 394, 397, 393, 384, 389, 392, 391, 383, 1, 344, 339, 340, 342, 345, 347, 343, 346, 341]",//限购区域id
        "is_del": 2,
        "detail": "< img src='https://scce-cos-prd.obs.cn-south-1.myhuaweicloud.com:443/c90b7760f33b4a4480b3ce837a2f7124.jpg'>",
        "img_detail": null,
        "tag_name": ""
    }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

获取商品spu列表

POST /api/goods/get_spuid_list

请求参数

名称 位置 类型 必选 说明
page query string false 当前页
limit query string false 每页数量
access_token query string false 凭证

返回示例

成功

{
    "error_code": 0,
    "error_msg": "",
    "time": 1635825547,
    "result": {
        "data": [
            {
                "id": 26,
                "goods_id": 35392,
                "sys_id": 1,
                "update_time": "2021-10-29 11:02:17",
                "create_time": "2021-10-29 11:02:17",
                "spuId": "100017527394",
                "skuId": "100017527394,100024945576,5559974"
            },
            {
                "id": 27,
                "goods_id": 16093,
                "sys_id": 1,
                "update_time": "2021-10-29 11:03:16",
                "create_time": "2021-10-29 11:03:16",
                "spuId": "100009572451",
                "skuId": "100009572451"
            },
            {
                "id": 28,
                "goods_id": 18979,
                "sys_id": 1,
                "update_time": "2021-10-29 11:03:37",
                "create_time": "2021-10-29 11:03:37",
                "spuId": "100017215506",
                "skuId": "100017215506"
            },
            {
                "id": 29,
                "goods_id": 67,
                "sys_id": 1,
                "update_time": "2021-10-29 13:54:17",
                "create_time": "2021-10-29 13:54:17",
                "spuId": "100011624444",
                "skuId": "100011624444,100011624442,100002040117,100002040115"
            },
            {
                "id": 30,
                "goods_id": 816,
                "sys_id": 1,
                "update_time": "2021-10-29 15:14:54",
                "create_time": "2021-10-29 15:14:54",
                "spuId": "100020576708",
                "skuId": "100020576708,100020576524"
            },
            {
                "id": 31,
                "goods_id": 38661,
                "sys_id": 1,
                "update_time": "2021-10-29 15:14:54",
                "create_time": "2021-10-29 15:14:54",
                "spuId": "10036515791348",
                "skuId": "10036515791348"
            }
        ],
        "total": 6,
        "pages": 1,
        "pageSize": "10",
        "page": "1"
    }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

获取商品规格

POST /api/goods/get_skuId_info

请求参数

名称 位置 类型 必选 说明
access_token query string true 访问口令
spu_id query string true 商品spuid

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1635245847,
  "result": [
    {
      "sku_sn": "100015361148",
      "img_url": "jfs/t1/195266/31/11023/64523/60dd4f43E8cfb8bca/bd2688c6a853c6cf.jpg",
      "market_price": "4.00",
      "cost_price": "3.90",
      "attribute_json": [
        {
          "val": "医用外科10个装1包",
          "name": "颜色"
        },
        {
          "val": "标准",
          "name": "尺码"
        }
      ],
    "detail": ["img30.360buyimg.com/sku/jfs/t1/120582/16/15887/88971/5f901f0cE39bd99a2/4ee698087d69f795.jpg"]
    }
  ]
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

获取商品价格

POST /api/goods/sell_price

请求参数

名称 位置 类型 必选 说明
access_token query string true 访问口令
skuIds query string true 商品skuid 数组格式['984783','ADH22123']

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1635158421,
  "result": [
    {
      "sku_id": 965717,
      "cost_price": 35,
      "price": 52.9
    }
  ]
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

POST 商品上下架

POST /api/goods/status

请求参数

名称 位置 类型 必选 说明
access_token query string false none
spu_id query string false none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1637216947,
  "result": [
    {
      "sku_id": "1424929084936933378",
      "status": "0  //0下架,1上架"
    }
  ]
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

订单相关

确认收货

POST /api/order/confirm_received

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string"
    },
    "out_order_no": {
      "type": "string"
    }
  },
  "required": [
    "access_token",
    "out_order_no"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» out_order_no body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "确认收货完成"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

查询订单状态

POST /api/order/status

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string"
    },
    "out_order_no": {
      "type": "string",
      "title": "外部系统sn"
    }
  },
  "required": [
    "access_token",
    "out_order_no"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» out_order_no body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": 3
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

运费查询(下单前调用,确定可售,不调用会导致下单失败)

POST /api/order/freight

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string"
    },
    "sku_list": {
      "type": "object",
      "properties": {
        "sku_id": {
          "type": "string",
          "title": "商品skuid"
        },
        "num": {
          "type": "number",
          "title": "数量"
        }
      },
      "required": [
        "sku_id",
        "num"
      ],
      "title": "sku列表"
    },
    "address_id": {
      "type": "integer",
      "title": "地址id"//(传四级地址,没有四级传三级)
    }
  },
  "required": [
    "access_token",
    "sku_list",
    "address_id"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» sku_list body object true none
»» sku_id body string true none
»» num body number true none
» address_id body integer true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634624632,
  "return": {
    "freight": "0//运费"
  }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

正式下单

POST /api/order/submit

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string",
      "title": "凭据"
    },
    "sku_list": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "sku_id": {
            "type": "string"
          },
          "num": {
            "type": "integer",
            "title": "购买数量"
          }
        },
        "required": [
          "sku_id",
          "num"
        ]
      },
      "description": "[{\"sku_id\"=>1119934,'num'=>1}]",
      "title": "商品的sku和商品数量"
    },
    "address_id": {
      "type": "integer",
      "title": "地址id"//(传四级地址,没有四级传三级)
    },
    "address": {
      "type": "string",
      "title": "地址详情"
    },
    "third_order": {
      "type": "string",
      "title": "外部系统sn"
    },
    "other": {
      "type": "string",
      "title": "备注"
    },
    "receiver": {
      "type": "string",
      "title": "收货人"
    },
    "receiver_phone": {
      "type": "string",
      "title": "收货人电话"
    }
  },
  "required": [
    "access_token",
    "sku_list",
    "address_id",//(传四级地址,没有四级传三级)
    "address",
    "third_order",
    "other",
    "receiver",
    "receiver_phone"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» sku_list body [object] true [{"sku_id"=>1119934,'num'=>1}]
»» sku_id body string true none
»» num body integer true none
» address_id body integer true none
» address body string true none
» third_order body string true none
» other body string true none
» receiver body string true none
» receiver_phone body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634624632,
  "return": {
    "supply_sn": 228664808722,
    "order_price": 23.63,
    "sku": [
      {
        "skuId": 9636696,
        "num": 1,
        "category": 1590,
        "price": 23.63,
        "name": "休闲零食 104g*3组合装(番茄+原味+烤肉)膨化食品"
      }
    ]
  }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

手动发货

POST /api/order/send

用于测试商品

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string"
    },
    "out_order_no": {
      "type": "string",
      "title": "订单号"
    },
    "logistics_number": {
      "type": "string",
      "title": "物流单号"
    },
    "logistics_company": {
      "type": "string",
      "title": "物流名称"
    }
  },
  "required": [
    "access_token",
    "out_order_no",
    "logistics_number",
    "logistics_company"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» out_order_no body string true none
» logistics_number body string true none
» logistics_company body string true none

返回示例

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

查询配送信息

POST /api/order/track

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string",
      "title": "凭据"
    },
    "out_order_no": {
      "type": "string",
      "title": "外部系统sn"
    }
  },
  "required": [
    "access_token",
    "out_order_no"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» out_order_no body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634624632,
  "return": {
    "orderTrack": [
      {
        "content": "您提交了订单,请等待系统确认",
        "msgTime": "2021-10-18 14:02:21",
        "operator": "客户"
      }
    ]
  }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

查询订单详情

POST /api/order/details

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string"
    },
    "out_order_no": {
      "type": "string",
      "title": "外部系统sn"
    }
  },
  "required": [
    "access_token",
    "out_order_no"
  ]
}

请求参数

名称 位置 类型 必选 说明
access_token query string false none
out_order_no query string false none
body body object false none
» access_token body string true none
» out_order_no body string true none

返回示例

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

售后相关

查询商品是否可售后属性

POST /api/after/is_can

Body 请求参数

{
  "type": "object",
  "properties": {
    "out_order_no": {
      "type": "string",
      "title": "外部系统订单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "out_order_no",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» out_order_no body string true none
» access_token body string true none

返回示例

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

确认寄回(测试商品)

POST /api/after/confirm_send_back

Body 请求参数

{
  "type": "object",
  "properties": {
    "after_sn": {
      "type": "string",
      "title": "售后订单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "after_sn",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» after_sn body string true none
» access_token body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "成功"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

取消申请售后

POST /api/after/cancel_apply

Body 请求参数

{
  "type": "object",
  "properties": {
    "after_sn": {
      "type": "string",
      "title": "售后订单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "after_sn",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» after_sn body string true none
» access_token body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "成功"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

确认申请售后(测试商品)

POST /api/after/confirm

Body 请求参数

{
  "type": "object",
  "properties": {
    "after_sn": {
      "type": "string",
      "title": "售后订单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "after_sn",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» after_sn body string true none
» access_token body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "成功"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

申请售后

POST /api/after/create_apply

Body 请求参数

{
  "type": "object",
  "properties": {
    "access_token": {
      "type": "string"
    },
    "out_order_no": {
      "type": "string",
      "title": "订单号"
    },
    "customer_expect": {
      "type": "string",
      "title": "客户期望售后类型。1退货退款,2换货"
    },
    "question_desc": {
      "type": "string",
      "title": "申请理由"
    },
    "sku_id": {
      "type": "string",
      "title": "商品skuid"
    },
    "img": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "title": "退货图片 json ['','','']  需完整的带域名的链接"
    }
  },
  "required": [
    "access_token",
    "out_order_no",
    "customer_expect",
    "question_desc",
    "sku_id",
    "img"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» access_token body string true none
» out_order_no body string true none
» customer_expect body string true none
» question_desc body string true none
» sku_id body string true none
» img body [string] true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": {
    "after_sn": "A2364782342873"
  }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

填写发货信息

POST /api/after/update_send_info

Body 请求参数

{
  "type": "object",
  "properties": {
    "after_sn": {
      "type": "string",
      "title": "售后订单号"
    },
    "logistics_company": {
      "type": "string",
      "title": "物流公司名称"
    },
    "logistics_number": {
      "type": "string",
      "title": "物流单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "after_sn",
    "logistics_company",
    "logistics_number",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» after_sn body string true none
» logistics_company body string true none
» logistics_number body string true none
» access_token body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "发货成功"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

取消寄回(测试商品)

POST /api/after/refuse_send_back

Body 请求参数

{
  "type": "object",
  "properties": {
    "after_sn": {
      "type": "string",
      "title": "售后订单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "after_sn",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» after_sn body string true none
» access_token body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "成功"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

拒绝售后申请(测试商品)

POST /api/after/refuse_after

Body 请求参数

{
  "type": "object",
  "properties": {
    "after_sn": {
      "type": "string",
      "title": "售后订单号"
    },
    "access_token": {
      "type": "string"
    }
  },
  "required": [
    "after_sn",
    "access_token"
  ]
}

请求参数

名称 位置 类型 必选 说明
body body object false none
» after_sn body string true none
» access_token body string true none

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634627760,
  "result": "成功"
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

地址相关

获取地区代码

POST /api/regions/get_region_code

获取地址库地址信息: 查询一级地区,不传code;查询二级地区,传一级地区的code;查询三级地区,传二级地区的code;查询四级地区,传三级地区的code

请求参数

名称 位置 类型 必选 说明
code query string false 地区代码
access_token query string false 凭证

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634795049,
  "result": [
    {
      "name": "北京",
      "code": 1
    },
    {
      "name": "重庆",
      "code": 2
    },
    {
      "name": "新疆",
      "code": 3
    },
    {
      "name": "广东",
      "code": 4
    },
    {
      "name": "浙江",
      "code": 5
    },
    {
      "name": "天津",
      "code": 6
    },
    {
      "name": "港澳",
      "code": 7
    },
    {
      "name": "广西",
      "code": 8
    },
    {
      "name": "内蒙古",
      "code": 9
    },
    {
      "name": "宁夏",
      "code": 10
    },
    {
      "name": "江西",
      "code": 11
    },
    {
      "name": "台湾",
      "code": 12
    },
    {
      "name": "安徽",
      "code": 13
    },
    {
      "name": "贵州",
      "code": 14
    },
    {
      "name": "陕西",
      "code": 15
    },
    {
      "name": "辽宁",
      "code": 16
    },
    {
      "name": "山西",
      "code": 17
    },
    {
      "name": "青海",
      "code": 18
    },
    {
      "name": "四川",
      "code": 19
    },
    {
      "name": "江苏",
      "code": 20
    },
    {
      "name": "河北",
      "code": 21
    },
    {
      "name": "西藏",
      "code": 22
    },
    {
      "name": "钓鱼岛",
      "code": 23
    },
    {
      "name": "福建",
      "code": 24
    },
    {
      "name": "吉林",
      "code": 25
    },
    {
      "name": "湖北",
      "code": 26
    },
    {
      "name": "上海",
      "code": 27
    },
    {
      "name": "云南",
      "code": 28
    },
    {
      "name": "海南",
      "code": 29
    },
    {
      "name": "湖南",
      "code": 30
    },
    {
      "name": "甘肃",
      "code": 31
    },
    {
      "name": "山东",
      "code": 32
    },
    {
      "name": "河南",
      "code": 33
    },
    {
      "name": "黑龙江",
      "code": 34
    }
  ]
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构

商品分类相关

获取商品分类

POST /api/category/get_list

获取商品分类

请求参数

名称 位置 类型 必选 说明
access_token query string true 凭证
pid query int false 父id(默认为0一级分类)
page query int false 页数(0默认第一页)

返回示例

成功

{
  "error_code": 0,
  "error_msg": "",
  "time": 1634795049,
  "result":
    {"data":
    [{
      "id": "2",
      "name": "安防用品",
      "pid":1,//父id
    }]
    }
}

返回结果

状态码 状态码含义 说明 数据模型
200 OK 成功 Inline

返回数据结构