2.5获取结算单信息

优质
小牛编辑
126浏览
2023-12-01

对接API接口,自行实现MQTT对接模式下,下行接口收到cash-pay推送时(下行接口说明见0.5),根据推送的支付流水号id调用本接口来获取支付单详情。

DLL接口已封装,无需直接调用本接口。

请求参数说明

参数描述必填示例值类型最大长度
action接口参数组object
└action需要调用的接口名称cash_get_paystring
getGET参数组,本组参数需要参与签名object
└id支付单流水号payid8601436320number

请求示例

{
	"action": {
		"action": "cash_get_pay"
	},
	"get": {
		"id": "8601451797"
	}
}

响应参数说明

参数描述必填示例值类型最大长度
status返回状态。接口成功时为1,出错为01number
id支付单流水号payid8601436320number
state支付状态,3为支付完成3number
type0number
table桌台号1211number
mbextidstring
mbaccid会员卡id2513240number
mbcardno会员卡号25132402number
mblevel会员等级,0为非会员,>0为会员1number
src支付方式,wx=微信,ali=支付宝wxstring
cate业务分类taostring
doid订单id8600103731number
bzid收银系统业务流水号string
amt支付总金额9.00number
discount折扣金额0.00number
payamt实付金额9number
time时间2019-09-16 13:28:41string
trid微信/支付宝支付流水号4200000388201909160062029411number
route支付通道spstring
pay_co优惠券金额0number
pay_mc会员卡金额7.99
pay_pt积分金额0.61
pay_wx微信金额0.40number
pay_ali支付宝金额0number
list组合支付列表list
└type支付类型,wx=微信,ali=支付宝,mc=会员卡,co=优惠券,pt=积分mcstring
└amt金额7.99
└points积分(type=pt时会有)61number
└accid会员卡id(type=mc)2513240number
└acdid会员/积分交易流水号(type=mc,pt)28611698number
└cardno会员卡号(type=mc)25132402number
└bonus_amt会员赠送部分金额(type=mc)7.99number

响应示例

{
	"status": "1",
	"id": "8601436320",
	"state": "3",
	"type": 0,
	"table": "1211",
	"mbextid": "",
	"mbaccid": "2513240",
	"mbcardno": "25132402",
	"mblevel": "1",
	"src": "wx",
	"cate": "tao",
	"doid": "8600103731",
	"bzid": "",
	"amt": "9.00",
	"discount": "0.00",
	"payamt": 9,
	"time": "2019-09-16 13:28:41",
	"trid": "4200000388201909160062029411",
	"route": "sp",
	"pay_co": 0,
	"pay_mc": 7.99,
	"pay_pt": 0.61,
	"pay_wx": "0.40",
	"pay_ali": 0,
	"list": [{
		"type": "mc",
		"amt": 7.99,
		"accid": "2513240",
		"cardno": "25132402",
		"acdid": 28611697,
		"bonus_amt": "7.99"
	}, {
		"type": "pt",
		"amt": 0.61,
		"points": 61,
		"accid": "2513240",
		"acdid": 28611698
	}, {
		"type": "wx",
		"amt": "0.40"
	}]
}