DOKU Malaysia API Reference
Home
Products
Products
  • Checkout
  • Payment
  • Cards Payment
DOKU Docs
Home
Products
Products
  • Checkout
  • Payment
  • Cards Payment
DOKU Docs
  1. Host-to-Host Payment
  • Introduction
  • Getting Started
    • Create Account
    • Make your first API call
    • Authentication & API Keys
  • Checkout
    • Overview
    • Create Checkout
      POST
    • Retrieve Checkout Status
      GET
  • Payment
    • Overview
    • Create Payment
      POST
    • Get Bank List - FPX
      POST
    • Retrieve Payment Status
      GET
  • Cards Payment
    • Overview
    • Payment Form
      • Request Payment
    • Host-to-Host Payment
      • Check Three D Secure
        POST
      • Charge Payment
        POST
      • Capture Authorized Payment
        POST
    • Request Refund
      POST
    • Unbind Token
      POST
    • Check Status
      GET
  • Payout
    • Overview
    • Inquire Beneficiary Account
      POST
    • Send Payout
      POST
    • Read Payout Status
      GET
    • Read Available Balance
      GET
  • Notification
    • Overview
    • Retry Notification
    • Setup Notification URL
    • Sample Notification - Global
    • Sample Notification - Cards
  • Technical Reference
    • Authentication & Integrity
    • Idempotency
    • Data Type
    • Order & Transaction Status
    • Postman Collection
    • Response Code
      • Error Code
      • Payout Response Code
      • Credit Card Acquirer Response Code
    • API Version
      • Create Checkout
      • Create Payment
      • Get Bank List - FPX
      • Retrieve Checkout
      • Retrieve Payment
      • Inquire Beneficiary Account
      • Send Payout
      • Read Payout Status
      • Read Available Balance
    • Signature
      • Signature - Global
        • Prepare Signature Component
        • Generating Signature
        • Validating Signature
        • Sample Code
      • Signature - Cards Payment API
        • Signature Component from Response Header
        • Signature from API Get Method
        • Sample Code
        • Signature Component from Request Header
  1. Host-to-Host Payment

Check Three D Secure

POST
/check-three-d-secure
Endpoint for H2H merchants to check 3D Secure eligibility on a credit card. Returns an authentication URL used to redirect the consumer to the 3DS challenge page.
Environment
Sandbox - https://api-sandbox.doku.com
Production - https://api.doku.com

Request

Authorization
API Key
Add parameter in header
Signature
Example:
Signature: ********************
API Key
Add parameter in header
Client-Id
Example:
Client-Id: ********************
Basic Auth
Send your HTTP requests with an
Authorization
header that contains the word Basic followed by a space and a base64-encoded string username:password
Example:
Authorization: Basic *****************
or
Header Params

Body Params application/jsonRequired

Examples
{
    "order": {
        "amount": 150000,
        "currency": "MYR",
        "invoice_number": "INV-2024-001",
        "descriptor": "DOKU Payment"
    },
    "card": {
        "number": "4111111111111111",
        "expiry": "1225",
        "cardholder_name": "John Doe",
        "cardholder_email_address": "john.doe@example.com",
        "cardholder_phone_number": "081234567890"
    },
    "three_d_secure": {
        "callback_url_success": "https://merchant.com/payment/success",
        "callback_url_failed": "https://merchant.com/payment/failed"
    },
    "payment": {
        "type": "SALE"
    },
    "customer": {
        "id": "CUST-001",
        "name": "John Doe",
        "email": "john.doe@example.com",
        "phone": "081234567890"
    }
}

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
cURL
curl --location '/check-three-d-secure' \
--header 'Request-Id: a1b2c3d4-e5f6-7890-abcd-ef1234567890' \
--header 'Request-Timestamp: 2024-01-15T10:30:00Z' \
--header 'Signature: <api-key>' \
--header 'Client-Id: <api-key>' \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "order": {
        "amount": 150000,
        "currency": "MYR",
        "invoice_number": "INV-2024-001",
        "descriptor": "DOKU Payment"
    },
    "card": {
        "number": "4111111111111111",
        "expiry": "1225",
        "cardholder_name": "John Doe",
        "cardholder_email_address": "john.doe@example.com",
        "cardholder_phone_number": "081234567890"
    },
    "three_d_secure": {
        "callback_url_success": "https://merchant.com/payment/success",
        "callback_url_failed": "https://merchant.com/payment/failed"
    },
    "payment": {
        "type": "SALE"
    },
    "customer": {
        "id": "CUST-001",
        "name": "John Doe",
        "email": "john.doe@example.com",
        "phone": "081234567890"
    }
}'

Responses

🟢200
application/json
Success - returns authentication URL for the 3DS challenge
Bodyapplication/json

Example
{
    "order": {
        "amount": 150000,
        "currency": "MYR",
        "invoice_number": "INV-2024-001"
    },
    "three_d_secure": {
        "authentication_id": "AUTH-20240115-001",
        "authentication_url": "https://3ds.doku.com/authenticate?id=AUTH-20240115-001",
        "three_ds_version": "2.0"
    }
}
🟠400
🟠409
🟠412
Modified at 2026-10-05 10:27:25
Previous
Request Payment
Next
Charge Payment
Built with