Skip to main content

Endpoint

GET /clients/business/virtual-accounts/{id}

Path parameters

id
string
required
The virtual account’s id, from List virtual accounts or the account’s creation response.

Headers

x-api-key
string
required
Your public API key.
x-api-secret
string
required
Your API secret. Use a stl_test_... value in sandbox, stl_live_... in production.
businessId
string
required
Your business ID.

Response

status
boolean
true on success.
message
string
Human-readable outcome.
data.id
string
Unique ID for this virtual account.
data.clientRef
string
The reference (or refCode) supplied when this account was created.
data.systemRef
string
The unique reference Interstellas generated for this account.
data.name
string
The name on the account.
data.accountNumber
string
The NUBAN account number.
data.bvn
string
The BVN associated with this account, if one was set at creation.
This endpoint returns fewer fields than List virtual accounts — notably no businessId or dateCreated. If you need those, use the list endpoint.

Code examples

curl -X GET https://sandbox.stellasbank.com/api/v1/clients/business/virtual-accounts/6f9d3e2a-1b4c-4a8d-9e2f-3c1a2b4d5e6f \
  -H "x-api-key: stl_c8e286ca55b0123e0b05da047494f585" \
  -H "x-api-secret: stl_test_6332e4b1dd6c2e5814395b549aec6deb0d0664406c66f2285f95f801c76117c0" \
  -H "businessId: YOUR_BUSINESS_ID"
const res = await fetch(
  "https://sandbox.stellasbank.com/api/v1/clients/business/virtual-accounts/6f9d3e2a-1b4c-4a8d-9e2f-3c1a2b4d5e6f",
  {
    headers: {
      "x-api-key": "stl_c8e286ca55b0123e0b05da047494f585",
      "x-api-secret": "stl_test_6332e4b1dd6c2e5814395b549aec6deb0d0664406c66f2285f95f801c76117c0",
      businessId: "YOUR_BUSINESS_ID",
    },
  }
);
const { data } = await res.json();
import requests

res = requests.get(
    "https://sandbox.stellasbank.com/api/v1/clients/business/virtual-accounts/6f9d3e2a-1b4c-4a8d-9e2f-3c1a2b4d5e6f",
    headers={
        "x-api-key": "stl_c8e286ca55b0123e0b05da047494f585",
        "x-api-secret": "stl_test_6332e4b1dd6c2e5814395b549aec6deb0d0664406c66f2285f95f801c76117c0",
        "businessId": "YOUR_BUSINESS_ID",
    },
)
print(res.json()["data"])

Example response

{
  "status": true,
  "message": "Successful",
  "data": {
    "id": "6f9d3e2a-1b4c-4a8d-9e2f-3c1a2b4d5e6f",
    "clientRef": "ref_unique_001",
    "systemRef": "STL|jYcphJZcT73yjv",
    "name": "Ada Lovelace",
    "accountNumber": "9000081483",
    "bvn": "12345678901"
  }
}

Errors

StatusCause
400 Bad RequestbusinessId header missing
400 Bad RequestThe account exists but belongs to a different business ("Account does not belong to this business")
401 UnauthorizedCredentials missing or invalid
If id doesn’t match any virtual account at all, this endpoint currently returns a generic 500 INTERNAL_SERVER_ERROR rather than 404 Not Found — there’s no existence check before the ownership check runs. Don’t rely on a 404 to detect an unknown id; treat any non-200 response as “this account isn’t accessible to you” and confirm the id came from List virtual accounts or a creation response before retrying.
See Errors for the full envelope and error code reference.