Created
January 12, 2018 00:00
-
-
Save daydream05/3c9558ebf89db2a3f24706c5071ad19a to your computer and use it in GitHub Desktop.
Revisions
-
daydream05 created this gist
Jan 12, 2018 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,12 @@ class Api::V1::PhoneVerificationsController < ApplicationController def start response = Authy::PhoneVerification.start(via: "sms", country_code: 1, phone_number: phone_number_params) if response.ok? # verification was started render json: {"success": true, message: "Verification code was sent to your phone number"}, status: :ok else render json: response end end end