Overview
The VirtualAccount class allows you to:- Create dedicated virtual accounts for customers
- Assign virtual accounts to existing customers
- List and fetch virtual account details
- Manage splits on virtual accounts
- Requery accounts for new transactions
- Deactivate virtual accounts
- Fetch available bank providers
Methods
create
Creates a dedicated virtual account.string
required
Customer ID or code
string
The preferred bank slug for the virtual account
string
Subaccount code to assign to the virtual account
string
Split code to assign to the virtual account
string
Customer’s first name
string
Customer’s last name
string
Customer’s phone number
object
assign
Assigns a dedicated virtual account to a customer.string
required
Customer’s email address
string
required
Customer’s first name
string
required
Customer’s last name
string
required
Customer’s phone number
'NG' | 'GH'
required
Customer’s country code
string
Customer’s account number for validation (Nigeria only)
string
Customer’s Bank Verification Number (Nigeria only)
string
Customer’s bank code
string
Subaccount code to assign
string
Split code to assign
list
Lists dedicated virtual accounts.boolean
required
Filter by active status
'NGN' | 'USD' | 'GHS' | 'ZAR' | 'KES' | 'XOF'
required
Filter by currency (defaults to NGN)
string
Filter by provider slug
string
Filter by bank ID
string
Filter by customer ID or code
array
object
Pagination metadata including total, page, perPage, and pageCount
fetch
Retrieves details of a dedicated virtual account.string
required
The ID of the dedicated virtual account
object
requery
Requeries a dedicated virtual account for new transactions.string
required
The virtual account number
string
required
The provider slug
string
ISO date to check for transactions (optional)
deactivate
Deactivates a dedicated virtual account.string
required
The ID of the dedicated virtual account to deactivate
object
The deactivated virtual account details with active status set to false
addSplit
Adds a split to a dedicated virtual account.string
required
Customer ID or code
string
Subaccount code
string
Split code
string
Preferred bank slug
object
Updated virtual account with split_config containing the split_code
removeSplit
Removes a split from a dedicated virtual account.string
required
The virtual account number
object
fetchBanks
Fetches available bank providers for dedicated virtual accounts.array

