Refund
Refund batch services allow merchants to refund a batch of payments using SFTP connection.
Connect using SFTP
- IP Address : 52.76.184.174
- Port : 22
- Username : The merchant must fill in the SFTP setup form and send the request to support team. An account will be created for merchant to access 2c2p SFTP in demo and production environment.
- Request Path : /input
- Response Path : /output
- Pickup Time For Request File : Everyday 2.00AM GMT+7
- Drop Time For Response File : Everyday Before 3.00AM GMT+7
File Format Specification
- File name format : refund_YYYYMMDD_fileName.csv
- Parameter delimiter : semicolon ';'
- Record delimiter : line break
- Encryption Method : None
How to integrate
- Merchants must prepare the refund request file. Refer to Refund Request.
- Upload the refund request file into the SFTP Server.
- 2C2P will pick up the refund request file and process the payment.
- 2C2P will drop the refund response file in the SFTP Server.
- Merchants must get the refund response file from SFTP Server.
- Merchants read the response data as payment acknowledgement. Refer to Refund Response.
Data Attribute Reference
Data Type
- A: Alphabet
- AN: Alphanumeric
- C: Characters
- B: Boolean
- D: Decimal
- N: Numeric
Mandatory attributes
- M: Mandatory
- C: Conditional
- O: Optional
Refund Request
Header Parameters
H;1.1;JT;[email protected];2015-01-01 00:00:01;2015-01-01 00:00:02;2
Parameter | Data Type | Mandatory | Description |
---|---|---|---|
recordType | C 1 | M | Header = H |
version | C 5 | M | Current version is 1.1 |
merchantID | C 25 | M | Merchant ID provided by 2C2P |
requestorID | C 50 | M | Merchant User Login ID |
createDateTime | C 19 | M | YYYY-MM-DD HH:mm:ss (24 hours format) |
processDateTime | C 19 | M | yyyy-MM-dd HH:mm:ss (24 hours format) |
totalRecord | N 5 | M | Total number of transactions |
Detail Parameters
D;1;Test120116161653531;000000000005;test for refund upload (SGD)
D;2;Test120116160448782;000000000010;
Parameter | Data type | Mandatory | Description |
---|---|---|---|
recordType | C 1 | M | Details = D |
recordNo | N 5 | M | running no 1 - 99999 |
transactionInvoiceNo | C 50 | M | Invoice number |
refundAmount | N 12 | M | Note: The refund amount will be padded with ‘0’ from the left and include no decimal point Examples: 1.00 = 000000000100 1.50 = 000000000150 |
note | C 250 | O | Refund note |
Refund Response
Header Parameters
H;1.1;JT;[email protected];2015-01-02 00:00:02;4
Parameter | Data type | Mandatory | Description |
---|---|---|---|
recordType | C 1 | M | Header = H |
version | C 5 | M | Current version 1.1 |
merchantID | C 15 | M | Merchant ID provided by 2C2P |
requestorID | C 50 | M | Merchant User Login ID |
completeDateTime | C 19 | M | YYYY-MM-DD hh:mm:ss |
totalRecords | N 5 | M | Total number of transactions |
Detail Parameters
D;1;123,Test120116161653531;000000000005;test for refund upload (SGD);00;Success
Parameter | Data type | Mandatory | Description |
---|---|---|---|
recordType | C 1 | M | Details = D |
recordNo | N 5 | M | running no 1 - 99999 |
tranRef | C 28 | M | Routing trace reference number |
transactionInvoiceNo | C 50 | M | Invoice number |
refundAmount | N 12 | M | Note: The refund amount will be padded with ‘0’ from the left and include no decimal point Examples: 1.00 = 000000000100 1.50 = 000000000150 |
note | C 250 | M | Refund note |
respCode | N 2 | M | 00 = success * Other response codes represent failure; please check the response code list below for specific failure details |
respDesc | C 100 | M | Response description |
Response Code List
respCode | respDesc |
---|---|
00 | Success |
01 | Mandatory field is not completed |
02 | Invalid transactionInvoiceNo or Invoice number is blank |
03 | Refund amount is not correct format |
04 | invalid transaction status |
05 | Invalid transaction |
06 | Refund rejected or Total refund amount is more than transaction amount. or Cannot retrieve main transaction. Refund failed. |
07 | Insufficient balance. |
08 | Refund amount is over merchant amount. |
09 | Data field length is not matched |
89 | Database error |
99 | System error |
Updated 8 months ago