GALAXY PAY - API Reference Guide
  • Payment Gateway
    • Payment solution
      • General integration steps
      • Modal checkout
        • Integration Guide for Web Desktop & Mobile Browser
      • Merchant checkout
      • Merchant Hosted Checkout
      • Pay with option
      • Pay with token
      • Fast pay
      • Pay with QR
      • Pay with E-Wallet
    • Demo
    • API Specification
      • Integration Keys
      • Definitions
        • Message Structure
        • Signature Algorithm
      • Data Flight
      • PAYMENT
        • Pay
        • Pay with create token
        • Pay with token
        • Pay with Option
        • Pay with QR
        • Checkout(for modal checkout)
        • Payment Link
        • Fast pay
      • TOKENIZATION
        • Merchants
          • Delete Token
        • Customers
          • Query Tokens
          • Remove Token
      • MANAGEMENT
        • Query Transaction
        • Refund Transaction
        • Void Transaction
        • Capture Transaction
      • IPN & CALLBACK
        • Result & IPN Callback
        • Cancel Callback
    • Appendix
      • Response Codes
      • Currencies
      • Domestic Banks
      • International Card Brands
      • eWallets
      • Payment Hubs
        • Apple Pay Validation
      • QR Payment Providers
      • Buy Now Pay Later
      • Test Information
      • Glossary
  • Payment Link
    • IPN callback
  • Archive
    • QR Payment (Old version)
      • API create QR
      • API query status
      • How to test
    • API create PaymentLink
Powered by GitBook
On this page
  1. Payment Gateway
  2. API Specification
  3. IPN & CALLBACK

Result & IPN Callback

  • Result URL: Use for Merchant to show result for Customer. Support http method POST or GET

  • IPN URL: Use for Merchant to receive payment result and process business workflow.

Note:

Response Signature is create by applying hash algorithm SHA256 the response data with Salt.

signature = SHA256(data + salt)

Body

Level
Field Name
Data Type
Description

1

data

Alphanumeric mandatory

Base-64 string

1

signature

Alphanumeric mandatory

Response Signature signature = SHA256(data + Salt)

Data (Decode Base-64 String)

Level
Field Name
Data Type
Description

1

requestID

Alphanumeric(50) mandatory

Original Request ID

1

responseDateTime

Numeric(14) mandatory

yyyyMMddHHmmss

1

responseCode

Numeric(3) mandatory

1

responseMessage

Alphanumeric(250) mandatory

Response message

1

responseData

JSON Object mandatory

Response data

2

transactionID

Alphanumeric(38) mandatory

GALAXY PAY transaction ID

2

transactionStatus

Numeric(14) optional

2

transactionDescription

Alphanumeric(20) optiona

Only available in apiVersion 2

2

paymentMethod

Alpha(20) optional

2

sourceType

Alphanumeric(20) optional

2

orderID

Alphanumeric(50) mandatory

Transaction ID at Merchant

2

orderNumber

Alphanumeric(20) optional

Order Number or Bill Number

2

orderAmount

Numeric(16) mandatory

Order Amount

2

orderCurrency

Alpha(3) mandatory

Order Currency

2

orderDateTime

Numeric(14) mandatory

Order Date Time

yyyyMMddHHmmss

2

orderDescription

Alphanumeric(250) mandatory

Order Description

2

language

Alpha(2) mandatory

vi or en

vi: Vietnamese

en: English

2

tokenization

JSON Object optional

Only Return on IPN callback when

· Transaction is successful (ResponseCode = 200)

· APIOperation = PAY_WITH_CREATE_TOKEN

3

accountBrand

Alphanumeric(50) optional

Card Brand info

3

accountSource

Alphanumeric(50) optional

Card Issuer info

3

accountNumber

Alphanumeric(50) optional

Card Masked Number

3

accountName

Alphanumeric(50) optional

Cardholder name

3

token

Alphanumeric(50) optional

Card Token

3

status

Alphanumeric(3) mandatory

Token Creation Result

3

message

Alphanumeric(250) mandatory

Token Creation Message

RESPONSE DATA

{
  "data": "eyJyZXF1ZXN0SUQiOiIxNDY1M2ZhMS0yZjY5LTRmNGYtOWQ0Yi0yNDBlMWJlYmJkZjMiLCJyZXNwb25zZURhdGVUaW1lIjoiMjAyMjA1MDYxMTM1MTciLCJyZXNwb25zZUNvZGUiOiIyMDAiLCJyZXNwb25zZU1lc3NhZ2UiOiJUcmFuc2FjdGlvbiBpcyBzdWNjZXNzZnVsLiIsInJlc3BvbnNlRGF0YSI6eyJ0cmFuc2FjdGlvbklEIjoiMjIwNTA2OTllNjVkOWE3MWQ1NDhlNmI2NzMyM2FlZjFhNDk0YWMiLCJ0cmFuc2FjdGlvbkRhdGVUaW1lIjoiMjAyMjA0MDUyMDIwMDAiLCJvcmRlcklEIjoiODg4Mjg5Iiwib3JkZXJOdW1iZXIiOiI4MjI2Mjg4OSIsIm9yZGVyQW1vdW50IjoiMTA5MDAwIiwib3JkZXJEZXNjcmlwdGlvbiI6IlNlY3VyZSBQYWdlIERlbW8iLCJvcmRlckN1cnJlbmN5IjoiVk5EIiwib3JkZXJEYXRlVGltZSI6IjIwMjIwNDA1MjAyMDAwIiwibGFuZ3VhZ2UiOiJ2aSJ9fQ==",
  "signature": "724c1f76663cc0b119080e0b53eaae06615dd8586e34c15b3e96e61d6d729dcc"
}


VERIFY SIGNATURE

const data = "eyJyZXF1ZXN0SUQiOiIxNDY1M2ZhMS0yZjY5LTRmNGYtOWQ0Yi0yNDBlMWJlYmJkZjMiLCJyZXNwb25zZURhdGVUaW1lIjoiMjAyMjA1MDYxMTM1MTciLCJyZXNwb25zZUNvZGUiOiIyMDAiLCJyZXNwb25zZU1lc3NhZ2UiOiJUcmFuc2FjdGlvbiBpcyBzdWNjZXNzZnVsLiIsInJlc3BvbnNlRGF0YSI6eyJ0cmFuc2FjdGlvbklEIjoiMjIwNTA2OTllNjVkOWE3MWQ1NDhlNmI2NzMyM2FlZjFhNDk0YWMiLCJ0cmFuc2FjdGlvbkRhdGVUaW1lIjoiMjAyMjA0MDUyMDIwMDAiLCJvcmRlcklEIjoiODg4Mjg5Iiwib3JkZXJOdW1iZXIiOiI4MjI2Mjg4OSIsIm9yZGVyQW1vdW50IjoiMTA5MDAwIiwib3JkZXJEZXNjcmlwdGlvbiI6IlNlY3VyZSBQYWdlIERlbW8iLCJvcmRlckN1cnJlbmN5IjoiVk5EIiwib3JkZXJEYXRlVGltZSI6IjIwMjIwNDA1MjAyMDAwIiwibGFuZ3VhZ2UiOiJ2aSJ9fQ==";
const salt = "GO@2021";
const signature = SHA256(data + salt);


DECODE BASE-64 STRING FOR DATA

{
  "requestID": "14653fa1-2f69-4f4f-9d4b-240e1bebbdf3",
  "responseDateTime": "20220506113517",
  "responseCode": "200",
  "responseMessage": "Transaction is successful.",
  "responseData": {
    "transactionID": "22050699e65d9a71d548e6b67323aef1a494ac",
    "transactionDateTime": "20220405202000",
    "orderID": "888289",
    "orderNumber": "82262889",
    "orderAmount": "109000",
    "orderDescription": "Secure Page Demo",
    "orderCurrency": "VND",
    "orderDateTime": "20220405202000",
    "language": "vi"
  }
}

Response Message (FOR IPN ONLY)

1

ipnStatus

Alphanumeric(50) mandatory

Response Code for IPN Request.

Accepted value:

200: Transaction Success

404: Transaction Not Found

409: Transaction Completed

1

ipnDescription

Alphanumeric(250) optional

Response Description

PreviousIPN & CALLBACKNextCancel Callback

Last updated 7 months ago

See for more detail

Only available in apiVersion 2 See for more detail

Only available in apiVersion 2 See for more detail

Only available in apiVersion 2 See for more detail

Response Codes
Response Codes
Payment Method
Payment Method