1. Introduction

QLink Payment Integration Standard Document

2. Environmental Requirements and Basic Agreements

Authorization:Contact QLink to obtain the appKey and appSecret(secret key for verifying message information)。

Interface address:

test:http://open-test1.800best.com/open-platform-api/pay

prod:http://open-prod.800best.com/open-platform-api/pay

Request method:

  • Method: POST
  • Content-Type: application/json

headerParams:

Field DataType Require Description
appKey String Y
sign String Y sign

Base Response:

Field DataType Require Description
success boolean Y Whether the business processing was successful
message String N Business processing exception message

Signature method:

  1. Combine appKey and content into a JSON string {"appKey":"appKey","content":"Specific business Params"}, and when content is empty, {"appKey":"appKey"}
  2. Append the customer appSecret assigned by the third party to the end of the JSON to obtain the string to be encrypted {"appKey":"appKey","content":"Specific business Params"}appSecret.
  3. Perform SHA1 encryption on the string to be encrypted (org.apache.commons.codec.digest.DigestUtils.sha1Hex(string to be encrypted))
  4. Assign the signature to the sign field of the common request

3. Query Payment Account

uri:

  • /queryPayAccount

Interface Params:

Field Field Description DataType Require Description
payAccount Payment Account String Y

Return Example:

Field Field Description DataType Require Description
serviceProvider Payment Service Provider String Y
type DataType String Y PAY_TYPE、PAY_CHANNEL
code code String Y
name name String Y

Request Example: { "payAccount": "account1" }

Return Example:

[ { "code": "ONLINE", "name": "在线支付", "type": "PAY_TYPE" }, { "code": "QR_CODE_PAYMENT", "name": "二维码扫描支付", "type": "PAY_TYPE" }, { "code": "QRIS", "name": "支付渠道", "type": "PAY_CHANNEL" } ]

4. payment application

uri:

  • /apply

Interface Params:

Field Field Description DataType Require Description
payAccount 支付账号 String Y
payTypeCode 支付方式 String Y
payChannelCode 支付渠道 String Y
tradeUuid request uuid String Y The appKey must be unique.
tradeTime 请求交易时间 Date Y
orderCode order code String Y
country 国家二字码 String Y Two-letter country code
currency 三个字母的货币代码 String Y Three-letter currency code
amount 金额 String Y
description 描述 String N
metadata 自定义数据 String N 例:{ "my_custom_id": "merchant-123", "my_custom_order_id": "order-123" }
items 描述 Array N
└ skuCode 商品编码 String Y
└ skuName 商品名称 String Y
└ quantity 数量 number Y
└ url 商品连接 String N
└ imageUrl 图片连接 String N
└ category 商品类目 String N
└ subcategory 商品子类目 String N
└ description 描述 String N
└ metadata 自定义数据 String N

Return Example:

Field Field Description DataType Require Description
billCode pay bill code String Y
paymentRequestId service provider unique Payment Request ID String N
actionValue The specific value that will be used by merchant to complete the action String N
errorCode String N

Request Example:

{ "glinkAccount": "account1", "payTypeCode": "ONLINE", "payChannelCode": "QRIS", "tradeUuid": "uuid", "tradeTime": "2025-08-04 13:45:21", "orderCode": "O20250804001", "country": "ID", "currency": "IDR", "amount": "1.1", "description": "描述", "metadata": "", "items": [ { "skuCode": "SKU01", "skuName": "商品01", "quantity": "1", "url": "http://", "imageUrl": "http://", "category": "", "subcategory": "", "description": "", "metadata": "" } ] }

Return Example:

{ "billCode": "账单号", "actionValue": "商家完成操作时将使用的具体值" }

5. Query Payment Status

uri:

  • /getPayStatus

Interface Params:

Field Field Description DataType Require Description
tradeUuidList request uuid String N At least one of tradeUuidList or billCodeList must be provided
billCodeList pay bill code String N At least one of tradeUuidList or billCodeList must be provided

Return Example:

Field Field Description DataType Require Description
tradeUuid request uuid String Y
billCode pay bill code String Y
paymentRequestId service provider unique Payment Request ID String Y
orderCode order code String Y
status Payment Status String Y Payment Status Enumeration
payTime Payment Time Date N Required when Payment Status SUCCESS
currency Three-letter currency code Date N Three-letter currency code
errorCode Date N

Request Example:

{ "tradeUuidList": ["uuid1"], "billCodeList": ["billCode1"] }

Return Example:

{ "tradeUuid": "uuid1", "billCode": "billCode1", "paymentRequestId": "paymentRequestId", "orderCode": "O20250804001", "status": "WAIT", "payTime": "2025-08-04 13:45:21", "currency": "IDR", "errorCode": "" }

6. Cancel Payment

uri:

  • /cancel

Interface Params:

Field Field Description DataType Require Description
tradeUuid request uuid String N At least one of tradeUuid or billCode must be provided
billCode pay bill code String N At least one of tradeUuid or billCode must be provided

Return Example:

Field Field Description DataType Require Description
status Cancellation Status String Y Pay Cancel status enum
cancelTime Cancellation TIme Date N
errorCode Cancellation TIme String N

Request Example:

{ "tradeUuid": "uuid1", "billCode": "billCode1" }

Return Example:

{ "status": "WAIT", "cancelTime": "", "errorCode": "" }

7. Webhook

8. Payment Status Notification

uri:

  • /payNotification

Interface Params:

Field Field Description DataType Require Description
tradeUuid request uuid String Y unique
billCode pay bill code String Y
orderCode order code String Y
paymentRequestId service provider unique Payment Request ID String Y
status Payment Status String Y Pay status enum
payTime Payment Time Date N Required when payment status is SUCCESS
errorCode String N Required payment status is FAIL

Request Example:

{ "tradeUuid": "uuid1", "billCode": "billCode1", "orderCode": "O20250804001", "paymentRequestId": "O20250804001", "status": "WAIT", "payTime": "", "errorCode": "" }

© Copyright QianYi Team 2025 All Rights Reserved            Updated 2025-08-13 07:32:45

results matching ""

    No results matching ""