Class: OnlineSim::GetFree

Inherits:
Base
  • Object
show all
Defined in:
lib/onlinesim/GetFree.rb

Constant Summary

Constants inherited from Base

Base::HTTP_OK_CODE

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from OnlineSim::Base

Instance Method Details

#countriesObject



5
6
7
# File 'lib/onlinesim/GetFree.rb', line 5

def countries
  return self ._get(:endpoint => 'getFreeCountryList')['countries']
end

#messages(phone, page: 1) ⇒ Object



13
14
15
# File 'lib/onlinesim/GetFree.rb', line 13

def messages(phone, page: 1)
  return self ._get(:endpoint => 'getFreeMessageList', :params => {phone: phone, page: page})['messages']['data']
end

#numbers(country: 7) ⇒ Object



9
10
11
# File 'lib/onlinesim/GetFree.rb', line 9

def numbers(country: 7)
  return self ._get(:endpoint => 'getFreePhoneList', :params => {country: country})['numbers']
end