- Clone this repo
- And install the dependencies using npm
- Have a server ready
- Create an .env file
npm install
VITE_REACT_API_PAY="<API to your server>"
VITE_REACT_API_WEB_URL="<Current website domain e.g localhost:5173 or https://domainName for this website>"
This App accepts an input number from a user and when the form is submited, the phone number is sent to the server and initialises an M-PESA stk push to the target phone number.
This is a security feature from Intasend API, it will only allow requests from a this domain and not any other, hence protecting the app from attacks.
Feel free to moding the code to suit your current needs. HAPPY CODING!