Authorization (Offline)

๐Ÿ‘

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 6.00AM GMT+7 (next day)

๐Ÿšง

File Format Specification

  • File name format : offlineauth_YYYYMMDD_fileName.csv
  • Parameter delimiter : semicolon ';'
  • Record delimiter : line break
  • Encryption Method : GPG

How to integrate


  1. Merchants must prepare the auth request file. Refer to Authorization Request.
  2. Encrypt the auth request file using GPG.
  3. Upload the encrypted auth request file to the SFTP Server.
  4. 2C2P will pick up the auth request file and process the payment.
  5. 2C2P will drop an encrypted auth response file in SFTP Server.
  6. Merchants must get the encrypted auth response file from SFTP Server.
  7. Decrypt the auth response file using GPG.
  8. Read the response data as payment acknowledgement. Refer to Authorization 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

Authorization Request


Header Parameters

H;1.0;0000001;2015-01-01 00:00:01;2015-01-01 00:00:02;2
ParameterData TypeMandatoryDescription
recordTypeC 1MHeader = H
versionN 5MCurrent version is 1.0
merchantIDC 15MMerchant ID provided by 2C2P
createDateTimeC 19MYYYY-MM-DD HH:mm:ss (24 hours format)
processDateTimeC 19MYYYY-MM-DD HH:mm:ss (24 hours format)
totalRecordN 5MTotal number of transactions

Detail Parameters

D;1;Invoice00001;1 night hotel in bali;300.00;840;4111111111111111;12;2020;;123;Joppie tjoa;[email protected];data1;data2;data3;data4;data5
D;2;Invoice00002;2 night hotel in bali;600.00;840;4111111111111111;12;2020;;123;Joppie tjoa;[email protected];;;;;

Parameter

Data Type

Mandatory

Description

recordType

C 1

M

Details = D

recordNo

N 5

M

running no 1 - 99999

uniqueTransactionCode

C 20

M

Transaction unique invoice number

  • Provided by merchant

desc

C 50

M

Payment description

amount

D 12,2

M

Transaction amount

  • Example: 12.50

currencyCode

N 3

M

Standard ISO-4217 currency codes

pan

N 16

M

Credit Card Number

  • This is optional if stored card token is used

expiryMonth

N 2

M

Credit Card Expiry Month

  • This is optional if stored card token is used

expiryYear

N 4

M

Credit Card Expiry Year

  • This is optional if stored card token is used
storeCardUniqueIDC 20OStored card token
securityCodeN 4OCVV2/CVC2/CID
cardholderNameC 50MCredit card holder name
cardholderEmailC 50OCredit card holder email address
userDefined1C 150OMerchant-defined information
userDefined2C 150OMerchant-defined information
userDefined3C 150OMerchant-defined information
userDefined4C 150OMerchant-defined information
userDefined5C 150OMerchant-defined information

Authorization Response


Header Parameters

H;1.0;0000001;2015-01-02 00:00:02;4
ParameterData TypeMandatoryDescription
recordTypeC 1MHeader = H
versionC 5MCurrent version is 1.0
merchantIDC 15MMerchant ID provided by 2C2P
completeDateTimeC 19MYYYY-MM-DD hh:mm:ss
totalRecordsN 5MTotal number of transactions

Detail Parameters

D;1;Invoice00001;ABC123456;111222;0123456789;000000030000;840;411111XXXXXX1111;;user1;user2;user3;;;00;approved

Parameter

Data Type

Mandatory

Description

recordType

C 1

M

Details = D

recordNo

N 5

M

running no 1 - 99999

uniqueTransactionCode

C 20

M

Transaction unique invoice number

  • Provided by merchant

tranRef

C 28

M

Routing trace reference number

approvalCode

C 6

M

Bank approval code

refNumber

C 15

M

Bank reference number

amt

D 12,2

M

Transaction amount

  • Example: 12.50

currencyCode

N 3

M

Standard ISO-4217 currency codes

panN 16MMasked card number
storeCardUniqueIDC 20OStored card token
userDefined1C 150MMerchant-defined information
userDefined2C 150MMerchant-defined information
userDefined3C 150MMerchant-defined information
userDefined4C 150MMerchant-defined information
userDefined5C 150MMerchant-defined information
respCodeC 2MRefer to Card Response Code.
respDescC 100MRefer to Card Response Code.