NICEPAY API
...
API Credit Card
Payment - API Credit Card

Recurring - Payment API Credit Card

17min

About Recurring - Payment API Credit Card



 Recurring type is another  feature that can pay a particular bill from your  periodically with  same amount similar to  initial bill .

The  used in this  stage is similar to   for Full  & Installment and Pre-Auth & Capture  types. However, there are differences in  sent  request.

 will give a recurringToken as   response  called recurring token making.  can use recurringToken on  later   request without using cardNo and cardExpYymm.



Recurring - Payment API Credit Card (First Payment)



To activate   recurring type , you mandatory pay  created  to receive  recurringToken beforehand.

API Endpoint

/nicepay/direct/v2/payment

Request Method

application/x-www-form-urlencoded

POST

Description

Recurring

Merchant Token

SHA256(timeStamp+iMid+referenceNo+amt+merchantKey)

The used  specification is similar to  API Recurring Token Credit Card.



Request Payment for Credit Card Recurring (First Payment)



The following is a request  on recurring to gain recurringToken which where You need to finish  Recurring - Registration API Credit Card beforehand.

You still need cardNo, cardExpYymm, cardCvv, cardHolderNm & cardHolderEmail from   on  first  on this recurring scheme.

Parameter

Type

Size

Description

Example / Notes

timeStamp

Required

N

14

Request Timestamp (YYYYMMDDHH24MISS)

20230522080502

tXid

Required

AN

30

Transaction ID

IONPAYTEST01202305220041509298

referenceNo

Required

ANS

40

 Order Number

MerchantReferenceNumber001

merchantToken

Required

AN

255

 Token

ff139e49606387091cd9baeadff3161aff6afd9406e1f481e0fdb8b46d1ae5ae

cardNo

Required

N

20

 Number

51234500****0000

cardExpYymm

Required

A

4

Card Expiry (YYMM)

3901

cardCvv

Required

N

4

Card CVV

100

cardHolderNm

Required

AN

45

Card Holder Name

John Doe



Only alphabet allowed

cardHolderEmail

Required

ANS

100

Card Holder Email

johndoe@gmail.com

callBackUrl

Required

ANS

255

 Result URL

https://www.nicepay.co.id/IONPAY_CLIENT/paymentResult.jsp



Response Parameter for Credit Card Recurring (First Payment)



Below is  detailed response You get.  perform save & store  recurringToken gain to execute  recurring feature  on  next  with  same  .

Parameter

Type

Size

Description

Example / Notes

timeStamp

N

14

Response Date

(YYYYMMDDHH24MISS)

20230520135959

resultCd

N

4

Result Code

0000

resultMsg

AN

255

SUCCESS

tXid

AN

30

Transaction ID

IONPAYTEST01202305161007570327

referenceNo

ANS

40

 Order Number

MerchantReferenceNumber001

payMethod

N

2

01



When Success

amount

N

12

 Amount

10000



When Success

currency

AN

3

Currency

IDR



When Success

goodsNm

AN

100

Goods Name

 Goods 1



When Success

billingNm

AN

100

Buyer Name

John Doe



When Success

transDt

N

8

Transaction Date

(YYYYMMDD)

20230516



When Success

transTm

N

6

Transaction Time

(HH24MISS)

135959



When Success

description

AN

100

Transaction Description

This Is The Description Of The 



When Success

authNo

N

10

Approval Number

123456



When Success

issuBankCd

A

4

CENA (Refer  Code)



When Success

acquBankCd

A

4

BNIA (Refer  Code)



When Success

cardNo

AN

20

Card Number (Masked)

51234500****0008



When Success

cardExpYymm

N

4

Card Expiry

(YYMM)

3901



When Success

instmntMon

N

1

Installment Month

1



When Success

instmntType

N

2

1



When Success

ccTransType

AN

2

1 Normal

2 Recurring

3 Pre-Auth

4 Capture

2



When Success

vat

N

12

Value Added Tax ()

0



When Success

fee

N

12

Service Fee

0



When Success

notaxAmt

N

12

Tax Free Amount

0



When Success

recurringToken

AN

64

Token That Using Recurring Payment

f19e3128784d0b33c189d5df21321c781b5bd107b185587fd8a54781aa845c84

acquBankNm

A

255

Acquiring  Name

CIMB

issuBankNm

A

255

Issuing  Name

BCA



Sample for Credit Card Recurring (First Payment)

Sample Request Recurring Payment
Sample Response Recurring Payment
Java Request




Continual Recurring - Payment API Credit Card



After ing with  first  and already receiving recurringToken on Recurring - Payment API Credit Card.

You can use that recurringToken to pay another bill using a similar   credential to implement recurring (subscription)  mechanism. However, to  this  continual recurring, You still need to beforehand do   registration on Recurring - Registration API Credit Card.

The following is  request and response detail used on  later  using  same recurring token.

API Endpoint

/nicepay/direct/v2/payment

Request Method

application/x-www-form-urlencoded

POST

Description

Recurring Continual  

Merchant Token

SHA256(timeStamp+iMid+referenceNo+amt+merchantKey)

 specification used is similar to  API Recurring Token Credit Card



Request Payment for Credit Card Recurring



You only need to use recurringToken on   Recurring for this next request without using cardNo and cardExpYymm .

Parameter

Type

Size

Description

Example / Notes

timeStamp

Required

N

14

Request Timestamp (YYYYMMDDHH24MISS)

20230522080502

tXid

Required

AN

30

Transaction ID

IONPAYTEST01202305220041509298

referenceNo

Required

ANS

40

 Order Number

MerchantReferenceNumber001

merchantToken

Required

AN

255

 Token

ff139e49606387091cd9baeadff3161aff6afd9406e1f481e0fdb8b46d1ae5ae

recurringToken

Required

AN

64

Token That Using Recurring Payment

When Success f19e3128784d0b33c189d5df21321c781b5bd107b185587fd8a54781aa845c84

cardCvv

Required

N

4

Card CVV

100

cardHolderNm

Required

AN

45

Card Holder Name

John Doe



Only alphabet allowed

cardHolderEmail

Required

ANS

100

Card Holder Email

johndoe@gmail.com

callBackUrl

Required

ANS

255

 Result URL

https://www.nicepay.co.id/IONPAY_CLIENT/paymentResult.jsp

Include cardCVV on every  depending on  MID type of CVV or Non-CVV.



Response Payment for Credit Card Recurring



Parameter

Type

Size

Description

Example / Notes

timeStamp

N

14

Response Date

(YYYYMMDDHH24MISS)

20230520135959

resultCd

N

4

Result Code

0000

resultMsg

AN

255

SUCCESS

tXid

AN

30

Transaction ID

IONPAYTEST01202305161007570327

referenceNo

ANS

40

 Order Number

MerchantReferenceNumber001

payMethod

N

2

01



When Success

amount

N

12

 Amount

10000



When Success

currency

AN

3

Currency

IDR



When Success

goodsNm

AN

100

Goods Name

 Goods 1



When Success

billingNm

AN

100

Buyer Name

John Doe



When Success

transDt

N

8

Transaction Date

(YYYYMMDD)

20230522



When Success

transTm

N

6

Transaction Time

(HH24MISS)

224343



When Success

description

AN

100

Transaction Description

This Is The Description Of The 



When Success

authNo

N

10

Approval Number

123456



When Success

issuBankCd

A

4

CENA (Refer  Code)



When Success

acquBankCd

A

4

BNIA (Refer  Code)



When Success

cardNo

AN

20

Card Number (Masked)

51234500****0008



When Success

cardExpYymm

N

4

Card Expiry

(YYMM)

3901



When Success

instmntMon

N

1

Installment Month

1



When Success

instmntType

N

2

1



When Success

ccTransType

AN

2

1 Normal

2 Recurring

3 Pre-Auth

4 Capture

2



When Success

vat

N

12

Value Added Tax ()

0



When Success

fee

N

12

Service Fee

0



When Success

notaxAmt

N

12

Tax Free Amount

0



When Success

acquBankNm

A

255

Acquiring  Name

CIMB

issuBankNm

A

255

Issuing  Name

BCA



Sample JSON for Credit Card Recurring Payment


Sample Request Continual Payment
Sample Response Continual Payment
Sample Java Request Continual




CallBack Handling for Credit Card Payment



tXid will never similar with  request hold. Capture  will ensure that  capture amount value won't exceed  owned funds.

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

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

URL CallBack
Response CallBack