Airwallex logo
Airwallex logo

Naver Pay recurring payments

When processing a payment for the first time

Step 1: Create a Customer

Create a customer with the Create a Customer API API if the customer is new. Otherwise, this step is optional.

Step 2: Create a Payment Intent

Create a Payment Intent with the Create a Payment Intent API API.

POST /api/v1/pa/payment_intents/create

JSON
1{
2 "request_id": "ed11e38a-7234-11ea-aa94-7fd44ffd1b89",
3 "amount": 100,
4 "currency": "KRW",
5 "merchant_order_id": "85d7b0e0-7235-11ea-862e-9f6aa1adfca6",
6 "return_url": "https://www.airwallex.com"
7}

If the payment is not intended to charge the shopper for the first time, such as a subscription with a free trial, please set the amount to zero.

Step 3: Confirm the Payment Intent With Consent Info

When you want to redirect the shopper to authorize the consent with Naver Pay, call the Confirm a Payment Intent API API with the Payment Consent info to get a redirect URL.

POST /api/v1/pa/payment_intents/{id}/confirm

JSON
1{
2 "request_id": "{{$guid}}",
3 "customer_id": "{{customer_id}}",
4 "payment_method": {
5 "type": "naver_pay"
6 },
7 "payment_consent": {
8 "next_triggered_by": "merchant",
9 "merchant_trigger_reason": "unscheduled"
10 }
11}

Once the shopper completes the payment, the Payment Consent will be verified automatically, and Airwallex will notify you of the Payment Consent status asynchronously via the webhook. Please refer to the webhook documentation to set up your webhook accordingly.

When initiating a subsequent transaction

Step 1: Initialize a Payment Intent

When you are ready to process the subsequent recurring payment, create a Payment Intent with the Create a Payment Intent API API.

POST /api/v1/pa/payment_intents/create

JSON
1{
2 "request_id": "ed11e38a-7234-11ea-aa94-7fd44ffd1b89",
3 "amount": 100,
4 "currency": "KRW",
5 "merchant_order_id": "85d7b0e0-7235-11ea-862e-9f6aa1adfca6",
6 "return_url": "https://www.airwallex.com"
7}

Step 2. Complete payment with verified consent

Confirm the subsequent payment with the verified Payment Consent by calling the Confirm a Payment Intent API API.

POST /api/v1/pa/payment_intents/{id}/confirm

JSON
1{
2 "request_id": "ed11e38a-7234-11ea-aa94-7fd44ffd1b89",
3 "payment_consent_id": "cst_sgstjgzhsh7hhmj8hr0"
4}
Was this page helpful?