Scan2Pay
  • Scan2Pay API
  • API Introduction
    • API Environment
    • API Security
    • API Request Format
    • API Response Format
    • SDK
  • API Specification
    • Merchant-Presented QR Code
    • Customer-Presented QR Code
    • Credit Card Payment
    • EasyCard Manipulation
      • Obtain the device list
      • Sign on
      • Query the card number
      • Query the balance
      • Payment
      • Refund
      • Settlement
      • Payment Retry (EasyCard)
    • Refund
    • Single Transaction Query
    • Multiple Transactions Query
    • New Multiple Transactions Query
    • Invoice Query
  • Payment Notification
  • Appendix
    • Payment Method Code
    • Transaction Status Code
    • EasyCard Transaction Status Code
    • Printing Information for EasyCard Transaction
    • Card Reader Setup
Powered by GitBook
On this page
  • Request
  • Header
  • Data
  • Response
  • Header
  • Data
  • API Example
  • Request
  • Response

Was this helpful?

  1. API Specification

Refund

Full refund of the transaction

Partial refund is not available.

Request

Header

Item

Mandatory

Data Type

Sample

Description

Method

YES

String(5)

00000

Fill in 00000 (indefinite payment method)

ServiceType

YES

String(32)

Refund

Selected Scan2Pay Service type

MchId

YES

String(32)

Account0001

Merchant ID provided by intella

TradeKey

YES

String(128)

sha256...hash

Marchant password provided by intella, this password must be encoded by SHA256

CreateTime

YES

String(14)

20180101120000

Request time, the format is "yyyyMMddHHmmss"

Data

Item

Mandatory

Data Type

Sample

Description

StoreRefundNo

YES

String(20)

RF180101001

Refund number, composition shall be an alphanumeric string and no more than 20 characters

StoreOrderNo

YES

String(20)

PO180101001

Original order number

DeviceInfo

YES

String(32)

skb0001

Terminal number is fixed as skb0001

StoreInfo

NO

String(16)

00001

Store ID

Cashier

NO

String(8)

王小明

Cashier

RefundKey

YES

String(32)

sha256...hash

Marchant password provided by intella, this password must be encoded by SHA256

RefundFee

YES

Integer

100

To match the amount of original order, partial refund is not available

RefundedMsg

YES

String

Product Malfunction

Description of purchase refund

Response

Header

Item

Data Type

Sample

Description

StatusCode

String(4)

0000

StatusDesc

String

Success

Description of transaction status

Method

String(5)

10100

Payment method code

ServiceType

String

Refund

Selected Scan2Pay Service type

MchId

String

Account0001

Merchant ID

ResponseTime

String

20180101120000

Transaction response time, the format is "yyyyMMddHHmmss"

Data

Item

Data Type

Sample

Description

SysRefundNo

String(64)

2018010112000005610

System refund number

StoreRefundNo

String(20)

RF180101001

Store refund number

StoreOrderNo

String(20)

PO180101001

Store order number

API Example

Request

{
  "Header": {
    "Method": "00000",
    "ServiceType": "Refund",
    "MchId": "myMchId",
    "TradeKey": "9af15b336e6a9619928537df30b2e6a2376569fcf9d7e773eccede65606529a0",
    "CreateTime": "20180715102813"
  },
  "Data": "{\"DeviceInfo\":\"skb0001\",\"StoreOrderNo\":\"PO-20180715-001\",\"StoreRefundNo\":\"PO-20180715-001\",\"RefundKey\":\"9af15b336e6a9619928537df30b2e6a2376569fcf9d7e773eccede65606529a0\",\"RefundFee\":\"1\",\"RefundedMsg\":\"Broken\"}"
}

Response

{
  "Header": {
    "StatusCode": "0000",
    "StatusDesc": "執行成功",
    "Method": "11500",
    "ServiceType": "Refund",
    "MchId": "myMchId",
    "ResponseTime": "20180715102816"
  },
  "Data": {
    "SysOrderNo": "2018071544571196210",
    "SysRefundNo": "2018071544571328811",
    "StoreOrderNo": "PO-20180715-001",
    "StoreRefundNo": "PO-20180715-001",
    "RefundedAt": "20180715102816",
    "PlatformRsp": "{\"returnCode\":\"0000\",\"returnMessage\":\"Success.\",\"info\":{\"refundTransactionId\":2018071544571328811,\"refundTransactionDate\":\"2018-07-15T02:28:15Z\"}}"
  }
}
PreviousPayment Retry (EasyCard)NextSingle Transaction Query

Last updated 6 years ago

Was this helpful?

Transaction Status Code