Class: Vatlayer::Api
- Inherits:
-
Object
- Object
- Vatlayer::Api
- Defined in:
- lib/vatlayer/api.rb
Instance Attribute Summary collapse
-
#access_key ⇒ Object
readonly
Returns the value of attribute access_key.
-
#https ⇒ Object
readonly
Returns the value of attribute https.
Instance Method Summary collapse
-
#initialize(access_key, https) ⇒ Api
constructor
A new instance of Api.
- #rate_list ⇒ Object
- #validate(vat_number:) ⇒ Object
Constructor Details
#initialize(access_key, https) ⇒ Api
9 10 11 12 |
# File 'lib/vatlayer/api.rb', line 9 def initialize(access_key, https) @access_key = access_key @https = https end |
Instance Attribute Details
#access_key ⇒ Object (readonly)
Returns the value of attribute access_key.
7 8 9 |
# File 'lib/vatlayer/api.rb', line 7 def access_key @access_key end |
#https ⇒ Object (readonly)
Returns the value of attribute https.
7 8 9 |
# File 'lib/vatlayer/api.rb', line 7 def https @https end |
Instance Method Details
#rate_list ⇒ Object
14 15 16 |
# File 'lib/vatlayer/api.rb', line 14 def rate_list request('/rate_list') end |
#validate(vat_number:) ⇒ Object
18 19 20 |
# File 'lib/vatlayer/api.rb', line 18 def validate(vat_number:) request('/validate', vat_number: vat_number) end |