PAYON Payment Gateway
  • Table of Contents
  • Revision History
  • How is Work
    • PAYON PG PAYMENT
      • PAYON's Wallet Payment via PAYON Mobile App
      • PAYON Payment via PAYON's Card
      • CREDIT/DEBIT Online Payment
      • PPCBank Mobile Pay via PPCBank Mobile App(Coming Soon)
      • KHQR Online Payment
      • Binding Payment via PAYON's Card
      • Binding Payment via Credit/Debit's Card
  • PayOn PG Overview
    • Desktop Views
      • PAYON Payment Method
        • PAYON Card Payment
        • PAYON QR Payment
      • Credit/Debit Payment
      • KHQR Payment
      • PPCBank Payment
    • Mobile Views
      • PAYON Payment Method
      • Credit/Debit Payment Method
      • KHQR Payment
        • Bakong APP
        • PPCBank App
        • Other Bank App
      • PPCBank Payment
    • Obtain your API Keys
    • Platform Application Settings
  • Work flows
    • Payment Request Workflow
    • Page Redirection Workflow
  • Getting Started
    • Generate Checkout Link
    • Try redirect to Checkout Link
    • Test your payment
    • Add Card(Create Binding)
  • PAYON API Reference
    • Payment Order Registration
    • Cancellation Payment
    • Pre Auth Completion Payment
    • Refunds Payment
    • Transaction Orders History
    • Get Transaction Status
    • Push Back Notification
    • Create Binding
    • Get Binding List
    • Create Binding PIN
    • Enable / Disable PIN
    • Merchant Reconciliation
  • TEST Cards and Accounts
    • Test Card&Account
  • PAYON Library
  • PayOn Library
    • How to use PayOn Library
    • How to encrypt data with RSA
  • PAYON APPS
    • Environments
  • 3RD PARTY APPS
    • PPCBANK Environment
    • Bakong Environment
Powered by GitBook
On this page
  • Respond Code
  • Example Request

Was this helpful?

  1. PAYON API Reference

Merchant Reconciliation

This endpoint is uses for reconciliation request between merchant and PAYON Aggregator.

Environment
URL

TEST

PRODUCTION

POST {{URL}}/pg/merchant/reconcilation

Request Body

Name
Type
Description

termId*

String

Terminal's Identification

merchantId*

String

Merchant's Identification

buyerId

String

Customer's Identification

sellerId

String

Customer's Identification

txId*

String

Transaction's Identification

grandToTAmt*

Grand total amount, including Fee

transactionType*

String

Transaction's Type, Possible value are PURCHASE,

REFUND,

PRE_AUTH,

PRE_AUTH_COMPLETE, PURCHASE_REVERSAL, PRE_AUTH_REVERSAL,

PRE_AUTH_COMPLETE_REVERSAL

[
    {
        "merchantId": "O0000021",
        "reconciliationDv": "APPROVED",
        "termId": "OW04000007",
        "txId": "1652858955940000",
        "buyerId": "becbd0f6-39b7-4b81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "grandToTAmt": 2.3,
        "resultMsg": "Success",
        "resultCode": "0000"
    },
    {
        "merchantId": "O0000021",
        "reconciliationDv": "APPROVED",
        "termId": "OW04000007",
        "txId": "1652886005159000",
        "buyerId": "becbd0f6-39b7-4b81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "grandToTAmt": 2.3,
        "resultMsg": "Success",
        "resultCode": "0000"
    }
]
[
    {
        "merchantId": "O0000021",
        "reconciliationDv": "REJECTED",
        "termId": "OW04000007",
        "txId": "1652858955940000",
        "buyerId": "becbd0f6-39b7-4b81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "grandToTAmt": 2.3,
        "resultMsg": "Invalid CUSTOMER ID",
        "resultCode": "0006"
    },
    {
        "merchantId": "O0000021",
        "reconciliationDv": "REJECTED",
        "termId": "OW04000007",
        "txId": "1652886005159000",
        "buyerId": "becbd0f6-39b7-4b81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "grandToTAmt": 2.3,
        "resultMsg": "Invalid CUSTOMER ID",
        "resultCode": "0006"
    }
]

Respond Code

ResultCode
ResultMsg
Description

0000

Success

Reconciliation's Success

9999

System Error

Reconciliation's Not Success

0001

Invalid Merchant ID

Reconciliation's Not Success - Invalid Merchant ID

0002

Invalid Term ID

Reconciliation's Not Success - Invalid Term ID

3003

Invalid Transaction

Reconciliation's Not Success - Invalid Transaction

0006

Invalid Customer ID

Reconciliation's Not Success - Invalid customer ID

Example Request

curl --location -g --request POST '{{url}}:{{pg_port}}/pg/merchant/reconcilation' \
--data-raw '[
    {
        "termId": "OW04000007",
        "merchantId": "O0000021",
        "buyerId": "becbd0f6-39b7-4db81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "txId": "1652858955940000",
        "transactionType": "PURCHASE",
        "grandToTAmt": 2.3
    },{
        "termId": "OW04000007",
        "merchantId": "O0000021",
        "buyerId": "becbd0f6-39b7-4bd81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "txId": "1652886005159000",
        "transactionType": "PURCHASE",
        "grandToTAmt": 2.3
    }
]'
POST /pg/merchant/reconcilation HTTP/1.1
Host: {{url}}:{{pg_port}}
Content-Length: 521

[
    {
        "termId": "OW04000007",
        "merchantId": "O0000021",
        "buyerId": "becbd0f6-39b7-4db81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "txId": "1652858955940000",
        "transactionType": "PURCHASE",
        "grandToTAmt": 2.3
    },{
        "termId": "OW04000007",
        "merchantId": "O0000021",
        "buyerId": "becbd0f6-39b7-4bd81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "txId": "1652886005159000",
        "transactionType": "PURCHASE",
        "grandToTAmt": 2.3
    }
]
var settings = {
  "url": "{{url}}:{{pg_port}}/pg/merchant/reconcilation",
  "method": "POST",
  "timeout": 0,
  "data": "[\n    {\n        \"termId\": \"OW04000007\",\n        \"merchantId\": \"O0000021\",\n        \"buyerId\": \"becbd0f6-39b7-4db81-ba36-6c374ae8eaee\",\n        \"sellerId\": \"5f31c1ec-97ff-4940-b5ad-5d6b79eba748\",\n        \"txId\": \"1652858955940000\",\n        \"grandToTAmt\": 2.3\n    },{\n        \"termId\": \"OW04000007\",\n        \"merchantId\": \"O0000021\",\n        \"buyerId\": \"becbd0f6-39b7-4bd81-ba36-6c374ae8eaee\",\n        \"sellerId\": \"5f31c1ec-97ff-4940-b5ad-5d6b79eba748\",\n        \"txId\": \"1652886005159000\",\n        \"grandToTAmt\": 2.3\n    }\n]",
};

$.ajax(settings).done(function (response) {
  console.log(response);
});a
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => '{{url}}:{{pg_port}}/pg/merchant/reconcilation',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'[
    {
        "termId": "OW04000007",
        "merchantId": "O0000021",
        "buyerId": "becbd0f6-39b7-4db81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "transactionType": "PURCHASE",
        "txId": "1652858955940000",
        "grandToTAmt": 2.3
    },{
        "termId": "OW04000007",
        "merchantId": "O0000021",
        "buyerId": "becbd0f6-39b7-4bd81-ba36-6c374ae8eaee",
        "sellerId": "5f31c1ec-97ff-4940-b5ad-5d6b79eba748",
        "transactionType": "PURCHASE",
        "txId": "1652886005159000",
        "grandToTAmt": 2.3
    }
]',
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
PreviousEnable / Disable PINNextTest Card&Account

Last updated 2 years ago

Was this helpful?

http://pgtest.payon.com.kh
https://pg.payon.com.kh