Integration Guide
Learn more about how DOKU RDL can help you Power up your online payments here.
Integration steps
Here is the overview of how to integrate with DOKU RDL:
- Registration
- Disbursements
- Get RDL by ID
1. Registration
To register, you will need to hit this API through your Backend:
API Request
Type | Value |
---|---|
HTTP Method | POST |
API endpoint (Sandbox) | https://api-sandbox.doku.com/sac-rdl/v1/rdl-customers |
API endpoint (Production) | https://api.doku.com/sac-rdl/v1/rdl-customers |
Here is the sample of request header to create the payment:
Client-Id: MCH-0001-10791114622547
Request-Id: b6a465ea-bb65-48b2-a22b-3e8fb51cf22e
Request-Timestamp: 2020-08-11T08:45:42Z
Signature: HMACSHA256=vl9DBTX5KhEiXmnpOD0TSm8PYQknuHPdyHSTSc3W6Ps=
Request Header Explanation
Parameter | Description |
---|---|
Client-Id | Client ID retrieved from DOKU Back Office |
Request-Id | Unique random string (max 128 characters) generated from merchant side to protect duplicate request |
Request-Timestamp | Timestamp request on UTC time in ISO8601 UTC+0 format. It means to proceed transaction on UTC+7 (WIB), merchant need to subtract time with 7. Ex: to proceed transaction on September 22th 2020 at 08:51:00 WIB, the timestamp should be 2020-09-22T01:51:00Z |
Signature | Security parameter that needs to be generated on merchant Backend and placed to the header request to ensure that the request is coming from valid merchant. Please refer to this section to generate the signature |
Here is the sample of request body for RDL Registration:
{
"rdl_customer": {
"customer_id": "INVESTOR-0000100001",
"customer_name": "SEMAR DUADUA",
"address_city": "Kota Bandung",
"address_kecamatan": "Buah Batu",
"address_kelurahan": "Margasari",
"address_province": "Jawa Barat",
"address_rt_rw": "10/10",
"address_street": "Jl. Jalan",
"birth_date": "1989-09-01",
"birth_place": "Jakarta",
"education": "STRATA_SATU",
"email": "duadua@doku.com",
"gender": "FEMALE",
"home_phone_number": "0810101011",
"id_expiry_date": "2099-10-10",
"id_number": "1000000000000000",
"npwp_number" : "0111111111111111",
"job_code": "ENTREPRENEUR",
"marital_status": "MARRIED",
"mobile_phone_number": "0851231231",
"monthly_income": "1",
"mother_maiden_name": "mymom",
"nationality": "ID",
"office_phone_number": "02112311",
"religion": "ISLAM",
"resident_status": "R",
"source_of_fund": "SALARY",
"zip_code": "40286",
"title": "MS",
"open_account_reason": "INVESTMENT",
"selfie_photo": "(Base64)"
}
}
Request Body Explanation
Parameter | Type | Mandatory | Description |
---|---|---|---|
rdl_customer.customer_id | string | Mandatory | Unique ID of the investor provide by merchant Max Length: 100 |
rdl_customer.customer_name | string | Mandatory | Investor's full name Max Length: 100 |
rdl_customer.address_city | string | Mandatory | City, you can refer to List Of City Max Length: 50 |
rdl_customer.address_kecamatan | string | Mandatory | District (kecamatan) where Investor lives Max Length: 50 |
rdl_customer.address_kelurahan | string | Mandatory | Sub-District (kelurahan) where Investor lives Max Length: 50 |
rdl_customer.address_province | string | Mandatory | Province (provinsi) where Investor lives Max Length: 50 |
rdl_customer.address_rt_rw | string | Mandatory | RT/RW where Investor lives Max Length: 50 |
rdl_customer.address_street | string | Mandatory | Street address where Investor lives Max Length: 100 |
rdl_customer.birth_date | date | Mandatory | Investor's birth date |
rdl_customer.birth_place | string | Mandatory | Investor's birth place Max Length: 100 |
rdl_customer.education | string | Mandatory | Education, you can refer to List Of Education Max Length: 20 |
rdl_customer.email | string | Mandatory | Investor's email Max Length: 40 |
rdl_customer.gender | string | Mandatory | Investor's gender Max Length: 5 |
rdl_customer.home_phone_number | string | Optional | Investor's home phone number Max Length: 15 |
rdl_customer.id_expiry_date | date | Mandatory | Investor's ID Expired date |
rdl_customer.id_number | string | Mandatory | Investor's ID number Max Length: 50 |
rdl_customer.npwp_number | string | Mandatory | Investor's NPWP number Max Length: 50 |
rdl_customer.job_code | string | Mandatory | Job Code, you can refer to List Of Job Code Max Length: 50 |
rdl_customer.marital_status | string | Mandatory | Marital Status, you can refer to List Of Marital Status Max Length: 10 |
rdl_customer.mobile_phone_number | string | Mandatory | Investor's phone number Max Length: 15 |
rdl_customer.monthly_income | number | Mandatory | Monthly Income, you can refer to List Of Monthly Income Max Length: 2 |
rdl_customer.mother_maiden_name | string | Mandatory | Investor's mother maiden name Max Length: 50 |
rdl_customer.nationality | string | Mandatory | Investor's nationality in ISO for country code Max Length: 2 |
rdl_customer.office_phone_number | string | Optional | Investor's office phone number Max Length: 15 |
rdl_customer.religion | string | Optional | Religion, you can refer to List Of Religion Max Length: 15 |
rdl_customer.resident_status | string | Mandatory | Investor's resident status Max Length: 2 |
rdl_customer.source_of_fund | string | Mandatory | Source of fund Max Length: 20 |
rdl_customer.zip_code | string | Mandatory | Investor's Zip Code Max Length: 5 |
rdl_customer.title | string | Mandatory | Title, you can refer to List Of Title Max Length: 3 |
rdl_customer.open_account_reason | string | Mandatory | Reason, you can refer to List Of Reason Max Length: 15 |
rdl_customer.selfie_photo | varchar | Mandatory | Investor's selfie photo encoded with base64 |
API Response
After hitting the above API request, DOKU will give the response.
Type | Value |
---|---|
HTTP Status | 201 |
Result | CREATED |
Here is the sample response header:
Client-Id: MCH-0001-10791114622547
Request-Id: b6a465ea-bb65-48b2-a22b-3e8fb51cf22e
Response-Timestamp: 2020-08-11T08:45:42Z
Signature: HMACSHA256=1jap2tpgvWt83tG4J7IhEwUrwmMt71OaIk0oL0e6sPM=
Response Header Explanation
Parameter | Description |
---|---|
Client-Id | Same as the request |
Request-Id | Same as the request |
Response-Timestamp | Timestamp Response on UTC with format ISO8601 UTC+0 from DOKU |
Signature | Signature generated by DOKU based on the response body |
Here is the sample of response body:
{
"rdl_customer": {
"customer_id": "INVESTOR-0000100001",
"birth_place": "Jakarta",
"birth_date": "1989-09-01",
"gender": "FEMALE",
"marital_status": "MARRIED",
"nationality": "ID",
"resident_status": "R",
"religion": "ISLAM",
"education": "STRATA_SATU",
"mother_maiden_name": "mymom",
"address_street": "Jl. Jalan",
"address_rt_rw": "10/10",
"address_kelurahan": "Margasari",
"address_kecamatan": "Buah Batu",
"address_city": "Kota Bandung",
"address_province": "Jawa Barat",
"zip_code": "40286",
"mobile_phone_number": "0851231231",
"office_phone_number": "02112311",
"home_phone_number": "0810101011",
"id_number": "1000000000000000",
"id_expiry_date": "2099-10-10",
"job_code": "ENTREPRENEUR",
"monthly_income": 1,
"source_of_fund": "SALARY",
"title": "MS",
"open_account_reason": "INVESTMENT",
"npwp_number": "0111111111111111",
"company_id": "DOKU",
"account_id": 2340220322154948265107180133830000142742,
"customer_name": "SEMAR DUADUA"
},
"rdl_customer_info": {
"account_balance": 0,
"RDL_status": "PENDING"
}
}
Response Body Explanation
Parameter | Type | Mandatory | Description |
---|---|---|---|
rdl_customer.customer_id | string | Mandatory | Unique ID of the investor provide by merchant |
rdl_customer.customer_name | string | Mandatory | Investor's full name |
rdl_customer.address_city | string | Mandatory | City |
rdl_customer.address_kecamatan | string | Mandatory | District (kecamatan) where Investor lives |
rdl_customer.address_kelurahan | string | Mandatory | Sub-District (kelurahan) where Investor lives |
rdl_customer.address_province | string | Mandatory | Province (provinsi) where Investor lives |
rdl_customer.address_rt_rw | string | Mandatory | RT/RW where Investor lives |
rdl_customer.address_street | string | Mandatory | Street address where Investor lives |
rdl_customer.birth_date | date | Mandatory | Investor's birth date |
rdl_customer.birth_place | string | Mandatory | Investor's birth place |
rdl_customer.education | string | Mandatory | Education |
rdl_customer.email | string | Mandatory | Investor's email |
rdl_customer.gender | string | Mandatory | Investor's gender |
rdl_customer.home_phone_number | string | Optional | Investor's home phone number |
rdl_customer.id_expiry_date | date | Mandatory | Investor's ID Expired date |
rdl_customer.id_number | string | Mandatory | Investor's ID number |
rdl_customer.npwp_number | string | Mandatory | Investor's NPWP numberInvestor's NPWP number |
rdl_customer.job_code | string | Mandatory | Job Code |
rdl_customer.marital_status | string | Mandatory | Marital Status |
rdl_customer.mobile_phone_number | string | Mandatory | Investor's phone number |
rdl_customer.monthly_income | number | Mandatory | Monthly Income |
rdl_customer.mother_maiden_name | string | Mandatory | Investor's mother maiden name |
rdl_customer.nationality | string | Mandatory | Investor's nationality in ISO for country code |
rdl_customer.office_phone_number | string | Optional | Investor's office phone number |
rdl_customer.religion | string | Optional | Religion |
rdl_customer.resident_status | string | Mandatory | Investor's resident status |
rdl_customer.source_of_fund | string | Mandatory | Source of fund |
rdl_customer.zip_code | string | Mandatory | Investor's Zip Code |
rdl_customer.title | string | Mandatory | Title |
rdl_customer.open_account_reason | string | Mandatory | Reason |
rdl_customer.company_id | string | Mandatory | Investor's company id |
rdl_customer.account_id | string | Mandatory | Investor's account id provide by DOKU |
rdl_customer_info.account_balance | number | Mandatory | Investor's account balance |
rdl_customer_info.RDL_status | string | Mandatory | Investor's RDL account status |
2. Disbursement
To do disbursement, you will need to hit this API through your Backend:
API Request
Type | Value |
---|---|
HTTP Method | POST |
API endpoint (Sandbox) | https://api-sandbox.doku.com/sac-rdl/v1/rdl-disbursements |
API endpoint (Production) | https://api.doku.com/sac-rdl/v1/rdl-disbursements |
Here is the sample of request header for RDL Disbursement:
Client-Id: MCH-0001-10791114622547
Request-Id: b6a465ea-bb65-48b2-a22b-3e8fb51cf22e
Request-Timestamp: 2020-08-11T08:45:42Z
Signature: HMACSHA256=vl9DBTX5KhEiXmnpOD0TSm8PYQknuHPdyHSTSc3W6Ps=
Request Header Explanation
Parameter | Description |
---|---|
Client-Id | Client ID retrieved from DOKU Back Office |
Request-Id | Unique random string (max 128 characters) generated from merchant side to protect duplicate request |
Request-Timestamp | Timestamp request on UTC time in ISO8601 UTC+0 format. It means to proceed transaction on UTC+7 (WIB), merchant need to subtract time with 7. Ex: to proceed transaction on September 22th 2020 at 08:51:00 WIB, the timestamp should be 2020-09-22T01:51:00Z |
Signature | Security parameter that needs to be generated on merchant Backend and placed to the header request to ensure that the request is coming from valid merchant. Please refer to this section to generate the signature |
Here is the sample of request body to create the account:
{
"transaction": {
"id": "transaksi-sandbox-01",
"amount": 300000000,
"description": "testuat"
},
"source_account": {
"account_id": "2340211124151729152107164433893000196019"
},
"account_destination": {
"code": "BNINIDJA",
"account_bank_number": "0115471119",
"account_bank_name": "pk ROBERT NARO ROBERT NARO",
"address": "JAKARTA"
}
}
Request Body Explanation
Parameter | Type | Mandatory | Description |
---|---|---|---|
transaction.id | string | Mandatory | Unique ID provide by merchant, for reconciliation purpose. Allowed chars: alphabetic, numeric, special chars Allowed Symbol: -, :, ., _ Max Length: 64 |
transaction.amount | integer | Mandatory | Amount of funds merchant wish to transfer. Min amount : 10000 , Max amount : 999.999.999.999 |
transaction.description | string | Mandatory | Description of transfer, provide by merchant Max Length: 256 |
source_account.account_id | string | Mandatory | Account ID of your customer that given by DOKU when register for RDL Max Length: 100 |
account_destination.code | string | Mandatory | Account number of the destination you wish to transfer funds to Max Length: 50 |
account_destination.account_bank_name | string | Mandatory | Name of the account holder, as per the banks records. Used for verification and error/customer support scenarios Max Length: 50 |
account_destination.account_bank_number | string | Mandatory | Account number of the destination you wish to transfer funds to Max Length: 100 |
account_destination.address | string | Mandatory | Address/City name of the destination you wish to transfer funds to Max Length: 50 |
API Response
After hitting the above API request, DOKU will give the response.
Type | Value |
---|---|
HTTP Status | 200 |
Result | CREATED |
Here is the sample response header:
Client-Id: MCH-0001-10791114622547
Request-Id: b6a465ea-bb65-48b2-a22b-3e8fb51cf22e
Response-Timestamp: 2020-08-11T08:45:42Z
Signature: HMACSHA256=1jap2tpgvWt83tG4J7IhEwUrwmMt71OaIk0oL0e6sPM=
Response Header Explanation
Parameter | Description |
---|---|
Client-Id | Same as the request |
Request-Id | Same as the request |
Response-Timestamp | Timestamp Response on UTC with format ISO8601 UTC+0 from DOKU |
Signature | Signature generated by DOKU based on the response body |
Here is the sample of response body:
{
"transaction": {
"amount": 10000,
"description": "Test disbursement 100",
"status": "PENDING",
"create_date": "2021-04-16T01:24:13Z",
"update_date": "2021-04-16T01:24:13Z",
"id": "TRX-102"
},
"source_account": {
"account_id": "2226210210084257767192168810150000152843"
},
"account_destination": {
"account_bank_number": "1234567890",
"account_bank_name": "Arip Hidayat",
"code": "CENAIDJA",
"address": "JAKARTA"
}
}
Response Body Explanation
Parameter | Type | Mandatory | Description |
---|---|---|---|
transaction.id | string | Mandatory | Unique ID provide by merchant, for reconciliation purpose. |
transaction.amount | integer | Mandatory | Amount of funds merchant wish to transfer. |
transaction.description | string | Mandatory | Description of transfer, provide by merchant |
source_account.account_id | string | Mandatory | Account ID of your customer that given by DOKU when register for RDL |
account_destination.code | string | Mandatory | Account number of the destination you wish to transfer funds to |
account_destination.account_bank_name | string | Mandatory | Name of the account holder, as per the banks records. Used for verification and error/customer support scenarios |
account_destination.account_bank_number | string | Mandatory | Account number of the destination you wish to transfer funds to |
account_destination.address | string | Mandatory | Address/City name of the destination you wish to transfer funds to |
3. Get RDL by ID
To get RDL by ID, you will need to hit this API through your Backend:
API Response
Type | Value |
---|---|
HTTP Method | GET |
API endpoint (Sandbox) | https://api-sandbox.doku.com/sac-rdl/v1/rdl-customers/{id} |
API endpoint (Production) | https://api.doku.com/sac-rdl/v1/rdl-customers/{id} |
Here is the sample of request header to get RDL by ID:
Client-Id: MCH-0001-10791114622547
Request-Id: b6a465ea-bb65-48b2-a22b-3e8fb51cf22e
Request-Timestamp: 2020-08-11T08:45:42Z
Signature: HMACSHA256=vl9DBTX5KhEiXmnpOD0TSm8PYQknuHPdyHSTSc3W6Ps=
Request Header Explanation
Parameter | Description |
---|---|
Client-Id | Client ID retrieved from DOKU Back Office |
Request-Id | Unique random string (max 128 characters) generated from merchant side to protect duplicate request |
Request-Timestamp | Timestamp request on UTC time in ISO8601 UTC+0 format. It means to proceed transaction on UTC+7 (WIB), merchant need to subtract time with 7. Ex: to proceed transaction on September 22th 2020 at 08:51:00 WIB, the timestamp should be 2020-09-22T01:51:00Z |
Signature | Security parameter that needs to be generated on merchant Backend and placed to the header request to ensure that the request is coming from valid merchant. Please refer to this section to generate the signature |
Here is the sample of request body to create the account:
curl -L -X GET 'https://api-sandbox.doku.com/sac-rdl/v1/rdl-customers/2226210210084257767192168810150000152843' \
-H 'Request-Id;' \
-H 'Request-Timestamp;' \
-H 'Client-Id: MCH-0001-2768422848440' \
-H 'Signature: HMACSHA256=vl9DBTX5KhEiXmnpOD0TSm8PYQknuHPdyHSTSc3W6Ps='
API Response
After hitting the above API request, DOKU will give the response.
Type | Value |
---|---|
HTTP Status | 200 |
Result | SUCCESS |
Here is the sample response header:
Client-Id: MCH-0001-10791114622547
Request-Id: b6a465ea-bb65-48b2-a22b-3e8fb51cf22e
Response-Timestamp: 2020-08-11T08:45:42Z
Signature: HMACSHA256=1jap2tpgvWt83tG4J7IhEwUrwmMt71OaIk0oL0e6sPM=
Response Header Explanation
Parameter | Description |
---|---|
Client-Id | Same as the request |
Request-Id | Same as the request |
Response-Timestamp | Timestamp Response on UTC with format ISO8601 UTC+0 from DOKU |
Signature | Signature generated by DOKU based on the response body |
Here is the sample of response body:
{
"rdl_customer": {
"customer_id": "TESTUAT_12",
"email": "lililili@doku.com",
"birth_place": "BANDUNG",
"birth_date": "1989-01-01",
"gender": "FEMALE",
"marital_status": "MARRIED",
"nationality": "ID",
"resident_status": "R",
"religion": "ISLAM",
"education": "STRATA_SATU",
"mother_maiden_name": "mymom",
"address_street": "Jl. Jalan",
"address_rt_rw": "10/10",
"address_kelurahan": "Margasari",
"address_kecamatan": "Buah Batu",
"address_city": "Kota Bandung",
"address_province": "Jawa Barat",
"zip_code": "40286",
"mobile_phone_number": "0851231236",
"office_phone_number": "0221123166",
"home_phone_number": "0810101016",
"id_number": "3273225101890006",
"id_expiry_date": "2099-10-10",
"job_code": "ENTREPRENEUR",
"monthly_income": 1,
"source_of_fund": "SALARY",
"title": "MS",
"open_account_reason": "INVESTMENT",
"account_id": 2340211210152458174107167435645000170590,
"customer_name": "Lili Lili"
},
"rdl_customer_info": {
"registered_date": "2021-12-10T15:24:58Z",
"RDL_status": "PENDING"
}
}
Response Body Explanation
Parameter | Type | Mandatory | Description |
---|---|---|---|
rdl_customer.customer_id | string | Mandatory | Unique ID of the investor provide by merchant Allowed chars: alphabetic, numeric, special chars Max Length: 100 |
rdl_customer.customer_name | string | Mandatory | Investor's full name Allowed chars: alphabetic Max Length: 100 |
rdl_customer.address_city | string | Mandatory | City Allowed chars: alphabetic Max Length: 50 |
rdl_customer.address_kecamatan | string | Mandatory | District (kecamatan) where Investor lives Allowed chars: alphabetic, numeric, special chars Max Length: 50 |
rdl_customer.address_kelurahan | string | Mandatory | Sub-District (kelurahan) where Investor lives Allowed chars: alphabetic Max Length: 50 |
rdl_customer.address_province | string | Mandatory | Province (provinsi) where Investor lives Allowed chars: alphabetic Max Length: 50 |
rdl_customer.address_rt_rw | string | Mandatory | RT/RW where Investor lives Allowed chars: alphabetic, numeric, special chars Max Length: 50 |
rdl_customer.address_street | string | Mandatory | Street address where Investor lives Allowed chars: alphabetic Max Length: 50 |
rdl_customer.birth_date | date | Mandatory | Investor's birth date Allowed chars: alphabetic Max Length: 100 |
rdl_customer.birth_place | string | Mandatory | Investor's birth place Allowed chars: alphabetic, numeric, special chars Max Length: 100 |
rdl_customer.education | string | Mandatory | Education Allowed chars: alphabetic Max Length: 20 |
rdl_customer.email | string | Mandatory | Investor's email Allowed chars: alphabetic Max Length: 40 |
rdl_customer.gender | string | Mandatory | Investor's gender Allowed chars: alphabetic Max Length: 5 |
rdl_customer.home_phone_number | string | Optional | Investor's home phone number Allowed chars: alphabetic Max Length: 15 |
rdl_customer.id_expiry_date | date | Mandatory | Investor's ID Expired date Allowed chars: alphabetic Max Length: 20 |
rdl_customer.id_number | string | Mandatory | Investor's ID number Allowed chars: alphabetic Max Length: 50 |
rdl_customer.npwp_number | string | Mandatory | Investor's NPWP numberInvestor's NPWP number Allowed chars: alphabetic Max Length: 50 |
rdl_customer.job_code | string | Mandatory | Job Code Allowed chars: alphabetic Max Length: 50 |
rdl_customer.marital_status | string | Mandatory | Marital Status Allowed chars: alphabetic Max Length: 10 |
rdl_customer.mobile_phone_number | string | Mandatory | Investor's phone number Allowed chars: alphabetic Max Length: 15 |
rdl_customer.monthly_income | number | Mandatory | Monthly Income Allowed chars: number Max Length: 2 |
rdl_customer.mother_maiden_name | string | Mandatory | Investor's mother maiden name Allowed chars: alphabetic Max Length: 50 |
rdl_customer.nationality | string | Mandatory | Investor's nationality in ISO for country code Allowed chars: alphabetic Max Length: 2 |
rdl_customer.office_phone_number | string | Optional | Investor's office phone number Allowed chars: alphabetic Max Length: 15 |
rdl_customer.religion | string | Optional | Religion Allowed chars: alphabetic Max Length: 15 |
rdl_customer.resident_status | string | Mandatory | Investor's resident status Allowed chars: alphabetic Max Length: 2 |
rdl_customer.source_of_fund | string | Mandatory | Source of fund Allowed chars: alphabetic Max Length: 20 |
rdl_customer.zip_code | string | Mandatory | Investor's Zip Code Allowed chars: alphabetic Max Length: 5 |
rdl_customer.title | string | Mandatory | Title Allowed chars: alphabetic Max Length: 2 |
rdl_customer.open_account_reason | string | Mandatory | Reason Allowed chars: alphabetic Max Length: 15 |
rdl_customer_info.account_id | string | Mandatory | Investor's account id provide by DOKU |
rdl_customer_info.registered_date | date | Mandatory | Investor's register date in UTC time in ISO8601 UTC+7 format |
rdl_customer_info.RDL_status | string | Mandatory | Investor's RDL account status |