summaryrefslogtreecommitdiff
path: root/lib/lsg_web/controllers/sms_controller.ex
diff options
context:
space:
mode:
Diffstat (limited to 'lib/lsg_web/controllers/sms_controller.ex')
-rw-r--r--lib/lsg_web/controllers/sms_controller.ex10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/lsg_web/controllers/sms_controller.ex b/lib/lsg_web/controllers/sms_controller.ex
new file mode 100644
index 0000000..00c6352
--- /dev/null
+++ b/lib/lsg_web/controllers/sms_controller.ex
@@ -0,0 +1,10 @@
+defmodule LSGWeb.SmsController do
+ use LSGWeb, :controller
+ require Logger
+
+ def ovh_callback(conn, %{"senderid" => from, "message" => message}) do
+ spawn(fn() -> LSG.IRC.SmsPlugin.incoming(from, String.trim(message)) end)
+ text(conn, "")
+ end
+
+end