Skip to main content
GET
/
api
/
v1
/
payment-method
/
virtual-account
Get or create virtual account payment method
curl --request GET \
  --url https://staging.afx-server.com/api/v1/payment-method/virtual-account \
  --header 'x-api-key: <api-key>'
{
  "data": {
    "paymentMethodId": "<string>",
    "customerId": "<string>",
    "institution": {
      "institutionId": "<string>",
      "institutionName": "<string>",
      "institutionCode": "<string>",
      "institutionAddress": "<string>"
    },
    "transaction": {
      "transactionInvoice": "<string>",
      "transactionNarration": "<string>"
    },
    "channel": "BANK_ACCOUNT",
    "countryCode": "<string>",
    "accountName": "<string>",
    "accountNumber": "<string>",
    "meta": {}
  }
}
Retrieve an existing virtual account or create a new one for the specified currency. Supported currencies include USD, NGN, GBP, and EUR. Important: This endpoint is only active in production and does not work on staging/dev.

Authorizations

x-api-key
string
header
required

Static business API key from the dashboard

Query Parameters

currency
enum<string>
required

The 3-letter ISO 4217 currency code for the virtual account

Available options:
USD,
NGN,
GBP,
EUR
amount
number

Optional expected transaction amount (max 5,000,000)

Required range: 0 <= x <= 5000000
customerId
string

Optional customer ID. If not provided, the account will be created for the business.

Response

Virtual account retrieved or created successfully.

data
object