module Vonage::Authentication

Public Instance Methods

authenticate() click to toggle source
# File lib/vonage/authentication.rb, line 4
def authenticate
  params = {login: @login, password: @password}
  get_response = get "/appserver/rest/user/null", params

  @cookies = parse_cookies(get_response)
end
authenticated?() click to toggle source
# File lib/vonage/authentication.rb, line 11
def authenticated?
  !@cookies.empty?
end
reauthenticate() click to toggle source
# File lib/vonage/authentication.rb, line 15
def reauthenticate
  @cookies = CookieHash.new
  authenticate
end