v1

latestOpenAPI 3.1.02026-07-26500375.1 KB

Create Virtual Account

The following endpoint creates a new virtual account

post/payments/va

Request body

bank_codestring required

The bank code for the Virtual Account. Supported Bank Codes: "BRI", "BCA", "MANDIRI", "PERMATA", "CIMB", "BNI", "NOBU"

namestring required

The name of the virtual account which will appear in ATM/Banking app. Example: "John's Virtual Account"

is_closedboolean

Whether account can accept open(any amount) or closed(specific amount). Example: true or false

amountstring

Specify amount to be paid to va when is_closed=true. Example: "12000.12"

expiry_minutesinteger

Number of minutes left till expiry from now. maximum: 15768000 minutes

account_suffixstring

Account suffix for the Virtual Account. If not provided, a random suffix will be automatically generated for the virtual account number.

is_reusableboolean

Whether multiple payments can be used for a particular VA. Example: true or false

va_ref_idstring

A reference ID which the merchant wants to use for a specific VA. Example: "VA_XYZ_1234"

auto_disable_after_paymentboolean

Disable a reusable VA temporarily after a payment. Patch API can be used to enable it again after changing some parameters. Example: true or false

Response

200

Example response

{
  "data": {
    "customer_id": "cus_abcdefghijklm",
    "virtual_account": {
      "id": "va_abcdefghjklmn",
      "bank_code": "PERMATA",
      "account_number": "1234006781234569",
      "name": "Dpay Jane Doe",
      "is_closed": true,
      "amount": 20000,
      "currency": "IDR",
      "customer_id": "cus_abcdefghijklm",
      "created_at": "2025-03-05T02:39:09.738801Z",
      "expiry_at": "2025-03-05T12:39:09.744Z",
      "va_ref_id": "VA_123"
    }
  }
}