API Reference
DOKU DocsChangelogDOKU Github
  • Getting Started with DOKU API
    • User Registration
    • Idempotency Request
    • Notification
      • Setup Notification URL
      • HTTP Notification Sample for SNAP
      • HTTP Notification Sample - Non SNAP
      • Best Practice
      • Retry Notification
      • Override Notification URL
    • Signature Component
      • Non-SNAP
        • Signature Component from Request Header
        • Signature Componen from Response Header
        • Signature from API Get Method
        • Sample Code
      • SNAP
        • Symmetric Signature
        • Asymmetric Signature
    • Response Code
      • HTTP Status and Case Code
    • Check Status API
      • Non-SNAP
      • SNAP
    • Retrieve Payment Credential
  • Accept Payment
    • DOKU Checkout
      • Integration Guide
        • Backend Integration
        • Frontend Integration
        • Simulate payment and Notification
      • Supported Payment Methods
      • Status Order
      • Additional Feature
        • Tokenization
        • Promo on DOKU Checkout Page
        • Track Campaign Source on Google Analytics
      • Checkout Settings
    • Direct API
      • Non-SNAP
        • Cards
          • Payment Page Integration Guide
          • Host-To-Host Integration Guide
          • Mastercard Automatic Billing Updater (ABU) Integration Guide
            • Backend Integration
        • e-Wallet
          • Overview
          • DOKU e-Wallet
          • OVO Push Payment
          • LinkAja
        • Paylater
          • Akulaku
          • Kredivo
          • Indodana
        • Digital Banking
          • Jenius Pay
        • Convenience Store
          • Alfa Group
          • Indomaret
      • SNAP
        • Integration Guide
          • Get Token API
            • B2B
            • B2B2C
          • Virtual Account
            • CIMB Virtual Account
            • BSI Virtual Account
            • BCA Virtual Account
            • BNC Virtual Account
            • BNI Virtual Account
            • Mandiri Virtual Account
            • BRI Virtual Account
            • BTN Virtual Account
            • Permata Virtual Account
            • Danamon Virtual Account
            • BSS Virtual Account
          • E-Wallet
            • DOKU Wallet
            • DANA
            • OVO
            • ShopeePay
          • Direct Debit
            • Allo Bank Direct Debit
            • BRI Direct Debit
            • CIMB Direct Debit
            • Mandiri Direct Debit
          • Kartu Kredit Indonesia Cepat Secure(KKI CPTS)
            • Host to Host Integration
          • QRIS
    • Finance and Settlement
      • Split Settlement
      • Custom Settlement Report
      • Hold and Release Settlement
      • Bulk Registration Bank
    • Test on DOKU Demo Site
    • DOKU Payment Simulator
  • Developer Kit
    • Postman Collection
    • Libraries and SDK
  • Wallet As A Service
    • Sub Account
  • Partnership
    • Partner API
      • Check Requirements API
      • Generate Token API
      • Upload File API
      • Business Registration API
      • Create Business Lite API
      • Get Business Data API
  • Payout
    • Kirim DOKU
  • FLEXIBILL
    • Account Billing
      • Batch Upload
    • DOKU Biller
      • Response Code
      • Samples
  • PAYCHAT API
    • Send WhatsApp Message
  • Archive
    • Non-SNAP
      • Tokenization V1
      • e-Wallet
        • OVO Recurring
        • OVO Open API
    • SNAP
      • Virtual Account
        • BCA v1.0
        • BRI v1.0
        • BNI v1.0
        • BNC v1.0
        • Mandiri v1.0
        • BTN v1.0
        • Permata v1.0
        • Danamon Virtual Account
      • e-Wallet
        • OVO Open API
        • DANA
        • ShopeePay
      • Direct Debit
        • CIMB Direct Debit
        • BRI Direct Debit
        • Allobank
Powered by GitBook

DOKU API

  • Legacy Documentation
On this page

Was this helpful?

  1. Accept Payment
  2. Direct API
  3. Non-SNAP
  4. e-Wallet

LinkAja

PreviousOVO Push PaymentNextPaylater

Last updated 7 months ago

Was this helpful?

DOKU has partnered with various e-money providers and one of them is Link Aja to provide E-Money Payment. Learn more about how DOKU can help you integrate with Link Aja here.


Integration steps

Here is the overview of how to integrate with Link Aja:

  1. Generate request

  2. Complete payment in Link Aja App

  3. Acknowledge payment result

Link Aja Sequence Diagram


1. Generate Request

To generate request, 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/linkaja-emoney/v2/ServiceRequestPayment

API endpoint (Production)

https://api.doku.com/linkaja-emoney/v2 /ServiceRequestPayment

Here is the sample of request header to create an order:

Client-Id: OCO-0203-1676104296656
Request-Id: 24bb5232-3fe6-47a5-b0b0-d0fc3c6b5fdb
Request-Timestamp: 2023-06-08T08:50:00Z
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

Here is a sample of request body to create an order:

{
    "order": {
        "invoice_number": "INV-20210124-0001",
        "amount": 150000,
        "callback_url": "https://merchant.com/return-url",
        "line_items": [
             {
               "name":" Roti",
               "price": 10000,
               "quantity": 1
             } 
        ]
    },
    "customer": {
            "name": "Jessica Tessalonika",
            "email": "example@doku.com",
            "phone" : "081112345678"
    },
    "additional_info": {
        "override_notification_url": "https://another.example.com/payments/notifications"
    }
}

Request Body Explanation

Parameter
Type
Mandatory
Description

order.invoice_number

string

Mandatory

Merchant's designated transaction invoice number Allowed chars: alphabetic, numeric, special chars

order.amount

number

Mandatory

Transaction amount Allowed chars: numeric

order.callback_url

string

Mandatory

Merchant URL that will redirected to after the order completed

order.line_items

string

Mandatory

Information about customer's basket (item's name, price, and quantities)

customer.name

string

Optional

Information about customer's name

customer.email

string

Optional

Information about customer's email

customer.phone

number

Optional

Information about customer's phone

additional_info.override_notification_url

string

Optional

API Response

After hitting the above API request, DOKU will give the response.

Type
Value

HTTP Status

200

Result

SUCCESS

Client-Id: MCH-0001-10791114622547
Request-Id: 24bb5232-3fe6-47a5-b0b0-d0fc3c6b5fdb
Response-Timestamp: 2021-07-09T02:05:14Z
Signature: HMACSHA256=9UPUFzOqJc47aJzD9ESOTcWg6TMsg3mqSP+DnUO8ENE=

Response Header Explanation

Parameter
Description

Client-Id

Same as the request

Request-Id

Same as the request

Request-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:

{
"order": {
        "invoice_number": "LINKAJA23052595",
        "amount": "10000.00"
    },
    "emoney_configuration": {
        "identifier": [
            {
                "name": "TERMINAL_ID",
                "value": "e2etest"
            } 
        ]
    },
    "emoney_payment": {
        "redirect_method_http": "POST",
        "redirect_url_http": "https://api-uat.doku.com/doku/simulator/v1/linkaja/redirectPostToPost",
        "redirect_parameter": [
            {
                "name": "Message",
                "value": 
                "cXAwdzcvd3VEeDlRTzl0V1g1NGZyMmpQbFBPMDQxaHpyclNLazdlV09PTUZ1Z1lJaDlscjU1QmZNS2VPTTNiOGpFY3Mzbmp1dStqUjRWL3FaTGRsekVQWVF3YWRRUVQ2UzZsQkFRSzl2ek1zbERWQWtEY01EV0xpaTYrcnRYVUJmSkYvc0tXbGpRWXFCMHVMVHpKMXZTRSt2eTY5K2lOQ3k4aFdCTTBUc2ZGaTlYaWdQZ1JGZ2VjWTNaUlBNT0JCaTNnUzdhMitrNkRlY2hZMWh1R2xpQWtLMTlrLzIyWkxLWnNxQXZTU1VkdllqV0FmeGtqVTVzUjM3ZUIvSE9mag=="
            } 
        ],
        "status": "PENDING"
    },
    "additional_info": {
        "override_notification_url": "https://another.example.com/payments/notifications"
    }
}

Response Body Explanation

Parameter
Type
Mandatory
Description

order.invoice_number

string

Mandatory

Same as the request

order.amount

number

Mandatory

Same as the request

emoney_configuration.identifier

string

Mandatory

Merchant identifier by Link Aja Max length: 15 Allowed chars: alphabetic, numeric

emoney_payment.redirect_method_http

string

Mandatory

HTTP redirect method by Link Aja Max length: 8 Allowed chars: alphabetic, numeric

emoney_payment.redirect_url_http

string

Mandatory

Merchant's redirect URL

emoney_payment.status

string

Mandatory

Status of the create order request Possible value: PENDING, SUCCESS.

emoney_payment.parameter

string

Mandatory

Custom message

additional_info.override_notification_url

string

Optional

Same as the request

2. Complete Payment in Link Aja

After the customer completed the payment, they will be redirected to the defined redirect.url that you set on the API request.

3. Acknowledge payment result

DOKU will send HTTP Notification to your defined Notification URL. Learn how to handle the notification from DOKU:


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 to generate the signature

This parameter is intended to override the configured Notification URL with another URL. Click for more information.

Handling DOKU HTTP Notification
this section
here