Get Transaction History

Retrieve transaction history for a virtual account.

GET /v1/virtual-account/transactions

Query Parameters

Parameter Type Required Description
accountId integer Yes Virtual account ID
type string No Filter by type: CREDIT or DEBIT
fromDate string No Start date (ISO 8601)
toDate string No End date (ISO 8601)
page integer No Page number (default: 1)
limit integer No Items per page (default: 20, max: 100)

Example Request

curl -X GET "https://api.esca.finance/v1/virtual-account/transactions?accountId=12345&page=1&limit=20" \
  -H "X-Api-Key: your_api_key_here"

Example Response

{
  "status": true,
  "data": {
    "transactions": [
      {
        "id": 98765,
        "type": "CREDIT",
        "service": "DEPOSIT",
        "amount": 50000.00,
        "balance": 50000.00,
        "comment": "Transfer from John Doe",
        "createdAt": "2026-01-18T09:00:00.000Z"
      },
      {
        "id": 98766,
        "type": "DEBIT",
        "service": "TRANSFER",
        "amount": 10000.00,
        "balance": 40000.00,
        "comment": "Payment for services",
        "createdAt": "2026-01-18T10:30:00.000Z"
      }
    ],
    "pagination": {
      "page": 1,
      "limit": 20,
      "total": 2,
      "totalPages": 1
    }
  }
}