Class: Msg91::Services::OTPService
- Inherits:
-
Object
- Object
- Msg91::Services::OTPService
- Defined in:
- lib/msg91/services/otp_service.rb
Class Method Summary collapse
Class Method Details
.verify_token(authkey, token) ⇒ Object
10 11 12 13 14 15 |
# File 'lib/msg91/services/otp_service.rb', line 10 def self.verify_token(authkey, token) uri = URI.parse("https://control.msg91.com/api/v5/widget/verifyAccessToken") params = { authkey: authkey, 'access-token': token } response = Net::HTTP.post_form(uri, params) JSON.parse(response.body) end |