Last active
August 10, 2016 11:41
-
-
Save ianjuma/80e1163d871bd1c0565b9c61a2907759 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'sinatra' | |
require 'AfricasTalkingGateway' | |
# gateway = AfricasTalkingGateway.new("username", "apikey"); | |
post '/ussd' do | |
@sessionId = params[:sessionId] | |
@serviceCode = params[:serviceCode] | |
@phoneNumber = params[:phoneNumber] | |
@text = params[:text] | |
puts "text - #{@text} on - #{@phoneNumber}" | |
response = "END I will call and tell you about the origins of ruby." | |
body response | |
status 200 | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment