Skip to content

查询订单

功能简述

  • 查询支付系统支付订单状态

查询订单 API

请求 URL

  • /orders/{ORDER_ID}
    • {ORDER_ID}:您的支付 ID

请求 Method

  • order.detail

请求方式

  • GET

请求参数

请求参数如下:

响应参数

响应参数如下:

  • Response Body
参数类型描述示例
amountnumber订单金额,注意这里是数字类型,浮点数,最多两位小数3.23
tipnumber订单小费"10.02"
taxAmountnumber税费"10"
refundAmountnumber发生退款的总金额0.99
idstringSGate 支付订单 ID,系统自动生成,全局唯一"M000001T2022101023455774363043"
clientIdstring创建订单通过的 Client 的 ID"CLT0000001"
clientIpstring客户下单时的 IP 地址"127.0.0.1"
merchantIdstring订单所属商户 ID"M000001"
payLinkIdstring支付链接 ID"L549641839"
productsstring当前订单所购买的产品信息
customerstring客户、付款人、买家信息
beneficiarystring受益人信息
logisticsstring境内物流信息
overseasLogisticsstring境外物流信息
deliveryStatusstring投递状态:
pending:未发货
shipping:海外已发货
domesticInStock:境内待发货
contacting:联系中
delivering:投递中
delivered:已签收
"pending"
afterSaleStatusstring售后状态:
none:无
applying:申请售后
returning:退货中
returned:退货完成
"none"
clientPayerInfostring客户端信息
statusstring订单状态:
pending:商家创建订单
paid:用户已支付
closed:订单关闭, 超时的订单会自动关闭
expired:订单过期
"pending"
complainStatusstring订单投诉状态:
normal:正常订单
complained:投诉订单
"normal"
ticketstring订单支付操作票据,引导付款人进行付款时,URL 必须包含此参数"Q6XU......Aw89"
namestring订单描述信息,商户创建订单时提交的参数"购买面值 100 的游戏充值卡"
merchantOrderIdstring商户支付订单 ID"2022102218233400123"
notificationURLstring订单支付成功通知地址
needTaxboolean是否需要缴纳税费false
exchangeRatestring汇率"15"
currencystring货币类型货币种类,三位大写字母"SAR"
"KWD"
"BHD"
"AED"
"OMR"
"QAR"
paidAtstring支付时间
closedAtstring订单关闭时间
expiredAtstring订单过期时间,过期后订单不可以继续支付,建议设置为 30 分钟后,默认为 30 分钟"2022-10-23T12:00:21.000Z"
messagestring系统信息
payerInfostring付款人信息
payLinkstring付款链接信息
refundStatusstring退款状态:
none:无退款
fail:退款失败
processing:退款处理中
partial:部分退款
full:全部退款
"none"
refundTimesnumber发生退款的次数0
invoiceIdstring发票 ID
successPaymentCardBrandstring支付成功的卡类型
successPaymentMethodstring支付成功的付款方式"stcpay"
createdAtstring订单创建时间"2022-10-22T12:00:21.000Z"
updatedAtstring更新时间"2022-12-31T12:53:17.000Z"

响应参数示例

json
{
  "amount": 12.02, // 订单金额
  "tip": 0.02, // 订单小费
  "taxAmount": 0, // 税费
  "refundAmount": 0, // 退款金额
  "id": "M448726T2022123112531745487632", // 支付订单ID
  "clientId": "CLT9208307", // 客户端 ID  
  "clientIp": "127.0.0.1", // 客户下单时的 IP 地址
  "merchantId": "M448726", // 商户ID
  "payLinkId": "L298791901", // 支付链接ID
  "products": "[{\"name\":\"Slip On Classic Beige\",\"type\":\"unknown\",\"quantity\":1,\"price\":\"12.02\",\"sku\":\"xxxx-xxxx-xx\",\"productId\":\"160603886211111111111\",\"amount\":\"12.02\",\"avatar\":\"https://xxx\",\"location\":\"SA\"}]", // 当前订单所购买的产品信息
  "customer": "{\"nickname\":\"customerName\",\"email\":\"info@gmail.com\",\"mobile\":\"900000000\",\"address\":\"Tabuk,Umluj,Al Balad,1022 9th Avenue\"}", // 客户、付款人、买家信息
  "beneficiary": "{\"platform\":\"PUBG\",\"info\":\"ACCOUNT123_UID12345\"}", // 受益人信息
  "logistics": "{\"trackingURL\":\"https://xxx\",\"trackingNumber\":\"TEST123345234\"}", // 境内物流信息
  "overseasLogistics": "{\"trackingURL\":\"https://xxx\",\"trackingNumber\":\"TEST12678567\"}", // 境外物流信息
  "deliveryStatus": "pending", // 投递状态
  "afterSaleStatus": "none", // 缴纳状态
  "clientPayerInfo":"{\"method\":\"M424843T2024010210344240829304\",\"clientTime\":\"2024-01-02T07:34:26.867Z\",\"language\":\"en\",\"outerWidth\":1425,\"outerHeight\":1124,\"innerWidth\":1401,\"innerHeight\":1033,\"clientWidth\":1401,\"clientHeight\":1033,\"availWidth\":2560,\"availHeight\":1400,\"screenWidth\":2560,\"screenHeight\":1440,\"url\":\"https:\/\/gccpay.lishaopeng.cn\/en-US\/order\/M424843T2024010210344240829304?ticket=rClF4FL2C7Bps7jllRhsPhAkIrkv73xd5sTPM6rFWeMeJPrMjX1o7c0v1GP98Wop\",\"userAgent\":\"Mozilla\/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit\/537.36 (KHTML, like Gecko) Chrome\/120.0.0.0 Safari\/537.36 Edg\/120.0.0.0\",\"clientIp\":\"114.93.215.105\",\"activedAt\":\"2024-01-02T07:34:42.604Z\"}",
  "status": "pending", // 订单状态
  "complainStatus": "complainStatus", // 订单投诉状态
  "ticket": "QnTkb04gg5RzB6fPKlfKH9AJgTW7PYQKCYnP0Wwdz0uiQZjSt8UjsHtBJbBBmTMc", // 票据凭证,用于验证订单ID
  "name": "Order test for desc", // 订单描述
  "merchantOrderId": "TEST1672491207", // 商户端订单ID
  "notificationURL": null, // 回调地址
  "needTax": false, // 是否需要缴纳税费
  "exchangeRate": null, // 汇率
  "currency": "SAR", // 支付币种
  "paidAt": "None", // 支付时间
  "closedAt": null, // 订单关闭时间
  "expiredAt": "2023-01-15T20:53:27.000Z", // 过期时间
  "message": null,
  "payerInfo": "{\"name\":\"alfa\",\"phone\":\"19884636245\",\"address\":\"alfa\",\"email\":\"alfall@qq.com\"}", // 付款人信息
  "payLink": "{\"amount\":10,\"tipOptions\":[1,2,3],\"id\":\"L296776508\",\"name\":null,\"clientId\":\"CLT7740145\",\"amountType\":\"fixed\",\"currency\":\"SAR\",\"needContact\":true,\"includeAddress\":true,\"needTip\":true,\"tipRequired\":false,\"tipType\":\"percent\",\"creatorId\":\"U643029\",\"createdAt\":\"2023-03-01T14:14:00.000Z\",\"updatedAt\":\"2023-03-01T14:14:00.000Z\"}", // 支付链接信息
  "refundStatus": "none", // 退款状态
  "refundTimes": 0, // 发生退款的次数
  "invoiceId": null, // 发票ID
  "successPaymentCardBrand":null, // 成功支付卡类型
  "successPaymentMethod":null, // 成功支付方式
  "createdAt":"2024-01-02T07:34:42.000Z",
  "updatedAt":"2024-01-03T07:39:42.000Z"
}