Direct Debit

API Corporate pay bill is service to pay goods and services for corporate like utility bills, invoice payments, etc. The company sends billing instructions via API for payment quick, easy and safe to the biller.

Use Case for Direct Debit Registration

Krungsri provide new Payment Gateway direct debit to e-commerce partners. To have ability to receive direct debit payment real-time from registered BAY accounts via existing regirstration 5 channels (Branch, ATM, KMA, KOL, LOC).

“Online Direct Debit Registration ”  To have ability to receive direct debit payment real-time from registered BAY accounts via KMA, KOL, ATM channels. Biller can deduct BAY account real-time on biller’s application and web-view.

Online Direct Debit Registration
This feature provides a customer with authentication options to complete online direct debit registration via 3 channels.

  • Krungsri Mobile App (KMA)

This option allows customer to authenticate identity by KMA PIN.

  • Krungsri Online (KOL)

This option allows customer to authenticate identity by KOL Username & Password.

  • Krungsri ATM (ATM)

This option allows customer to authenticate identity using personal and BAY ATM / Debit Card information.

  User journey Direct Debit Registration
  •  Direct Debit Registration with Krungsri Mobile App (KMA)
 
  • Direct Debit Registration with Krungsri Online(KOL)
 
  • Direct Debit Registration with Krungsri ATM(ATM)

 

Use Case for Direct Debit Transaction

This feature provides partners to generate charge direct to payer’s account via API Transaction feature enables e-commerce partners to design their own customer experiences in order to provide customized journey to their customersHi_flow_2.png 

  • Drawer generates request transaction using Cashlink or API.
  • ​BAY automatically debits the payer's account.
  • BAY transfers money to biller account and notify the result of the transaction.

User journey Direct Debit Transaction

Step4-(1).png

    Sending Registration - WebView
 
  • An application submits request using Register Prepare API, then oauth_context_id will be returned.
  • An application submits request using Register Authorize API, then URL will be returned to redirect to BAY webview.
  • Navigate user to BAY webview.
  • Instruction will be sent to backend system for process register transaction
    • If transaction is success, a paymentToken will be provided as a unique reference for registration.
    • If transaction fails, and error code and description will be returned for reference.
  • The Backend Callback API can be used to callback registration information to partner then will be returned a response with http status
Sending Registration - Deep Link
 
  • An application submits request using Get KMA Deep link API, then KMA deep link will be returned.
  • Navigate user to KMA Application.
  • Instruction will be sent to backend system for process register transaction
    • If transaction is success, a paymentToken will be provided as a unique reference for registration. paymentToken will be uses as a mandatory for payment transaction request.
    • If transaction fails, and error code and description will be returned for reference.
  • After complete registration process, KMA application navigate user to Partner Application
Direct Debit Register Prepare
 
  • An application submits request using Register Prepare API, then oauth_context_id will be returned.
Direct Debit Register Authorize
 
  • An application submits request using Register Authorize API, then URL will be returned to redirect to BAY webview.
Direct Debit Register Backend Call Back
 
  • The Backend Callback API can be used to callback registration information to partner then will be returned a response with http status.
Direct Debit Register Token Status Inquiry
 
  • This API can be called after transaction was made, and there is a need to send additional advice to specified recipients.
Direct Debit Register Inquiry
 
  • An application submits request using Register Inquiry API.
Direct Debit Cancel Register
 
  • An application submits request using Cancel Register API.
Direct Debit Get KMA Deep link
 
  • An application submits request using Get KMA Deep link API, then KMA deep link will be returned.
Direct Debit Transaction
 
  • An application submits request using Register Prepare API, then oauth_context_id will be returned.
  • An application submits request using Register Authorize API, then URL will be returned to redirect to BAY webview.
  • Navigate user to BAY webview.
  • Instruction will be sent to backend system for process register transaction
    • If transaction is success, a paymentToken will be provided as a unique reference for registration.
    • If transaction fails, and error code and description will be returned for reference.
  • The Backend Callback API can be used to callback registration information to partner then will be returned a response with http status
Direct Debit Transaction Status Inquiry
 
  • An application submits request using Get KMA Deep link API, then KMA deep link will be returned.
  • Navigate user to KMA Application.
  • Instruction will be sent to backend system for process register transaction
    • If transaction is success, a paymentToken will be provided as a unique reference for registration. paymentToken will be uses as a mandatory for payment transaction request.
    • If transaction fails, and error code and description will be returned for reference.
  • After complete registration process, KMA application navigate user to Partner Application
Direct Debit Transaction Inquiry
 
  • An QR Parser API to be used to determinded QR type and identify information.
Direct Debit Schedule Submission
 
  • Payer generates request transaction using Open API (QR Transaction Initiation)
    •  Biller and payment information will be included in the QR string being used
    • Additional information will still be required such as payer account information and associated technical details for calling an API
  •  Validation will take place which may include input fields, payer, and biller information validation. If transaction fails at this step, information will not be recorded in the system.
  • Instruction will be sent to backend system for initiating a transaction with biller
    • If initiation is successful, a paymentReferenceIdentification will be provided as a unique reference for this transaction. An Inquiry API can be called from this point onwards to fetch transaction status
    • If initiation fails, an error code and description will be returned for reference
Direct Debit Schedule Inquiry
 
  • An inquiry API can be used to inquire transaction status
Direct Debit Schedule Cancellation
 
  • This API can be called after transaction was made, and there is a need to send additional advice to specified recipients.

• Related API

-

Seq No. API Name API Endpoints
AAuthentication - Register additional oauth 2.0 contextPOST /rest/api/v1/authorization/prepareOAuthContext
BCorporate Direct Debit Token Status InquiryPOST /rest/api/v1/corporateServices/directDebit/tokenStatus/inquiry
CCorporate Direct Debit Token InquiryPOST /rest/api/v1/corporateServices/directDebit/token/inquiry
DCorporate Direct Debit Token CancellationPOST /rest/api/v1/corporateServices/directDebit/token/cancellation
ECorporate Direct Debit Payment Token Registration with KMAPOST /rest/api/v1/corporateServices/directDebit/getKMADeeplink
FCorporate Direct Debit RealTime Transaction PaymentPOST /rest/api/v1/corporateServices/directDebit/realTime/transaction/payment
GCorporate Direct Debit Transaction Status InquiryPOST /rest/api/v1/corporateServices/directDebit/transactionStatus/inquiry
HCorporate Direct Debit Transaction InquiryPOST /rest/api/v1/corporateServices/directDebit/transactionDetails/inquiry
ICorporate Direct Debit Schedule SubmissionPOST /rest/api/v1/corporateServices/directDebit/schedule/submission
JCorporate Direct Debit Schedule InquiryPOST /rest/api/v1/corporateServices/directDebit/schedule/inquiry
KCorporate Direct Debit Schedule CancellationPOST /rest/api/v1/corporateServices/directDebit/schedule/cancellation

Technical Detail

Sample of request message can be as following
 

Request parameter : Direct Debit Registration

paymentTokenStatus Start create date. endCreateDateTime is required if startCreateDateTime is provided. All transactions under the range of specified startCreateDateTime and endCreateDateTime will be returned. Expected format in RFC3339. For example, YYYY-MM-DDThh:mm:ssZ (UTC) or YYYY- MM-DDThh:mm:ss+07:00 (TH Time zone)
drawerAccountNumber String of characters (mainly numbers) used to identify an end-user account for transferred (sender). Expected valued is 10- Numeric value to represent end-user’s account number.
startCreateDateTime  Start create date. endCreateDateTime is required if startCreateDateTime is provided.
endCreateDateTime End create date. startCreateDateTime is required if endCreateDateTime is provided.
journeyIdentifier UUID that generated from Microsite (oauth_context_id)or Online channel (system generated).
         
Sample request
 : Direct Debit Registration        
{
 
  "paymentTokenStatus": "ACTV",
  "drawerAccountNumber": "7770011555",
  "startCreateDateTime": "2020-08-15T00:00:00+07:00",
  "endCreateDateTime": "2020-08-16T00:00:00+07:00",
  "journeyIdentifier": "68c971e1-6652-48f9-af3a-0f6c70bde952"

}
     
Request parameter : Direct Debit Transaction
paymentTokenStatus Start create date. endCreateDateTime is required if startCreateDateTime is provided. All transactions under the range of specified startCreateDateTime and endCreateDateTime will be returned. Expected format in RFC3339. For example, YYYY-MM-DDThh:mm:ssZ (UTC) or YYYY- MM-DDThh:mm:ss+07:00 (TH Time zone)
transactionIdentification unique identification (UUID) to identify direct debit transaction
creditorAccountNumber String of characters (mainly numbers) used to identify a partner account for transferred.
payerInformation Payer's information.
payerInformation.paymentToken Reference surrogate value of the account number.
transactionInformation  Transaction information 
transactionInformation.transactionType Identifier of transaction type 
transactionInformation.re ferenceNumber1  eference issued by a party to identify an instruction, transaction or a message 
transactionInformation.re ferenceNumber2  Reference issued by a party to identify an instruction, transaction or a message 
transactionInformation.pa ymentInstrument  Type of payment instrument 

Sample request  : Direct Debit Transaction  
{
  “transactionIdentification”: “071f2a78-a77b-4e45-91ba-4bd96d5bcde9”,
  “creditorAccountNumber”: “0457262823”,
  “payerInformation”: {
    “paymentToken”: “06252dbc-0a4c-437f-b718-f2aa836b10b3”
  },
  “transactionInformation”: {
    “transactionType”: “REALTIME”,
    “referenceNumber1”: “REF1”,
    “referenceNumber2”: “REF2”,
    “paymentInstrument”: “DDEB”,
    “paymentAmount”: 5000.00,
    “annotation”: “This is remark for this transaction” 
  }
}