This page explains how to add DOKU payment methods to your existing Web Components integration.
Through our partner DOKU, we offer various bank transfer payment methods and convenience store payment methods in Indonesia.
Requirements
Select which endpoint you are using:
Import resources for v6
If you are using Web Components v6, import the Component that you need for DOKU payment methods:
import { AdyenCheckout, Doku } from '@adyen/adyen-web'
API reference
You do not need to send additional fields for DOKU payment methods. To see optional fields that you can send for all payment methods, choose the endpoint you integrated:
- /sessions: This is the default with Components v5.0.0 or later.
- /payments: If you implemented an additional use case.
Component configuration
The Component to create depends on the payment method type:name |
type |
Kind of payment method |
---|---|---|
Alfamart | doku_alfamart | Convenience store |
Bank Transfer (Permata) | doku_permata_lite_atm | Bank transfer |
BCA Bank Transfer | doku_bca_va (only available with a local entity) | Bank transfer |
BNI VA | doku_bni_va | Bank transfer |
BRI VA | doku_bri_va (only available with a local entity) | Bank transfer |
CIMB VA | doku_cimb_va | Bank transfer |
Danamon VA | doku_danamon_va | Bank transfer |
Indomaret | doku_indomaret | Convenience store |
Mandiri VA | doku_mandiri_va | Bank transfer |
In the examples below, we use a scenario where the shopper chooses to pay in an Alfamart convenience store.
Step 1: Create a DOM element
Create a DOM element on your checkout page, placing it where you want the payment method form to be rendered:
<div id="doku_alfamart-container"></div>
Step 2: Create an instance of the Component
v6.0.0 or later
Create an instance of the Component, passing:
- Your instance of
AdyenCheckout
.
const dokuAlfamart = new Doku(checkout).mount('#doku_alfamart-container');
v5.x.x or earlier
Use the create
method of your AdyenCheckout
instance, in this case checkout
, to create the Component:
const dokuAlfamartComponent = checkout.create('doku_alfamart').mount('#doku_alfamart-container');
Customization
You can customize the expiry date of the virtual bank account (for bank transfers) or the voucher (for convenience store payments). By default, the validity period is 48 hours. To change the validity period, contact the Support Team.
You can change the language of the voucher to Indonesian by using the locale
id-ID. For instructions, refer to Localizing Components.
Test and go live
Use our test vouchers and card numbers to simulate the payments.
Check the status of the test payments in your Customer Area, under Transactions > Payments.
Before you can accept live payments, you need to submit a request for one or more Indonesian DOKU online banking or convenience store payment methods in your live Customer Area.