Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions app.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,19 @@
"<Response/>"
end

post "/voice" do
response = Twilio::TwiML::Response.new do |r|
r.Say "Hello Mr King, please leave your tweet after the beep", voice: "alice", language: "en-GB"
r.Record transcribe: true, transcribeCallback: "/transcription", maxLength: 30
end
response.to_xml
end

post "/transcription" do
twitter.update("#{params["TranscriptionText"]} #tweetlikelarryking")
200
end

get "/health" do
200
end
Expand Down