Class: Paysio::Coupon
- Includes:
- Actions::Create, Actions::Destroy, Actions::Find, Actions::List, Actions::Update
- Defined in:
- lib/paysio/resources/coupon.rb
Instance Attribute Summary
Attributes inherited from Resource
Class Method Summary collapse
Methods included from Actions::Find
Methods included from Actions::Destroy
Methods included from Actions::Update
Methods included from Actions::Create
Methods included from Actions::List
Methods inherited from Resource
#action_path, #as_json, #attribute, #attributes, build_from, #each, #initialize, #inspect, #method_missing, path, #path, #refresh_from, resource, #to_hash, #to_json, #to_s
Constructor Details
This class inherits a constructor from Paysio::Resource
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Paysio::Resource
Class Method Details
.check(code) ⇒ Object
10 11 12 13 |
# File 'lib/paysio/resources/coupon.rb', line 10 def self.check(code) response = Paysio::Client.request(:get, "#{self.path}/code/#{code}/check") Resource.build_from(response) end |