POST https://mybundlepay.com/ng/api/v2/virtualcards/enroll-user
KEY USAGE POLICY
Important: Always begin integration using your
test_secret_key to simulate enrollments.
- Use
test_secret_keyfor development/testing. - Switch to
secret_key(Live Key) only after approval. - Test calls return simulated responses; no real customers are created.
- Live calls create real customers and enroll them.
⚠️ Going live without testing may cause failed enrollments or blocked API keys.
HEADERS
Authorization * string
Send your {secret_key} as a Bearer token.
Content-Type * application/json
All requests must use JSON.
IP WHITELISTING
Ensure your server IP is whitelisted in your dashboard.
CF-Connecting-IPX-Forwarded-For$request->ip()fallback
BODY PARAMS
| Parameter | Required | Description |
|---|---|---|
customerEmail | ✅ | Customer email address. |
idNumber | ✅ | ID number (e.g., BVN, PASSPORT, NATIONAL_ID). |
idType | ✅ | Uppercase ID type (BVN, PASSPORT, NATIONAL_ID, etc.) |
firstName | ✅ | First name. |
lastName | ✅ | Last name. |
otherNames | - | Other names (optional). |
phoneNumber | ✅ | Phone number with country code. |
city | ✅ | City. |
state | ✅ | State/region. |
country | ✅ | Full country name (e.g., Nigeria, Madagascar). |
zipCode | ✅ | Postal code. |
line1 | ✅ | Address line. |
houseName | - | Optional house/apartment name. |
bvn | ✅ | Required only for Nigerian customers. |
idImage | ✅ | ID front image URL. |
userPhoto | ✅ | ID back image or user photo. |
dateOfBirth | ✅ | Date of birth (YYYY-MM-DD). Required for non-Nigeria users. |
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://mybundlepay.com/ng/api/v2/virtualcards/enroll-user",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
"customerEmail" => "john.doe@example.com",
"idNumber" => "12345678901",
"idType" => "BVN",
"firstName" => "John",
"lastName" => "Doe",
"phoneNumber" => "+2348012345678",
"city" => "Lagos",
"state" => "Lagos",
"country" => "Nigeria",
"zipCode" => "100001",
"line1" => "10 Allen Avenue",
"houseName" => "House 5",
"bvn" => "12345678901",
"idImage" => "https://example.com/id-front.jpg",
"userPhoto" => "https://example.com/id-back.jpg",
"dateOfBirth" => "1995-07-14"
]),
CURLOPT_HTTPHEADER => array(
"Content-Type: application/json",
"Authorization: Bearer {secret_key}"
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
?>
const axios = require('axios');
const data = {
customerEmail: "jane.doe@example.com",
idNumber: "MG123456789",
idType: "NATIONAL_ID",
firstName: "Jane",
lastName: "Doe",
phoneNumber: "+261330123456",
city: "Antananarivo",
state: "Antananarivo",
country: "Madagascar",
zipCode: "101",
line1: "123 Antananarivo Street",
houseName: "House 12",
idImage: "https://example.com/id-front.jpg",
userPhoto: "https://example.com/id-back.jpg",
dateOfBirth: "1990-05-20"
};
axios.post("https://mybundlepay.com/ng/api/v2/virtualcards/enroll-user", data, {
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer {secret_key}"
}
}).then(res => console.log(res.data))
.catch(err => console.error(err.response ? err.response.data : err.message));
Success Response
{
"status": "success",
"code": "USER_ENROLLED",
"message": "Virtual card user successfully enrolled for MyBundlePay.",
"mode": "TEST",
"data": {
"business_id": "xxxxx-b3f1-4759-8bb7-xxxxxx",
"response": {
"customer_id": "xxxxxxxxxxxxxx",
"name": "Jane Doe",
"emailAddress": "jane.doe@example.com",
"phoneNumber": "+261330123456",
"status": "active",
"type": "individual",
"individual": {
"firstName": "Jane",
"lastName": "Doe",
"otherNames": "",
"dob": "1990-05-20",
"documents": {
"idFrontUrl": "https://example.com/id-front.jpg",
"idBackUrl": "https://example.com/id-back.jpg"
}
},
"billingAddress": {
"line1": "123 Antananarivo Street",
"line2": "House 12",
"city": "Antananarivo",
"state": "Antananarivo",
"postalCode": "101",
"country": "Madagascar"
},
"isDeleted": false,
"createdAt": "2025-11-11T02:04:17+01:00",
"updatedAt": "2025-11-11T02:04:17+01:00"
}
}
}
Error Response (Validation)
{
"status": "failed",
"message": {
"bvn": ["The bvn field is required."]
}
}
Error Response
{
"status": "failed",
"message": "Failed to enroll virtual card user.",
"details": {
"error": "ID type not supported",
"statusCode": 400
}
}