Class: Stripe::Reversal
- Inherits:
-
APIResource
- Object
- StripeObject
- APIResource
- Stripe::Reversal
- Extended by:
- APIOperations::List
- Includes:
- APIOperations::Save
- Defined in:
- lib/stripe/resources/reversal.rb
Constant Summary collapse
- OBJECT_NAME =
"transfer_reversal".freeze
Instance Attribute Summary
Attributes inherited from APIResource
Class Method Summary collapse
Instance Method Summary collapse
Methods included from APIOperations::List
Methods included from APIOperations::Save
Methods inherited from APIResource
class_name, custom_method, #refresh, resource_url, save_nested_resource
Methods included from APIOperations::Request
Methods inherited from StripeObject
#==, #[], #[]=, additive_object_param, additive_object_param?, #as_json, construct_from, #deleted?, #dirty!, #each, #eql?, #hash, #initialize, #inspect, #keys, #marshal_dump, #marshal_load, protected_fields, #refresh_from, serialize_params, #serialize_params, #to_hash, #to_json, #to_s, #update_attributes, #values
Constructor Details
This class inherits a constructor from Stripe::StripeObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Stripe::StripeObject
Class Method Details
.retrieve(_id, _opts = {}) ⇒ Object
22 23 24 25 26 27 |
# File 'lib/stripe/resources/reversal.rb', line 22 def self.retrieve(_id, _opts = {}) raise NotImplementedError, "Reversals cannot be retrieved without a transfer ID. Retrieve " \ "a reversal using `Transfer.retrieve_reversal('transfer_id', " \ "'reversal_id')`" end |
.update(_id, _params = nil, _opts = nil) ⇒ Object
15 16 17 18 19 20 |
# File 'lib/stripe/resources/reversal.rb', line 15 def self.update(_id, _params = nil, _opts = nil) raise NotImplementedError, "Reversals cannot be updated without a transfer ID. Update a " \ "reversal using `r = Transfer.update_reversal('transfer_id', " \ "'reversal_id', update_params)`" end |
Instance Method Details
#resource_url ⇒ Object
10 11 12 13 |
# File 'lib/stripe/resources/reversal.rb', line 10 def resource_url "#{Transfer.resource_url}/#{CGI.escape(transfer)}/reversals" \ "/#{CGI.escape(id)}" end |