A REST API written in GoLang to send SMS to a Kannel server
Set the credentials to be used by the API in the environment variables SMSAPI_USER and SMSAPI_PASS
go run src/smsapi/main.go
Access the API at http://localhost:8080/outbound/sms/
Unit tests:
go test -v smsapi/router smsapi/handlers smsapi/models
This outputs the names of the tests being run and the result, along with the time taken to run each test. It also outputs a summary result and the total time taken to run all the tests.
API tests:
Install newman using npm install newman
Execute the tests using newman run /smsapi/SMSApiTestSuite.postman_collection.json
REST API:
go install smsapi/
Run the executable in /smsapi/bin
Kannel:
Install the Kannel software by following the instructions in the documentation.
Replace kannel.conf in /etc/kannel with this kannel.conf.
Modify /etc/default/kannel and uncomment the START_SMSBOX=1 line
Run Kannel as a service using the command
sudo service kannel start
Check the status of the Kannel gateway here.
SMPPSIM:
Install the Kannel software by following the instructions in the documentation.
Replace conf/smppsim.props in the installation directory with this smppsim.props.
Run the following command
sh startsmppsim.sh
Confirm the setup using the admin tool here.