Date: 2024-11-30 || Views: 152
In today's digital economy, seamless and transparent payment processes are crucial for building trust between service providers and their customers. Recognizing this, we have introduced a new feature in the pawaPay Integration PHP SDK that enhances user awareness during mobile money transactions. This article delves into the significance of this addition, explaining how it works and the benefits it brings to both merchants and customers.
When customers initiate a payment through mobile money services, they often expect to see the merchant's name (e.g., "Katorymnd Freelancer") displayed on their mobile devices during the transaction. However, due to regulatory and operational frameworks in different countries, the payment request might display the name of the Mobile Network Operator (MNO) or an intermediary company associated with the transaction, rather than the merchant's name.
This discrepancy can lead to confusion or concern among customers who might be hesitant to confirm a payment request from an unfamiliar entity. They may wonder if the transaction is legitimate or if their funds will reach the intended recipient.
To address this challenge, we have enhanced the pawaPay Integration PHP SDK to include an "Owner Name" notification in the payment confirmation step. This feature informs customers about the entity from which they will receive the payment request, clarifying that it is acting on behalf of the merchant.
Data Retrieval: The SDK fetches the Owner Name associated with the selected country and operator from the active_conf.json
configuration file provided by pawaPay. This file contains up-to-date information about available operators and their corresponding owner entities.
Updating MNO Correspondents: The SDK updates the mnoCorrespondents
object to include the ownerName
for each operator, ensuring that this information is readily accessible during the transaction flow.
User Interface Enhancement: In the payment confirmation step, the SDK dynamically displays a professionally crafted notice using Bootstrap alerts. This notice informs the customer that they will receive a payment request from the specified Owner Name acting on behalf of the merchant (e.g., "Katorymnd Freelancer").
<div class="alert alert-info mt-4" role="alert">
<strong>Important:</strong> You will receive a payment request from <strong>Owner Name</strong> acting on behalf of <strong>Katorymnd Freelancer</strong>. Please confirm the payment to proceed with your transaction.
</div>
Consider a customer in Uganda using MTN Mobile Money to pay for services from "Katorymnd Freelancer." Due to the integration with pawaPay, the payment request might show "QUIDEXPLUS UGANDA LIMITED" as the entity requesting the payment. Without prior notice, the customer might be unsure about confirming this request.
With the new feature, before confirming the payment, the customer sees:
And the following important notice:
Important: You will receive a payment request from QUIDEXPLUS UGANDA LIMITED acting on behalf of Katorymnd Freelancer. Please confirm the payment to proceed with your transaction.
This message reassures the customer that the payment request is legitimate and connected to their intended transaction.
Developers should ensure they are using the latest version of the pawaPay Integration PHP SDK, which includes the necessary functions to fetch and display the Owner Name.
Loading Configuration Data: The SDK loads both mno_availability.json
and active_conf.json
to obtain real-time data about operator availability and owner names.
// Function to load the availability data
async function loadAvailabilityData() {
try {
const [availabilityResponse, activeConfResponse] = await Promise.all([
fetch("../data/mno_availability.json"),
fetch("../data/active_conf.json"),
]);
if (!availabilityResponse.ok || !activeConfResponse.ok) {
throw new Error("Network response was not ok");
}
const availabilityData = await availabilityResponse.json();
const activeConfData = await activeConfResponse.json();
return { availabilityData, activeConfData };
} catch (error) {
console.error("Error loading availability data:", error);
return null;
}
}
Updating Correspondent Information: The SDK updates the mnoCorrespondents
object with the availability status and owner names for each operator.
// Function to update the availability in mnoCorrespondents
function updateMnoAvailability(availabilityData, activeConfData) {
if (!availabilityData || !activeConfData) {
console.error(
"No availability or active configuration data to process."
);
return;
}
// Create a mapping from MNO apiCode to availability status and ownerName
const availabilityMap = {};
const ownerNameMap = {};
// Build the ownerNameMap from activeConfData
if (activeConfData.countries) {
activeConfData.countries.forEach((countryData) => {
countryData.correspondents.forEach((correspondentData) => {
const apiCode = correspondentData.correspondent;
const ownerName = correspondentData.ownerName;
ownerNameMap[apiCode] = ownerName;
});
});
}
// Build the availabilityMap from availabilityData
availabilityData.forEach((countryData) => {
countryData.correspondents.forEach((correspondentData) => {
const apiCode = correspondentData.correspondent;
const allOperational = correspondentData.operationTypes.every(
(op) => op.status === "OPERATIONAL"
);
availabilityMap[apiCode] = allOperational;
});
});
// Now update the mnoCorrespondents object
for (const country in mnoCorrespondents) {
mnoCorrespondents[country].forEach((mno) => {
const apiCode = mno.apiCode;
// Update availability
if (availabilityMap.hasOwnProperty(apiCode)) {
mno.available = availabilityMap[apiCode];
} else {
mno.available = false;
}
// Update ownerName
if (ownerNameMap.hasOwnProperty(apiCode)) {
mno.ownerName = ownerNameMap[apiCode];
} else {
mno.ownerName = "N/A";
}
});
}
}
Displaying the Notice: In the confirmation step, the SDK constructs the summary and includes the owner name in the notice.
function updateConfirmation() {
// Get the MNO details
let selectedMnoName = "";
let ownerName = "";
const mnos = mnoCorrespondents[country];
if (mnos) {
for (let i = 0; i < mnos.length; i++) {
if (mnos[i].apiCode === selectedMnoCode) {
selectedMnoName = mnos[i].name;
ownerName = mnos[i].ownerName || "N/A";
break;
}
}
}
// Build the summary HTML
// Craft the professional notice message
}
Developers can customize the notice message or styling as needed. For instance, they might choose to include additional information or modify the alert type (e.g., alert-warning
).
The addition of the Owner Name notification feature in the pawaPay Integration PHP SDK represents a significant step towards enhancing transparency and trust in mobile money transactions. By proactively informing customers about who will send the payment request and on whose behalf, we bridge the information gap that can lead to confusion or hesitation.
This feature not only improves the user experience but also supports merchants in providing a seamless payment process, ultimately contributing to higher conversion rates and customer satisfaction.
About pawaPay Integration PHP SDK
The pawaPay Integration PHP SDK is a powerful tool that simplifies the integration of mobile money payment services across various African countries and operators. By providing a unified interface and robust functionalities, it enables developers and businesses to offer seamless payment experiences to their customers.
For more information, documentation, and support, please visit the pawaPay Developer Portal. You can also find the source code on our GitHub repository.
Discover key strategies for optimizing websites for voice search in...
Here is how I helped my clients reach their goals. Click on the portfolio websites.
A VS Code extension to manage and synchronize your remote and local files efficiently, supporting FTP, SFTP, SSH, WebDAV, and Google Drive connections.
A WordPress plugin that introduces a dynamic and interactive layer to your site, allowing users to express their feelings and thoughts on your content through a variety of reaction options.
The pawaPay SDK provides seamless mobile money integration into your PHP applications, enabling smooth transaction processing with powerful API features.
© Copyright 2025 - Katorymnd Web Solutions - All Rights Reserved. Registered with Uganda Registration Services Bureau.