![Create React App Officially Deprecated Amid React 19 Compatibility Issues](https://cdn.sanity.io/images/cgdhsj6q/production/04fa08cf844d798abc0e1a6391c129363cc7e2ab-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Python wrapper on Mpesa public API for mobile Payment Integration made with care to offer easy and elegant integration made by kalebu
The following are the features that are supported by the Mpesa public API and require the python implementation.
Full documentation can be found on pypesa
Getting started with pypesa is pretty straight forward and can be categorized
into steps shown below.
Sign up for Mpesa Developer portal
Install the pypesa package using pip
Build your services with pypesa
To sign up for Mpesa public API visit Mpesa-API and then
you can go through getting started Mpesa Developer portal by alphaolomi to see how.
To install the pypesa package to your machine you can either
install directly from github or use pip to install it.
$~ git clone https://github.com/Kalebu/pypesa
$~ cd pypesa
$ pypesa ~ python setup.py install
pip install python-pesa
To begin using the package is pretty straight forward
{
'api_key': 'xxx',
'public_key': 'xxxxxxxxxxxxxx'
}
2.Once done you're ready to go, just make sure you have active internet connection
>>> import pypesa
>>> mpesa = pypesa()
>>> transaction_query = {"input_Amount": "10",
"input_Country": "TZN",
"input_Currency": "TZS",
"input_CustomerMSISDN": "000000000001",
"input_ServiceProviderCode": "000000",
"input_ThirdPartyConversationID":'2edf7a0206d848f6b6fedea26accdc3a',
"input_TransactionReference": 'T23434ZE5',
"input_PurchasedItemsDesc": "Python Book"
}
>>> mpesa.customer_to_bussiness(transaction_query)
Request processed successfully INS-0
{'output_ResponseCode': 'INS-0', 'output_ResponseDesc': 'Request processed successfully',
'output_TransactionID': 'uGnPxFoXT2W0', 'output_ConversationID': '1d1e38495dc946729a8cffb136ab8391', 'output_ThirdPartyConversationID': '2edf7a0206d848f6b6fedea26accdc3a'}
If you named your authentication json in other name than keys you might to specify it while creating an instance for mpesa just as shown below;
>>> import pypesa
>>> mpesa = pypesa(auth_path = filename)
The package run by default using sandbox environmnent, If you wanna use it to real production environmnent you can specify it while creating an instance as shown below
>>> import pypesa
>>> mpesa = pypesa(environmnent="production")
Wanna contribute to Pypesa ? then please contributing.md to see how
If you found this repository useful, give it a star, You can also keep in touch with on twitter.
If you encounter issue with the usage of the package, feel free raise an issue so as we can fix it as soon as possible(ASAP) or just reach me directly through my email isaackeinstein(at)gmail.com
All the credits to kalebu and all the future contributors
FAQs
Python package for Vodacom Mpesa API Integration
We found that python-pesa demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.