NICEPAY API
...
API Version 1 (V1)
V1 Enterprise

Credit Card - V1 Enterprise

56min

Credit Card



Transaction flow :

  1. Request onePassToken.
  2. Redirect to 3Ds / MIGS page.
  3. Customer input OTP on 3Ds page.
  4. Merchant register transaction.
  5. NICEPAY send notification.



Credit Card Flow V1 Enterprise
Credit Card Flow V1 Enterprise


Credit Card Flow:

  1. The Customer does checkout.
  2. The Customer requests checkout from Merchant.
  3. The Merchant registers checkout data.
  4. The Merchant sends response, card data based, to Customer.
  5. The Customer inputs card data.
  6. The Customer sends data card data information to Merchant.
  7. The Merchant sends request by using Regist API to NICEPAY.
  8. NICEPAY saves order detail.
  9. NICEPAY sends response to Merchant.
  10. The Merchant requests payment using Payment API to NICEPAY.
  11. NICEPAY requests 3Ds to Bank.
  12. Bank verifies the request.
  13. Bank sends 3Ds URL response to NICEPAY.
  14. NICEPAY sends authentication page to Customer.
  15. The Bank sends OTP to Customer.
  16. The Customer input OTP and send the data to Bank.
  17. Bank validates OTP.
  18. Bank sends 3Ds result to NICEPAY.
  19. NICEPAY calculates FDS.
  20. NICEPAY requests payment to Bank.
  21. Bank processes the payment.
  22. Bank sends payment response to NICEPAY.
  23. NICEPAY sends payment notification using callBackUrl and dbProcessUrl to Merchant.
  24. The Merchant receives notification.
  25. The Merchant requests status checking to NICEPAY.
  26. NICEPAY sends checking status response to Merchant.
  27. The Merchant receives final status.
  28. The Merchant sends order result to Customer.



Request Token



Merchant need to request onePassToken for each Credit Card transaction using API V1 Enterprise.

API Specifications - Request Token

API Endpoint

/nicepay/api/onePassToken.do

Request Method application/x-www-form-urlencoded

POST

Description

Request onePassToken for Credit Card Transaction.

Merchant Token

SHA256 (iMid+ referenceNo+ amt+ merchantKey)

Payment Methods

01 Credit Card



Request Parameter - Request Token

The Parameters below must be sent inside ‘jsonData’ parameter and formatted as JSON.

Token Request


Parameter

Type

Size

Description

Example Value

iMid

Required

AN

10

Merchant ID

IONPAYTEST

merchantToken

Required

AN

255

Merchant Token

f5d1a08fd497bf3f39e9a0027c0a6822109903cd95140c36db537b5977fb9652

cardNo Required

N

16

Card Number

5123450000000008

cardExpYYmm Required

N

4

Card Expiry (YYMM)

3901

cardHolderNm Required 

AN

45

Card Holder Name

John Doe

cardHolderEmail Required

ANS

100

Card Holder Email

johndoe@gmail.com

amt Required

N

12

Payment Amount

10000

referenceNo Required

ANS

40

Merchant Order Number

MerchantReferenceNumber001

instmntType

N

2

1

instmntMon

N

2

Installment Month

1



Response Parameter - Request Token

Sample JSON Response


Parameter

Type

Size

Description

resultCd

N

4

Result Code

resultMsg

AN

255

cardToken

AN

64

One Time Use Transaction Token

paymentType

N

1

CC Authorization Type

Kindly check the paymentType parameter from onePassToken.do response. This will be needed for the next step to determine whether to use 3DS or MIGS.

paymentType

Description

1

3D Secure

2

KeyIn (Proceed to Registration without 3Ds/MIGS)

3

MiGS



3Ds Request



Proceed with this API when you get paymentType = 1 from onePassToken.do response.

3Ds Steps:

  1. Send Request Parameters to 3Ds Request API.
  2. Customer will be redirect to 3Ds page.
  3. Customer input OTP.
  4. NICEPAY will send Response Parameter to callbackUrl.



API Specification - 3Ds

API Endpoint

/nicepay/api/secureVeRequest.do

Method

application/x-www-form-urlencoded

Pop Up or Redirect

Description

Request 3D page for paymentType = 1

Merchant Token

SHA256 (iMid+ referenceNo+ amt+ merchantKey)



Request Parameter - 3Ds

JSON


Parameter

Type

Size

Description

Example

country

Required

N

3

Country

360

callbackUrl

Required

ANS

200

Callback URL

http://merchant.com/callback

onePassToken Required

AN

64

One time use transaction token

c5bd0b91bcc3d21358cd004c60e54 579441c23aa8e7553b41ce3402db1113fff



Response Parameter - 3Ds

JSON


Parameter

Type

Size

Description

resultCd

N

4

Result Code

resultMsg

AN

255

referenceNo

ANS

40

Merchant Order Number

merchantToken

AN

255

Merchant Token



MiGS Request



MiGS (MasterCard Internet Gateway Service) is a service from Mastercard to refund and monitor the transaction report based on the transaction between Merchant and Customer.

Currently, NICEPAY using MPGS (Mastercard Payment Gateway Service) that the latest version of MiGS to increase the transaction security with 3Ds 2.0 feature. Although, MiGS API still used on MPGS system.

Use this API if get paymentType = 3 from onePassToken.do response .

Steps:

  1. Send Request Parameters to MIGS Request API.
  2. Customer will be redirect to MIGS page.
  3. Customer input OTP.
  4. NICEPAY will send Response Parameter to callbackUrl.



API Specifications - MiGS

API url

/nicepay/api/migsRequest.do

Request Method application/x-www-form-urlencoded

POST or Redirect

Description

Request MIGS page for paymentType = 3

Merchant Token

SHA256 (iMid+ referenceNo+ amt+ merchantKey)

Payment Methods

01 Credit Card



Request Parameter - MiGS

Sample URL Parameter MIGS Request


Parameter

Type

Size

Description

Example

instmntType

Required

N

2

1

instmntMon

N

2

Installment Month

1

referenceNo Required

ANS

40

Merchant Order Number

MerchantReferenceNumber001

cardCvv

N

3

Card CVV

100

callbackUrl Required 

ANS

200

Callback URL for result

http://merchant.com/callbackUrl

onePassToken Required 

AN

64

One Time Use Transaction Token

d12b153b3dd50b1875e64ac17288a7cd33fd5511cf01924cac2ca7f345de8f08



Response Parameter - MiGS

Sample URL Parameter MIGS Response


Parameter

Type

Size

Description

resultCd

N

4

Result Code

resultMsg

AN

255



Credit Card Payment



API Specifications - Credit Card Payment

API Endpoint

/nicepay/api/onePass.do

Request Method application/x-www-form-urlencoded

POST

Description

Register Transaction and Charge Credit Card using onePassToken

Merchant Token

SHA256 (iMid+ referenceNo+ amt+ merchantKey)

Payment Methods

01 Credit Card



Request Parameter - Credit Card Registration

Sample API Payment
Sample Java Request Credi Card


Parameter

Type

Size

Description

Example / Notes

iMid

Required

AN

2

Merchant ID

IONPAYTEST

payMethod Required

N

2

01

currency Required 

A

40

Currency

IDR

amt Required 

N

12

Goods Amount

10000

referenceNo Required

ANS

40

Merchant Order Number

MerchantReferenceNumber001

goodsNm Required 

AN

100

Goods Name

Merchant Goods 1

billingNm Required 

A

30

Billing Name

John Doe

billingPhone Required 

N

15

Billing Phone Number

08123456789

billingEmail Required

ANS

40

Billing E-Mail

john.doe@example.com

billingCity Required

N

50

Billing City

South Jakarta

billingState Required 

A

50

Billing State

DKI Jakarta

billingPostCd Required

N

10

Billing Post Number

10200

billingCountry Required

A

10

Billing Country

Indonesia

callBackUrl Required 

ANS

255

Payment Result Forward URL (On Browser)

https://www.mechant.com/callbackUrl

dbProcessUrl Required

ANS

255

Payment Result Receive URL (Server Side)

https://www.merchant.com/dbProcessUrl

description Required

AN

100

Description

This Is The Description Of The Payment

merchantToken Required 

AN

255

Merchant Token

2349fcbd3a5b81d08ca719cc6d9c826f2f6f9d4de337b86e4019114aad6222b1

userIP Required

ANS

15

User IP

127.0.0.1

cartData Required 

ANS

4000

Cart Data (JSON Format)

{}

instmntType Required 

N

2

1

instmntMon Required 

N

2

Installment Month

1

cardCvv

N

3

Card CVV

100

onePassToken Required 

AN



One Time Use Transaction Token

9338d54573688ae18e175240b0257de48d89c6ef1c9c7b5c094dc4beed9e435f

recurrOpt Required For Recurring CC 

N

2

0 : Automatic Cancel 1 : Do not cancel 2 : Do not make token

1

billingAddr

AN

255

Billing Address

Jln. Raya Kasablanka Kav.88

deliveryNm

A

30

Delivery Name

Merchant's Name

deliveryPhone

N

15

Delivery Phone

08123456789

deliveryAddr

AN

100

Delivery Address

Jln. Dr. Saharjo No.88

deliveryEmail

AN

100

Delivery E-Mail

example@merchant.com

deliveryCity

A

50

Delivery City

South Jakarta

deliveryState

A

50

Delivery State

DKI Jakarta

deliveryPostCd

N

10

Delivery Post Number

10201

deliveryCountry

A

A

Delivery Country

Indonesia

vat

N

12

VAT

0

fee

N

12

Service Tax

0

notaxAmt

N

12

Tax Free Amount

0

reqDt

N

N

Request Date (YYYYMMDD)

20230516

reqTm

N

N

Request Time (HH24MISS)

135959

reqDomain

ANS

100

Request Domain

www.merchant.com

reqServerIP

ANS

15

Request Server IP

127.0.0.1

reqClientVer

ANS

50

Request Client Version

1.0

userSessionID

AN

100

User Session ID

userSessionID

userAgent

ANS

100

User Agent Information

Mozilla

userLanguage

ANS

2

User Language

en-US



Response Parameter - Credit Card Payment

Sample Respone Payment


Parameter

Type

Size

Description

resultCd

N

4

Result Code

resultMsg

AN

255

tXid

AN

30

Transaction ID

referenceNo

ANS

40

Merchant Order Number

payMethod

N

2

amount

N

12

Transaction Amount

currency

AN

3

Currency

goodsNm

N

100

Goods Name

billingNm

N

30

Buyer Name

transDt

N

8

Transaction Date (YYYYMMDD)

transTm

N

6

Transaction Time (HH24MISS)

description

AN

100

Transaction Description

callbackUrl

ANS

100

Callback URL

authNo

N

10

Authorization Number

issuBankCd

A

4

issuBankNm

A

255

Issuing Bank Name

acquBankCd

A

4

acquBankNm

A

255

Acquiring Bank Name

cardNo

ANS

20

Card Number (Masked)

instmntMon

N

2

Installment Month

instmntType

N

2

Installment Type

recurringToken

AN

64

Token for Recurring Payment

preauthToken

AN

64

Token for Preauth Payment

ccTransType

N

2

vat

N

12

VAT Number

fee

N

12

Service Fee

notaxAmt

N

12

Tax Free Amount



Credit Card Recurring



When the Merchant signs contract as Recurring, NICEPAY give a RecurringToken to the Payment API Response. The Merchant can use RecurringToken for the next Payment API Request without input card detail, except cardCVV (Mandatory).



Recurring Issue

To do the Recurring payment, the system need recurringToken own from the Customer to use the Customer information continuously without reinputting the card data multiple times. recurringToken receives after the Customer proceeds the initial payment. Following are the steps to get the recurringToken .

  1. The Customer will input the data card such as cardNo and ExyMmYy through API Request Token (onePassToken.do).
  2. The Customer will get cardToken.
  3. Recurring payment process on V1 Enterprise divide into 2 process , Direct 3Ds and Direct Non-3Ds.
    • If going through the 3Ds process, then the card data will going through the security verification from API 3Ds Request (secureVeRequest.do) with an OTP also FDS (Fraud Detection System) NICEPAY security.
    • If not going through 3Ds process, then will not going through the security verification.
  4. The Customer does payment with API Credit Card Payment (onePass.do) and get recurringToken to proceed the recurring payment.

API Specification - Recurring Issue

API Endpoint

/nicepay/api/recurringToken.do

Request Method application/x-www-form-urlencoded

POST

Description

recurringToken.do almost similar to onePassToken.do the difference whether use the card info or recurring token

Merchant Token

SHA256 (Merchant ID + Reference Number + Amount + Merchant Key)



Request Parameter - Recurring Issue

The parameter below must send on 'jsonData' parameter and with JSON format.

Sample Request Recurring Issue


Parameter

Type

Size

Description

Example / Notes

amt Required 

N

12

Amount

10000

referenceNo Required 

AN

40

Merchant Order Number

MerchantReferenceNumber001

merchantToken Required 

AN

255

Merchant Token

baf19eaed10d8539498cbe06ed19c50a60a587416d9c980abbb3c06b4eee51f5

iMid Required 

AN

10

Merchant ID

IONPAYTEST

recurringToken Required 

AN

100

Recurring Token

88cb7e30c531429a95fb2af442f591b75939fd0387288af2dc2340c50776d84a

instmntType Required 

AN

2

1

instmntMon Required 

N

2

Installment Month

1

cardHolderNm Required 

AN

45

Card Holder Name

John Doe

cardHolderEmail Required 

ANS

100

Card Holder Email

johndoe@gmail.com



Response Parameter - Recurring Issue

Sample Response Parameter


Parameter

Type

Size

Description

Remark

resultCd

N

4

Result Code

0000

resultMsg

AN

255

SUCCESS

cardToken

AN

64

Recurring Token

c954f03ef83a363f94fa26bef6ec4d08fa7693590a735386fcce6e2ef1caae8a

paymentType

AN

1

1 : 3Ds

2 : KeyIn





Recurring Payment

After get the recurringToken from the initial payment success or result from card registration process, the system will use that recurringToken to execute the next schedule. Following is the payment steps on the system using the recurringToken.

  1. Input recurringToken gain from the initial payment process (recurringToken.do) or the result from card registration process (tokenize.do).
  2. Next, cardToken will gain and save on the database to use on the next payment.
  3. Special for the 3Ds process, card data will go through the security verification from API 3Ds Request (secureVeRequest.do) with an OTP also FDS (Fraud Detection System) NICEPAY security using cardToken gain from the previous step.
  4. The payment will proceed using API Recurring Payment (recurringTrans.do).

This process will proceed continuously on the recurring period.

On the next recurring payment, recurringToken will originate from recurringToken.do . onePass.do only use during the first recurring payment.

API Specifications - Recurring Payment

API Endpoint

/nicepay/api/recurringTrans.do

Method

application/x-www-form-urlencoded

POST

Merchant Token

SHA256(Merchant ID + Reference Number + Amount + MerchantKey)

Description

The API Payment for Credit Card Recurring or payment with Recurring Token



Request Parameter- Recurring Payment

Sample Request Recurring Payment
Sample Java Request Recurring Paymen


Parameter

Type

Size

Description

Example / Notes

iMid

Required

AN

2

Merchant ID

IONPAYTEST

payMethod Required

N

2

01

currency Required 

A

40

Currency

IDR

amt Required 

N

12

Goods Amount

10000

referenceNo Required

ANS

40

Merchant Order Number

MerchantReferenceNumber001

goodsNm Required 

AN

100

Goods Name

Merchant Goods 1

billingNm Required 

A

30

Billing Name

John Doe

billingPhone Required 

N

15

Billing Phone Number

08123456789

billingEmail Required

ANS

40

Billing E-Mail

john.doe@example.com

billingCity Required

N

50

Billing City

South Jakarta

billingState Required 

A

50

Billing State

DKI Jakarta

billingPostCd Required

N

10

Billing Post Number

10200

billingCountry Required

A

10

Billing Country

Indonesia

callBackUrl Required 

ANS

255

Payment Result Forward URL (On Browser)

https://www.mechant.com/callbackUrl

dbProcessUrl Required

ANS

255

Payment Result Receive URL (Server Side)

https://www.merchant.com/dbProcessUrl

description Required

AN

100

Description

This Is The Description Of The Payment

merchantToken Required 

AN

255

Merchant Token

2349fcbd3a5b81d08ca719cc6d9c826f2f6f9d4de337b86e4019114aad6222b1

userIP Required

ANS

15

User IP

127.0.0.1

cartData Required 

ANS

4000

Cart Data (JSON Format)

{}

instmntType Required 

N

2

1

instmntMon Required 

N

2

Installment Month

1

cardCvv

N

3

Card CVV

100

recurringToken

Required 

AN

64

Recurring Token

88cb7e30c531429a95fb2af442f591b75939fd0387288af2dc2340c50776d84a

recurrOpt Required For Recurring CC 

N

2

0 Automatic Cancel 1 Do Not Cancel 2 Do Not Make Token

1

billingAddr

AN

255

Billing Address

Jln. Raya Kasablanka Kav.88

deliveryNm

A

30

Delivery Name

Merchant's Name

deliveryPhone

N

15

Delivery Phone

08123456789

deliveryAddr

AN

100

Delivery Address

Jln. Dr. Saharjo No.88

deliveryEmail

ANS

100

Delivery E-Mail

example@merchant.com

deliveryCity

A

50

Delivery City

South Jakarta

deliveryState

A

50

Delivery State

DKI Jakarta

deliveryPostCd

N

10

Delivery Post Number

10201

deliveryCountry

A

A

Delivery Country

Indonesia

vat

N

12

VAT

0

fee

N

12

Service Tax

0

notaxAmt

N

12

Tax Free Amount

0

reqDt

N

N

Request Date (YYYYMMDD)

20230516

reqTm

N

N

Request Time (HH24MISS)

135959

reqDomain

ANS

100

Request Domain

www.merchant.com

reqServerIP

ANS

15

Request Server IP

127.0.0.1

reqClientVer

ANS

50

Request Client Version

1.0

userSessionID

AN

100

User Session ID

userSessionID

userAgent

ANS

100

User Agent Information

Mozilla

userLanguage

ANS

2

User Language

en-US



Response Parameter - Recurring Payment

Sample Response Recurring Payment


Parameter

Type

Size

Description

resultCd

N

4

Result Code

resultMsg

AN

255

tXid

AN

30

Transaction ID

referenceNo

ANS

40

Merchant Order Number

payMethod

N

2

amount

N

12

Transaction Amount

currency

AN

3

Currency

goodsNm

N

100

Goods Name

billingNm

N

30

Buyer Name

transDt

N

8

Transaction Date (YYYYMMDD)

transTm

N

6

Transaction Time (HH24MISS)

description

AN

100

Transaction Description

callbackUrl

ANS

100

Callback URL

authNo

N

10

Authorization Number

issuBankCd

A

4

issuBankNm

A

255

Issuing Bank Name

acquBankCd

A

4

acquBankNm

A

255

Acquiring Bank Name

cardNo

ANS

20

Card Number (Masked)

instmntMon

N

2

Installment Month

instmntType

N

2

ccTransType

N

2

Credit Card Transaction Type

vat

N

12

VAT Number

fee

N

12

Service Fee

notaxAmt

N

12

Tax Free Amount



Generate Recurring Token Without First Payment

This API uses specific on Credit Card with Recurring type to create the recurringToken without doing the payment transaction process beforehand, but only going through the card information registration process. recurringToken that created successfully can be used for transaction process (recurringTrans.do).

API Specification - Generate Recurring Token Without First Payment

API Endpoint

/nicepay/api/tokenize.do

Method 

application/x-www-form-urlencoded

POST

Description

To generate Credit Card's Recurring Token without proceed through the payment process beforehand.

Merchant Token

SHA256 (Merchant ID + Card No + Card Exp Yymm + Merchant Key)



Request Parameter - Generate Recurring Token

Sample Java Request Generate Recurring Token


Parameter

Type

Size

Description

Contoh / Catatan

iMid

Required

AN

10

Merchant ID

IONPAYTEST

merchantToken

Required

AN

255

Merchant Token

b63d66156715bf8c9d851e76 e61a42ce7efb815a91843b75 35c5bcde8490cb4d

cardNo

Required

N

16

Card Number

552103******6573

cardExpYymm

Required

N

4

Card Expired YY/MM

2012

billingNm

Required

A

30

Billing Name

John Doe

cardHolderNm

Required

AN

45

Card Holder Name

John Doe

cardHolderEmail

Required

ANS

100

Cardholder Email

johndoe@gmail.com



Response Parameter - Generate Recurring Token

Sample Java Response Generate Recurring Token


Parameter

Type

Size

Description

Example / Notes

resultCode

N

4

Result Code

0000

resultMsg

AN

255

Result Message

SUCCESS

transDt

N

8

Transaction Date

20180604

When Success

transTm

N

6

Transaction Time

141806

When Success

recurringToken

AN

10

Recurring Token

75d5220c439b83359ed440ab 12b713ed273feb455cc278fe0 0209e57dfe84cjk

When Success



Check Recurring Token

API Specification - Check Recurring Token

API Endpoint

/nicepay/api/checkToken.do

Method

application/x-www-form-urlencoded

POST

Merchant Token

SHA256(Merchant ID + Recurring Token + MerchantKey)

Deskripsi

To check the Recurring Token on Credit Card payment.



Request Parameter - Check Recurring Token

Sample Java Request Check Recurring Token


Parameter

Type

Size

Description

Example / Notes

iMid

Required

AN

10

Merchant ID

IONPAYTEST

merchantToken

Required

AN

64

Merchant Token

b63d66156715bf8c9d851e76 e61a42ce7efb815a91843b75 35c5bcde8490cb4d

recurringToken

Required

AN

64

Recurring Token

75d5220c439b83359ed440ab 12b713ed273feb455cc278fe0 0209e57dfe84c7a



Response Parameter - Check Recurring Token

Sample Java Response Check Recurring Token


Parameter

Type

Size

Description

Example / Notes

resultCode

Required

N

4

Result Code

0000

resultMsg

Required

AN

255

Result Message

SUCCESS

transDt

Required

N

8

Transaction Date

20180604

transTm

Required

N

6

Transaction Time

141806

When Success

recurringToken

Required

AN

60

Authorization Number

75d5220c439b83359ed440ab 12b713ed273feb455cc278fe0 0209e57dfe84cjk

When Success

billingEmail

Required

AN

40

Billing Email



When Success

billingNm

Required

A

30

Billing Name



When Success



Remove Recurring Token

API Specification - Remove Recurring Token

API Endpoint

/nicepay/api/removeToken.do

Method

application/x-www-form-urlencoded

POST

Merchant Token

SHA256(Merchant ID + Recurring Token + MerchantKey)

Deskripsi

To remove the Recurring Token on Credit Card payment



Request Parameter - Remove Recurring Token

Sample Java Request Remove Recurring Token


Parameter

Type

Size

Description

Example / Notes

iMid

Required

AN

10

Merchant ID

IONPAYTEST

merchantToken

Required

AN

64

Merchant Token

b63d66156715bf8c9d851e76 e61a42ce7efb815a91843b75 35c5bcde8490cb4d

recurringToken

Required

AN

64

Recurring Token

75d5220c439b83359ed440ab 12b713ed273feb455cc278fe0 0209e57dfe84c7a



Response Parameter - Remove Recurring Token

Sample Java Response Remove Recurring Token


Parameter

Type

Size

Description

Example / Notes

resultCode

N

4

Result Code

0000

resultMsg

AN

255

Result Message

SUCCESS

transDt

N

8

Transaction Date

20180604

When Success

transTm

N

6

Transaction Time

141806

When Success



Credit Card Pre-Auth



To do Pre-Auth & Capture payment, the system need preauthToken to proceed the capture process. That process only can proceed during the preauthToken validity period. Following are the payment steps on the system using Pre-Auth Token.

  1. The Customer will input the data card such as cardNo and ExyMmYy through API Request Token (onePassToken.do).
  2. The Customer will get cardToken.
  3. The Pre-Auth process on V1 Enterprise divides into 2 processes, Direct 3Ds, and Direct Non-3Ds.
    • If going through the 3Ds process, then the card data will go through the security verification from API 3Ds Request (secureVeRequest.do) with an OTP also FDS (Fraud Detection System) NICEPAY security.
    • If not go through the 3Ds process, then will not go through the security verification. 
  4. The Customer does a payment with API Credit Card Payment (onePass.do).
  5. The system does hold process and gets preauthToken to proceed with the process.
  6. The capture amount process will use API Pre-Auth (captureTrans.do) by input preauthToken and CVV.

If preauthToken expired, then payment will become void and the balance will refund to the Customer.

API Specification- Pre-Auth

API Endpoint

/nicepay/api/captureTrans.do

Method

application/x-www-form-urlencoded

POST

Merchant Token

SHA256(Merchant ID + Reference Number + Amount + MerchantKey)

Deskripsi

API Payment for Credit Card Pre-Auth using preauthToken



Request Parameter - Pre-Auth

Sample Request Pre-Auth
Sample Java Request Pre-Auth


Parameter

Type

Size

Description

Example / Notes

iMid

Required

AN

2

Merchant ID

IONPAYTEST

payMethod Required

N

2

01

currency Required 

A

40

Currency

IDR

amt Required 

N

12

Goods Amount

10000

referenceNo Required

ANS

40

Merchant Order Number

MerchantReferenceNumber001

goodsNm Required 

AN

100

Goods Name

Merchant Goods 1

billingNm Required 

A

30

Billing Name

John Doe

billingPhone Required 

N

15

Billing Phone Number

08123456789

billingEmail Required

ANS

40

Billing E-Mail

john.doe@example.com

billingCity Required

N

50

Billing City

South Jakarta

billingState Required 

A

50

Billing State

DKI Jakarta

billingPostCd Required

N

10

Billing Post Number

10200

billingCountry Required

A

10

Billing Country

Indonesia

callBackUrl Required 

ANS

255

Payment Result Forward URL (On Browser)

https://www.mechant.com/callbackUrl

dbProcessUrl Required

ANS

255

Payment Result Receive URL (Server Side)

https://www.merchant.com/dbProcessUrl

description Required

AN

100

Description

This Is The Description Of The Payment

merchantToken Required 

AN

255

Merchant Token

2349fcbd3a5b81d08ca719cc6d9c826f2f6f9d4de337b86e4019114aad6222b1

userIP Required

ANS

15

User IP

127.0.0.1

cartData Required 

ANS

4000

Cart Data (JSON Format)

{}

instmntType Required 

N

2

1

instmntMon Required 

N

2

Installment Month

1

cardCvv

N

3

Card CVV

100

preauthToken

Required 

AN

255

Pre-Auth Token

c2921cc7a1967f905fd4f895f22f06c02d24adf8c9f7b169d6ef0c2c0b128549

recurrOpt Required For Recurring CC 

N

2

0 : Automatic Cancel 1 : Do Not Cancel 2 : Do Not Make Token

1

billingAddr

AN

255

Billing Address

Jln. Raya Kasablanka Kav.88

deliveryNm

A

30

Delivery Name

Merchant's Name

deliveryPhone

N

15

Delivery Phone

08123456789

deliveryAddr

AN

100

Delivery Address

Jln. Dr. Saharjo No.88

deliveryEmail

AN

100

Delivery E-Mail

example@merchant.com

deliveryCity

A

50

Delivery City

South Jakarta

deliveryState

A

50

Delivery State

DKI Jakarta

deliveryPostCd

N

10

Delivery Post Number

10201

deliveryCountry

A

A

Delivery Country

Indonesia

vat

N

12

VAT

0

fee

N

12

Service Tax

0

notaxAmt

N

12

Tax Free Amount

0

reqDt

N

N

Request Date (YYYYMMDD)

20230516

reqTm

N

N

Request Time (HH24MISS)

135959

reqDomain

ANS

100

Request Domain

www.merchant.com

reqServerIP

ANS

15

Request Server IP

127.0.0.1

reqClientVer

ANS

50

Request Client Version

1.0

userSessionID

AN

100

User Session ID

userSessionID

userAgent

ANS

100

User Agent Information

Mozilla

userLanguage

ANS

2

User Language

en-US



Response Parameter - Pre-Auth

Sample Response Pre-Auth


Parameter

Type

Size

Description

resultCd

N

4

Result Code

resultMsg

AN

255

tXid

AN

30

Transaction ID

referenceNo

ANS

40

Merchant Order Number

payMethod

N

2

amount

N

12

Transaction Amount

currency

AN

3

Currency

goodsNm

N

100

Goods Name

billingNm

N

30

Buyer Name

transDt

N

8

Transaction Date (YYYYMMDD)

transTm

N

6

Transaction Time (HH24MISS)

description

AN

100

Transaction Description

callbackUrl

ANS

100

Callback URL

authNo

N

10

Authorization Number

issuBankCd

A

4

issuBankNm

A

255

Issuing Bank Name

acquBankCd

A

4

acquBankNm

A

255

Acquiring Bank Name

cardNo

ANS

20

Card Number (Masked)

instmntMon

N

2

Installment Month

instmntType

N

2

ccTransType

N

2

vat

N

12

{{vat}} Number

fee

N

12

Service Fee

notaxAmt

N

12

Tax Free Amount