A stable internet connection.
Go through the USSD documentation provided by Africa's Talking to have an idea as to how it works here.
An Africa's Talking account is required. In case you do not have one, create it by following this link.
A installation of PHP 7 or higher.
Ngrok- This is a tunneling application that will expose our USSD application from the local server to the internet. Download here and set up an account.
The aim of this documentation is to guide you on how to test a USSD application using Africa's Talking sandbox by dialling the code you will create on the launch simulator.
Note: Interaction with your application will take place only on the SIMULATOR and not your PERSONAL MOBILE PHONE.
Tip: Click on the text labelled to reveal the code .
Let us create a callback URL using the following steps. The URL is supposed to expose our app that is on our local server to the web so that we can POST data to it. This is where Ngrok comes in. But first...
Tip: To confirm if the addition has been successful, check for the php version installed by doing php -v on your terminal.
Note: Africa's Talking APIs are accessible on the web through HTTP/HTTPS.
Note: If you're using https, select the https link provided on localhost:4040.
The outcome below is what should be displayed:
Tip: localhost:4040 allows us to inspect incoming connections through the ngrok tunnel and the corresponding response from our server application. A response of 200(OK) means that a client request has been accomplished.
Click on the lauch simulator menu item. Key in your phone number and click launch.
This is the outcome that should be displayed:
That's it! I hope you learnt something new today!