Exchange Rate With Token

👍

HTTPS POST / Server-to-Server

Sandbox endpoint : sandbox-pgw.2c2p.com/payment/4.1/exchangerate
Run test with Swagger Editor

Go live when you are ready, Live endpoint is provided.

Exchange Rate With Token API allow merchant to get forex rate with payment token.

Exchange Rate With Token Request


Below are the guidelines that how to prepare a exchange rate request and send to 2c2p

  1. Prepare and Receive Payment Token API.

  2. Prepare payload data. Below sample request data show the request structure. Refer Exchange Rate With Token Request Parameterfor API Specification.

{
    "paymentToken": "kSAops9Zwhos8hSTSeLTUcCrwcnrndJUZanGJy3fBEsXCiYmynwxHvK5h7XPBadJqD0nG7v65t5N2jPVrnwX2jL4nu+KKSegjUjERKCyWPg=",
    "clientID": "E380BEC2BFD727A4B6845133519F3AD7",
    "locale": "en",
    "bin": "411111"
}

 

Exchange Rate With Token Response


Below are the guidelines that how to process exchange rate response from 2c2p.

  1. Below are sample exchange rate with token response refer to Exchange Rate With Token Response Parameter for API Specification.
{
    "paymentToken": "kSAops9Zwhos8hSTSeLTUcCrwcnrndJUZanGJy3fBEsXCiYmynwxHvK5h7XPBadJqD0nG7v65t5N2jPVrnwX2jL4nu+KKSegjUjERKCyWPg=",
    "providerCode": "SCB",
    "expire": 1545383164989,
    "fxRates": [{
        "sequenceNo": 1,
        "id": "fx001",
        "name": "SGD",
        "iconUrl": "https://img.2c2p.com/pgw/fx/flag_sg.png",
        "amount": "1500.00",
        "fx": 1.0,
        "currencyCode": "SGD"
    }, {
        "sequenceNo": 2,
        "id": "fx002",
        "name": "THB",
        "iconUrl": "https://img.2c2p.com/pgw/fx/flag_th.png",
        "amount": "2450.00",
        "fx": 24.50,
        "currencyCode": "THB"
    }],
    "respCode": "0000",
    "respDesc": "success"
}