用户工具

站点工具


侧边栏

订单

订单接口


1、订单列表

接口名称

orders/list

请求方式

get

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
type int 订单类型
orderNo string 订单编号
startTime date 订单创建开始时间
endTime date 订单创建结束时间
status int 订单状态 (不传获取所有订单0 :待付款,1 :待发货,2 :待收货,3 :交易成功,4:交易取消,5:交易关闭,6:等待卖家处理,7待评价)
productName string 产品名称
pageSizeint每页数量 默认为50

返回值

名称 类型 说明
items data 数据
_links data 分页信息
_meta data 查询数据信息

items数据说明

名称 类型 说明
id int 订单ID
order_no string 订单编号
supplier_id int 供货商ID
member_id int 买家ID
order_type int订单类型 1 实物订单 2 积分兑换订单
order_money number 订单金额
discount number 折扣
shipping_costs number 运费
order_total number 订单合计金额
pay_money number 支付金额
quantity int 合计件数
create_time string 创建时间
pay_time string 支付时间
ship_time string 查询数据信息
complete_time string 发货时间
express int 配送方式
express_code string 运单号
cancle_time string 取消时间
status int订单状态订单状态 0 待付款 1待发货 2待收货 3交易成功 4交易取消5交易关闭 6 等待卖家处理
memos string 订单备注
buyer_feedback string 买家留言
is_comment int 是否评论
shopName string 店铺名称
details array 订单产品信息
 {
          "id": "43", //订单详情id
          "orders_id": "26",//订单ID
          "product_id": "3",//产品ID
          "sku_id": "3",//产品SKU ID
          "product_name": "432432432",//产品名称
          "properties": "颜色:红色,大小:X,套餐:电信",//SKU属性
          "quantity": "2",//购买数量
          "price": "22.00",//单价
          "total": "44.00",//小计
          "cost": "46.00",//成本价
          "back_status": "0",//退款状态(0没有退款,1申请中,2退款成功,3退款失败,4退款中)
          "back_id": "5",//退款id
          "pic1": "http://pic.8dage.net/data/uploadfile/images/1/20160504/6c50be469f.png"////产品图片
        }

2、订单详情

接口名称

orders/detail

请求方式

get

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
orderId int 订单id

返回值

名称 类型 说明
id int 订单ID
order_no string 订单编号
supplier_id int 供货商ID
member_id int 买家ID
order_type int 订单类型 1 实物订单 2 积分兑换订单
order_money number 订单金额
discount number 折扣
shipping_costs number 运费
order_total number 订单合计金额
pay_money number 支付金额
quantity int 合计件数
create_time string 创建时间
pay_time string 支付时间
ship_time string 查询数据信息
complete_time string 发货时间
express int 配送方式
express_code string 运单号
cancle_time string 取消时间
status int 订单状态订单状态 0 待付款 1待发货 2待收货 3交易成功 4交易取消5交易关闭 6 取消订单等待卖家处理
memos string 订单备注
buyer_feedback string 买家留言
is_comment int 是否评论
shopName string 店铺名称
shopServiceTel string 店铺电话
detail array 订单产品信息
 {
          "id": "43", //订单详情id
          "orders_id": "26",//订单ID
          "product_id": "3",//产品ID
          "sku_id": "3",//产品SKU ID
          "product_name": "432432432",//产品名称
          "properties": "颜色:红色,大小:X,套餐:电信",//SKU属性
          "quantity": "2",//购买数量
          "price": "22.00",//单价
          "total": "44.00",//小计
          "cost": "46.00",//成本价
          "back_status": "0",//退款状态(0没有退款,1申请中,2退款成功,3退款失败,4退款中)
          "back_id": "5",//退款id
          "pic1": "http://pic.8dage.net/data/uploadfile/images/1/20160504/6c50be469f.png"////产品图片
        }

3、创建订单

接口名称

orders/create

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
orderType int 订单类型(1 实物订单 2 积分兑换订单 默认为实物订单)
discount number 折扣 (默认为0)
addressId int 买家收货地址id
productSkuId int 产品skuid
buyCount int 购买数量
buyerFeedback string 买家留言

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息
data array 返回数据
id(订单id), order_no(订单编号), supplier_id(供货商id), member_id(买家id), order_type(订单类型), pay_money(订单金额id), reate_time(时间), product_name(产品名称),point(订单积分)

4、从购物车创建订单

接口名称

orders/create-by-cart

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
orderType int 订单类型
discount number 折扣
addressId int 买家收货地址id
carts string购物车id,多个以逗号拼接
buyerFeedback string 买家留言

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息
data array 返回数据
id(产品id),
order_no(订单编号),
supplier_id(供货商id),
member_id(买家id),
order_type(订单类型),
pay_money(订单金额id),
reate_time(时间),
product_name(产品名称),,point(订单积分)

5、支付订单

接口名称

orders/pay

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
orderId int 订单id
orderMoney number 订单金额
buyerId int 买家id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

6、订单发货

接口名称

orders/fahuo

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
orderId int 订单id
expressType string 快递类型
expressCode string 快递名称
sellerId int 卖家id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

7、订单确认收货

接口名称

orders/confirm

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
orderId int 订单id
buyerId int 买家id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

8、取消订单

接口名称

orders/cancel

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
orderId int 订单id
buyerId int 买家id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

9、申请退款

接口名称

orders/apply-refund

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
orderDetailId int 订单详情id
backNote string 退款说明
backPrice string 退款金额
backPic string 退款凭证
backType number默认为1 ,退款类型 (1.仅退款 ,2.退货退款)
goodsType number默认为1 ,货物状态 (1.未收到货 ,2.已收到货)
backReason number默认为1 , 退款原因 (1.7天无理由退换货 ,2.质量问题)

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息
dataint退款id

10、买家取消退款

接口名称

orders/callce-refund

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
backId int 退款id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

11、卖家拒绝退款

接口名称

orders/refuse-refund

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
sellerId int 卖家id
backId int 退款id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

12、卖家同意退款

接口名称

orders/agree-refund

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
sellerId int 卖家id
backId int 退款id
backAddrs int 退货地址id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

13、买家退货

接口名称

orders/return-goods

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id
backId int 退款id
shippingId int 快递id
shippingName string 快递名称
invoiceNo string 快递单号

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

14、卖家确认退货

接口名称

orders/agree-return

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
sellerId int 卖家id
backId int 退款id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息

15、根据会员id获取订单状态数量

接口名称

orders/order-num-by-status

请求方式

get

请求参数

参数名称 参数类型 是否必填 说明
buyerId int 买家id

返回值

allCount int 所有订单数量
daipayCount int 待支付
daifhCount int 待发货
daishCount int 待收货
succCount int交易成功
daipjCount int待评价

16、获取订单支付签名

接口名称

orders/get-sign

请求方式

get

请求参数

参数名称 参数类型 是否必填 说明
orderNo string 订单编号
payType string 支付类型 llQuickPay 连连快捷支付 llApplePay 连连苹果支付 alipay 支付宝

返回值

result string 结果 success 成功 error 失败
message string 提示信息
data string 返回数据

17、获取快递费

接口名称

orders/calculate-shipping

请求方式

get

请求参数

参数名称 参数类型 是否必填 说明
destination int 收货地址所在地
buyCount int 购买件数
freightTemplatestring运费模板id

返回值

名称 类型 说明
from string 买家地区
to string 卖家地区
yunfei int运费

18、删除订单

接口名称

orders/delete

请求方式

post

请求参数

参数名称 参数类型 是否必填 说明
orderId int 订单id
buyerId int 买家id

返回值

名称 类型 说明
result bool 返回结果 success 成功 error 失败
message string 返回信息
订单.1470134419.txt.gz · 最后更改: 2017/06/01 13:58 (外部编辑)