Widget (payment window) payment
What is Paymentwall widget?
Paymentwall is an overseas PG with a different payment environment than domestic PGs. Unlike the domestic environment where authenticated payments are common, non-authenticated payments are more common overseas. Non-authenticated payments are made in the Paymentwall payment window called a widget.
Test environment setup
- i'mport Admin console→ Payment integration → Test settings → Select PG (Paymentwall) → Paymentwall -> Add
- Check the auto-generated test MID value and click Save
- Test payments incur real payment on the actual credit card number, and you must cancel the transaction afterwards.
- Depending on each country's payment method policy, there may be countries/payment methods that cannot be cancelled (refunded).
Live environment setup
- Payment integration -> Live settings
- Select PG (Paymentwall) → Paymentwall -> Add
- Enter the Project Key/Secret Key issued by Paymentwall upon contract signing.
After setting Test mode to OFF, enter the information for the live account issued by Paymentwall after passing inspection.
You must apply via the following sign up page for i'mport:
(Signing up via other routes will cause payment integration issues.)
Note - Paymentwall payment integration flow
Result response for all payment requests through Paymentwall must be processed through i'mport webhook because Paymentwall transaction flow is different from domestic PGs. In the payment flow, the final result response for all transactions requested to Paymentwall is sent to i'mport via pingback (webhook), and i'mport sends it to the merchant via webhook.
The cancellation request processing flow is also different from domestic PGs due to Paymentwall's unique cancellation processing logic. The flow is identical to that of direct integration with Paymentwall without using i'mport. Unlike domestic PGs, Paymentwall does not immediately send the result of the cancellation request. It first creates a cancellation ticket for the request and processes each ticket one by one. Once processed, the result is sent to i'mport via pingback and i'mports sends it to the merchant via webhook.
Even if you integrate Paymentwall directly by registering a cancellation ticket in Paymentwall, you must process the final result received via pingback (webhook) from Paymentwall.
When using i'mport, you must update the "Waiting for cancellation" payment status in your database when you receive the final result via webhook notification.
Widget Version Configuration
Currently, PortOne supports widget codes pw_1
and t3_1
.
To use the pw_1
widget, the version must be 1.2
to function properly.
-
Go to Paymentwall Console → My Projects, select the relevant project → Widgets
-
Select Version 1.2 and then save changes (SAVE CHANGES)
User country code
You can know the user country code as a pingback upon completion of a paymentwall checkout. To get this, you need to add the parameter provided by the paymentwall as a pingback parameter.
-
Go to Paymentwall Console → My Projects, select the relevant project → Settings
-
Go to Custom Pingback parameters section
-
Add Name as
country_code
and select Value asCOUNTRY_CODE
You can check this result by adding the extension=true
query parameter when querying payment.
GET http://api.iamport.kr/payments/{imp_uid}?extension=true
{
// ...
"vbank_name": null,
"vbank_num": null,
"extension": {
"country_code": "KR" // User Country Code(alpha-2)
// ...
}
}
API Payment
Preparing for service
Preparing for service