To ensure secure and reliable communication between your system and DANA's SNAP API, Bank Indonesia mandates the use of Asymmetric Signature Authentication. This method leverages cryptographic keys to verify the identity of the sender and protect data integrity during transactions.
Private Key: Used by you (the merchant) to digitally sign API requests.
Public Key: Shared with DANA to verify the authenticity of your requests.
By signing your request data with your private key, you provide a secure proof that the request originates from an authorized source. This process is critical to meeting the regulatory standards mandated by Bank Indonesia.
After successfully do the sandbox, the next process is going to production, you will need to generate your own keys for the production environment. You then submit your generated Public Key so DANA can verify your requests.
The following steps are used to generate the asymmetric key used in the signature process for Production environment.
You will receive two credentials: a Private Key and a Public Key.
The Private Key is used to authenticate and communicate securely with DANA. Keep this key confidential and do not share it.
The Public Key must be shared with DANA by uploading it through the Merchant Portal during form submission.
After successful submission, you will receive other credentials, including Merchant ID, Client ID (also known as X-PARTNER-ID), and Client Secret.
Skip this step if you're using DANA Library , as it handles this automatically
SNAP APIs require a specific signature string to be generated for a field called X-SIGNATURE. This signature will be validated by DANA using your public key to confirm the authenticity of the request.
Required Data
Format Example
X-CLIENT-KEY
Unique identifier for partner was generated by DANA, or known as clientId
82150823919040624621823174737537
X-TIMESTAMP
Transaction date time, in format YYYY-MM-DDTHH:mm:ss+07:00 (GMT+7)
2022-11-30T09:45:35+07:00
The following steps are used to generate the asymmetric key used in the signature process for Production environment:
Generate the signature by applying SHA-256 with RSA-2048 encryption (using PKCS#8 or PKCS#1 private key) to the string, then encode the result in Base64.
Generate the signature by applying SHA-256 with RSA-2048 encryption (using PKCS#8 or PKCS#1 private key) to the string, then encode the result in Base64.