> ## Documentation Index
> Fetch the complete documentation index at: https://docs.usezentra.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Virtual Account

> GET /api/v1/virtual-accounts/{id} - Retrieve a virtual account

Retrieve a specific virtual account for the authenticated tenant.

## Endpoint

```
GET /api/v1/virtual-accounts/{id}
```

## Path Parameters

<ParamField path="id" type="string" required>
  Virtual account ID.
</ParamField>

## Response Fields

<ResponseField name="id" type="string">
  Unique identifier for the virtual account.
</ResponseField>

<ResponseField name="tenant_id" type="string">
  Tenant that owns the account.
</ResponseField>

<ResponseField name="customer_id" type="string">
  Customer assigned to the account.
</ResponseField>

<ResponseField name="account_number" type="string">
  Provider account number.
</ResponseField>

<ResponseField name="account_name" type="string">
  Name on the account.
</ResponseField>

<ResponseField name="bank_code" type="string">
  Provider bank code or slug.
</ResponseField>

<ResponseField name="bank_name" type="string">
  Human-readable bank name.
</ResponseField>

<ResponseField name="provider" type="string">
  Provider selected for the account.
</ResponseField>

<ResponseField name="status" type="string">
  Current account status.
</ResponseField>

<ResponseField name="account_type" type="string">
  Account type stored by the service.
</ResponseField>

<ResponseField name="total_received_minor" type="number">
  Total inbound amount recorded on this account, in minor units.
</ResponseField>

<ResponseField name="transaction_count" type="number">
  Number of recorded inbound credits.
</ResponseField>

<ResponseField name="metadata" type="object | null">
  Account metadata.
</ResponseField>

<ResponseField name="expires_at" type="string | null">
  Provider expiry timestamp if the account allocation is temporary.
</ResponseField>

<ResponseField name="created_at" type="string">
  ISO 8601 creation timestamp.
</ResponseField>

<ResponseField name="updated_at" type="string">
  ISO 8601 last-update timestamp.
</ResponseField>

## Example Request

<CodeGroup>
  ```javascript JavaScript theme={null}
  const account = await client.virtualAccounts.get('va_abc123xyz');

  console.log(`Account: ${account.accountNumber}`);
  console.log(`Received: ${account.totalReceivedMinor}`);
  console.log(`Status: ${account.status}`);
  ```

  ```python Python theme={null}
  account = client.virtual_accounts.get('va_abc123xyz')

  print(f"Account: {account.account_number}")
  print(f"Received: {account.total_received_minor}")
  print(f"Status: {account.status}")
  ```

  ```php PHP theme={null}
  $account = $client->virtualAccounts->get('va_abc123xyz');

  echo "Account: {$account->account_number}\n";
  echo "Received: {$account->total_received_minor}\n";
  echo "Status: {$account->status}";
  ```

  ```bash cURL theme={null}
  curl https://api.usezentra.com/api/v1/virtual-accounts/va_abc123xyz \
    -H "Authorization: Bearer YOUR_SECRET_KEY"
  ```
</CodeGroup>

## Example Response

```json theme={null}
{
  "data": {
    "id": "va_abc123xyz",
    "tenant_id": "tenant_123",
    "customer_id": "cus_1234567890",
    "account_number": "0123456789",
    "account_name": "John Doe",
    "bank_code": "wema-bank",
    "bank_name": "Wema Bank",
    "provider": "paystack_dva",
    "status": "active",
    "account_type": "standard",
    "total_received_minor": 500000,
    "transaction_count": 5,
    "metadata": {
      "purpose": "collections",
      "tier": "premium"
    },
    "expires_at": null,
    "created_at": "2026-03-07T10:30:00Z",
    "updated_at": "2026-03-07T15:45:00Z"
  },
  "meta": {
    "timestamp": "2026-03-07T15:45:00Z",
    "requestId": "req_123"
  }
}
```

## Error Responses

<ResponseExample>
  ```json Not Found theme={null}
  {
    "error": {
      "code": "NOT_FOUND",
      "message": "Account not found",
      "details": null
    },
    "meta": {
      "path": "/api/v1/virtual-accounts/va_missing",
      "method": "GET"
    }
  }
  ```

  ```json Unauthorized theme={null}
  {
    "error": {
      "code": "UNAUTHENTICATED",
      "message": "Authentication required",
      "details": null
    },
    "meta": {
      "path": "/api/v1/virtual-accounts/va_abc123xyz",
      "method": "GET"
    }
  }
  ```
</ResponseExample>

## Use Cases

<AccordionGroup>
  <Accordion title="Display Account Details">
    Show customers their account number and bank details in your app.
  </Accordion>

  <Accordion title="Verify Status">
    Confirm whether an account is `active`, `frozen`, `closed`, or `expired` before presenting it to users.
  </Accordion>

  <Accordion title="Track Credits">
    Use `total_received_minor` and `transaction_count` for reporting and reconciliation.
  </Accordion>
</AccordionGroup>

## Next Steps

<CardGroup cols={2}>
  <Card title="List Accounts" icon="list" href="/api-reference/virtual-accounts/list">
    View all virtual accounts
  </Card>

  <Card title="Close Account" icon="xmark" href="/api-reference/virtual-accounts/close">
    Close the account
  </Card>

  <Card title="Webhooks" icon="webhook" href="/api-reference/webhooks/overview">
    Handle account events
  </Card>
</CardGroup>
