GET /v1/data/b2b/plans, and is debited from your wallet. The transaction comes back SUCCESS, FAILED (refunded to your wallet) or PROCESSING while the network confirms delivery — poll GET /v1/data/b2b/{reference} until it settles.curl --location 'http://localhost:5050/v1/data/b2b-buy' \
--header 'Idempotency-Key;' \
--header 'x-api-key: <api-key>' \
--header 'Content-Type: application/json' \
--data '{
"idempotencyKey": "5f0c7c1e-8a52-4a5e-9d0b-1c1f6f1d2a11",
"network": "MTN",
"planId": "7",
"phoneNumber": "08012345678"
}'{
"success": true,
"message": "Data purchase successful",
"statusCode": 200,
"path": "/v1/…",
"timestamp": "2026-09-26T12:00:00.000Z",
"hash": "a1b2c3d4-…",
"data": {
"transaction": {
"reference": "DB-DATA-20250923-MFX2K9QZ-7A3C9D21",
"type": "DATA",
"status": "SUCCESS",
"amount": 480,
"recipient": "08012345678",
"network": "MTN",
"planId": "7",
"description": "1GB SME · 30 days",
"tokenOrPin": null,
"balanceBefore": 10000,
"balanceAfter": 9520,
"failureReason": null,
"createdAt": "2026-09-26T12:00:00.000Z"
}
}
}