NICEPAY API
...
Checkout API
Payment - API Checkout

Credit Card - API Checkout

33min

About Credit Card - API Checkout



There are several things that you must know when using for method so that your will run smoothly with us:

  1. Flow 3Ds/Non-3Ds Process.
  2. Full Feature.
  3. Installment Feature.
  4. Recurring Token Feature.
  5. Pre-Auth Token Feature.



Process Flow



 visit Credit Card Feature to check explanation about 3Ds.

3Ds

CC Payment Flow - Redirect 3Ds
CC Payment Flow - Redirect 3Ds


Description steps of Redirect flow with 3Ds:

  1. The does .
  2. The sends data to .
  3. The requests using Registration to .
  4.  registers data.
  5.  redirects to 's .
  6. The sends 's to .
  7. The selects .
  8. The inputs card data.
  9. The sends of card data to .
  10.  s with FDS calculation.
  11.  requests 3Ds to .
  12.  validates 3Ds.
  13.  sends 3Ds URL response to .
  14.  receives verification response.
  15.  redirects to ACS authentication .
  16.  creates OTP response.
  17.  sends OTP to .
  18. The receives OTP.
  19. The inputs OTP.
  20. The sends OTP to .
  21.  verifies the OTP.
  22.  sends 3Ds result to .
  23.  receives checking result.
  24.  requests to .
  25.  s .
  26.  sends to .
  27.  performs callbackUrl redirect to .
  28. The displays callbackUrl result to .
  29.  sends to .
  30. The receives .
  31. The requests inquiry to .
  32.  receives request.
  33.  automatically sends inquiry response to .
  34. The receives final .
  35. The sends result to .



Non-3Ds

CC Payment Flow - Redirect N 3Ds
CC Payment Flow - Redirect N 3Ds


Description steps of Redirect flow with Non-3Ds:

  1. The performs .
  2. The requests to .
  3. The registers data.
  4. The sends response in form of card data form.
  5. The requests to .
  6. The registers using Registration to .
  7.  stores registration.
  8.  redirects s to 's .
  9. The sends 's to .
  10. The selects .
  11. The inputs card detail.
  12. The requests using to .
  13.  s with FDS calculation.
  14.  requests to .
  15.  verifies request.
  16.  sends confirmation request to .
  17. The requests /charge to .
  18.  s .
  19.  sends response of to .
  20.  sends notification using callBackUrl and dbProcessUrl to .
  21. The receives .
  22. The requests checking to .
  23.  sends response of checking.
  24. The receives final .
  25. The sends result to .



NICEPAY Secure Payment Page



 open Credit Card Payment Guide to provide your with guide on method.

Secure Payment Page
Secure Payment Page


The image above is a sample with a using Secure Page.

After selects method, will ask to input their card data. will automatically recognize type of 's BIN card like in picture below, such as VISA or Mastercard, American Express, etc, later cards will be different according to card types being used.

After completing card data input, Your can continue .

Credit Secure Payment Page
Credit Secure Payment Page


Then, will run. Once is successful, then display of will appear as image as follows.

Success - NICEPAY Secure Payment Page
Success - NICEPAY Secure Payment Page


 visit Payment - API Checkout to know next step regarding payment handling.



Full Payment Credit Card



On Full , paid fully nominal billed at once. The following is details used on .

Request Parameter Full Payment Credit Card



Parameter

Type

Size

Description

Remark

paymentURL

Required

ANS

14

 URL



https://dev.nicepay.co.id/nicepay/redirect/v2/payment

tXid

Required

AN

30

Transaction ID



IONPAYTEST00202203211640309389

For , with Full and Installment got same response.



Response Parameters Full Payment Credit Card (CallbackUrl) - Payment



Parameter

Type

Size

Description

Remark

status

N

1

0

tXid

AN

30

Transaction ID

IONPAYTEST00202212201540174369



When Success

referenceNo

AN

40

 Order Number

ordNo20221220151243



When Success

payMethod

N

2

01



When Success

amt

N

12

Transaction Amount

1000



When Success

notaxAmt

N

12

Tax Fee Amount

0



When Success

vat

N

12

Value Added Tax ()

0



When Success

fee

N

12

Service Fee

0



When Success

currency

A

3

Currency

IDR



When Success

goodsNm

AN

100

Goods Name

Goods+For+Testing+Credit+Card



When Success

billingNm

A

100

Billing Name

John+Doe



When Success

transDt

N

8

Transaction Date (YYYYMMDD)

20221220



When Success

transTm

N

6

Transaction Time (HH24MISS)

154017



When Success

authNo

N

10

Approval Number

174300



When Success (Additional)

issuBankCd

A

4

BMRI



When Success

acquBankCd

A

4

BMRI



When Success

issuBankNm

A

255

Issuing Name

Mandiri



When Success

acquBankNm

A

255

Acquiring Name

Mandiri



When Success

ccTransType

AN



2

 Transaction Type:

1: Normal

2: Recurring

3: Pre-Auth

4: Capture

1



When Success

cardNo

ANS

20

Card Number with Masking

46161111****1111



When Success

cardExpYymm

N

4

Card Expiration (YYMM)

2707



When Success

instmntType

N

2

1



When Success

instmntMon

N

2

Installment Month 1: 1 Month/Full , if instmntType: null/1 3: 3 Months 6: 6 Months 12: 12 Months

1



When Success

recurringToken

AN

255

Recurring Token

null



When Success

preauthToken

AN

255

Pre-Auth Token

null



When Success

matchCl

N

1

1



When Success

merchantToken

AN

255

 Token

8f5b330a549c167b53b4b9fd5f2d2eba897a64235c1610524074ec59f8884e8a



Sample Parameter for CallbackUrl API Checkout Payment


URL Request
URL Callback
Response Callback


Note: Response will be sent through callBackurl with Content-type: application/json and method: POST Parameter.

For on , Response from Request received after performing Call Request is a callback URL.



API Checkout Transaction Payment



API URL

/nicepay/redirect/v2/payment

Request Method

Redirect-GET

Header

Content-Type: application/Form-UrlEncoded

The endpoint above can use for s with Full , Recurring, and PAC (Pre-Auth Capture) types.



Recurring Token



After completes Registration - API Checkout and Payment - API Checkout, then will provide recurringToken for gain Payment - API Checkout response.

On next with same , can use that recurringToken by using on Recurring - Payment API Credit Card.



Request Parameter Recurring Token



Parameter

Type

Size

Description

Remark

paymentURL

Required

ANS

14

 URL



https://dev.nicepay.co.id/nicepay/redirect/v2/payment

tXid

Required

AN

30

Transaction ID



RECURRTEST00202212221422115631



Response Parameter Recurring Token



Parameter

Type

Size

Description

Remark

status

N

1

0

tXid

AN

30

Transaction ID

RECURRTEST00202212221422115631



When Success

referenceNo

AN

40

 Order Number

ordNo20221222141245



When Success

payMethod

N

2

01



When Success

amt

N

12

Transaction Amount

1000



When Success

notaxAmt

N

12

Tax Fee Amount

0



When Success

vat

N

12

Value Added Tax ( )

0



When Success

fee

N

12

Service Fee

0



When Success

currency

A

3

Currency

IDR



When Success

goodsNm

AN

100

Goods Name

Goods+For+Testing+Recurring+Token



When Success

billingNm

A

100

Billing Name

John+Doe



When Success

transDt

N

8

Transaction Date (YYYYMMDD)

20221220



When Success

transTm

N

6

Transaction Time (HH24MISS)

142211



When Success

authNo

N

10

Approval Number

115631



When Success (Additional)

issuBankCd

A

4

OTHR



When Success

acquBankCd

A

4

BMRI



When Success

issuBankNm

A

255

Issuing Name

(empty)



When Success

acquBankNm

A

255

Acquiring Name

Mandiri



When Success

ccTransType

AN



2

 Transaction Type:

1: Normal

2: Recurring

3: Pre-Auth

4: Capture

1



When Success

cardNo

ANS

20

Card Number with Masking

45321111****1111



When Success

cardExpYymm

N

4

Card Expiry (YYMM)

2712



When Success

instmntType

N

2

1



When Success

instmntMon

N

2

Installment Month 1: 1 Month/Full , if instmntType: null/1 3: 3 Months 6: 6 Months 12: 12 Months

1



When Success

recurringToken

AN

255

Recurring Token

083333e129dea0535119b71813b1dc67b565e2704958411d2ee2ec2f430d745



When Success

preauthToken

AN

255

Pre-Auth Token

null



When Success

matchCl

N

1

 Amount Match Flag: Notification Status Code

1



When Success

merchantToken

AN

255

 Token

f083333e129dea0535119b71813b1dc67b565e2704958411d2ee2ec2f430d745



Sample Parameter Recurring Token Payment


URL Request
URL Callback
Response Callback


After ing with registration (Registration - API Checkout) and (Payment - API Checkout) using ,

  • If you want to with Recurring using same Recurring Token, please do registration again on Registration - API Checkout.
  • Then s by adding Recurring Token also CVV on recurringToken .



Pre-Auth Token



When s sign a contract as PAC (Pre-Auth/Capture), provides a preauthToken for Payment - API Checkout response. That token will later use on capture amount to complete on Pre-Auth & Capture - Payment API Credit Card.



Request Parameter Pre-Auth Token



The following are lists to perform requests with Pre-Auth Token . This uses in platform as one of steps to connect 's s with s.

Parameter

Type

Size

Description

Remark

paymentURL

Required

ANS

14

 URL



https://dev.nicepay.co.id/nicepay/redirect/v2/payment

tXid

Required

AN

30

Transaction ID

PACTEST00100202212221548525731



Response Parameter Pre-Auth Token



Parameter

Type

Size

Description

Remark

status

N

1

5

tXid

AN

30

Transaction ID

PACTEST00100202212221548525731



When Success

referenceNo

AN

40

 Order Number

ordNo20221222151220



When Success

payMethod

N

2

01



When Success

amt

N

12

Transaction Amount

1000



When Success

notaxAmt

N

12

Tax Fee Amount

0



When Success

vat

N

12

Value Added Tax ()

0



When Success

fee

N

12

Service Fee

0



When Success

currency

A

3

Currency

IDR



When Success

goodsNm

AN

100

Goods Name

Goods+For+Testing+Pre+-+Auth+Token



When Success

billingNm

A

100

Billing Name

John+Doe



When Success

transDt

N

8

Transaction Date (YYYYMMDD)

20221222



When Success

transTm

N

6

Transaction Time (HH24MISS)

154852



When Success

authNo

N

10

Approval Number

525731



When Success (Additional)

issuBankCd

A

4

CENA



When Success

acquBankCd

A

44

BMRI



When Success

issuBankNm

A

255

Issuing Name

BCA



When Success

acquBankNm

A

255

Acquiring Name

Mandiri



When Success

ccTransType

AN

2

 Transaction Type:

1: Normal

2: Recurring

3: Pre-Auth

4: Capture

1



When Success

cardNo

ANS

20

Card Number with Masking

53079511****1111



When Success

cardExpYymm

N

4

Card Expiry (YYMM)

2712



When Success

instmntType

N

2

1



When Success

instmntMon

N

2

Installment Month 1: 1 Month/Full , if instmntType: null/1 3: 3 Months 6: 6 Months 12: 12 Months

1



When Success

recurringToken

AN

255

Recurring Token

null



When Success

preauthToken

AN

255

Pre-Auth Token

edc46eb30a81ac9753e34003d2d1e910d5aaf0dea620889dffcfcc18621864eb



When Success

matchCl

N

1

 Amount Match Flag: Notification Match Amount Indicator

1



When Success

merchantToken

AN

255

 Token

1bee4b7c84cfb4e04d9d26cd47285bf49a77f252f39a48370094f5e3250b9524

Sample Parameter for Pre-Auth Token Payment


URL Request
URL Callback
Response Callback


After s registration and using ,

  • If you wants to with multiple-capture by using same Pre-Auth Token, please do registration again.
  • Then captures on Payment V2 Credit Card by adding Pre-Auth Token also CVV on preauthToken .



CallBack Handling API Checkout Payment



The tXid won't be same as request hold. The capture will reassure that captured amount value doesn't exceed funds owned.

When Your callback already received callbackUrl, we recommended to do verification using Status Inquiry - API Checkout.

CallBack Handling is very important to minimize Fraud act, we highly recommend to do verification using callBack parameter.

Callback Handling Flow
Callback Handling Flow

Callback Handling Flow
Callback Handling Flow

URL CallBack
Response CallBack