Dark Mode

Static VA Fetch By ID API

The following endpoint retrieves the details of a single Virtual Account


Run in Postman

Path parameters

Fieldis required?Description
idmandatoryinteger Unique identifier of the Virtual Account to be retrieved

Sample Request (cURL)

curl -X GET \
https://api.durianpay.id/v1/payments/va/static/va_yiCTj9JRaP9307 \
-H 'authorization: [Base64({Your_Server_Key}:)]' \
-H "content-type: application/json"

Sample Response

    "data": {
        "virtual_account": {
            "id": "va_iz2tvf9UiH4986",
            "bank_code": "BRI",
            "account_number": "1236170050000007",
            "name": "Hello Virtual Account",
            "is_closed": true,
            "amount": 12346,
            "currency": "IDR",
            "customer_id": "cus_vS2R7NX08l7424",
            "is_sandbox": false,
            "created_at": "2022-03-01T07:37:35.313679Z",
            "expiry_at": "2024-01-24T12:47:35.385003Z",
            "metadata": {}
        "virtual_account_status": "VirtualAccountSuccess",
        "customer": {
            "id": "cus_vS2R7NX08l7424",
            "customer_ref_id": "27aa09d7-dd63-4053-94a4-d3ebb0e1e68b",
            "given_name": "Paul",
            "middle_name": "K",
            "sur_name": "Rudd",
            "email": "paulrudd@gmail.com",
            "mobile": "999999999"

Authorization Errors

Authorization errors are errors that occur during authorization. The status code returned is usually 401

    "error": "invalid Authorization header in request",
    "error_code": "DPAY_UNAUTHORIZED_ACCESS"

Sample Error

The possible error status codes are: 404, 500

    "error": "sql: no rows in result set",
    "error_code": "DPAY_VA_NOT_FOUND",
    "request_id": "dp_d3HX9S5W0r4989"