Class: Mercadopago::Chargeback
- Defined in:
- lib/mercadopago/resources/chargeback.rb
Overview
Instance Method Summary collapse
-
#get(chargeback_id, request_options: nil) ⇒ Hash{Symbol => Object}
Retrieves a chargeback by its ID.
-
#search(filters: nil, request_options: nil) ⇒ Hash{Symbol => Object}
Searches chargebacks matching the given filters.
Methods inherited from MPBase
#_check_headers, #_check_request_options, #_delete, #_get, #_post, #_put, #initialize
Constructor Details
This class inherits a constructor from Mercadopago::MPBase
Instance Method Details
#get(chargeback_id, request_options: nil) ⇒ Hash{Symbol => Object}
Retrieves a chargeback by its ID.
19 20 21 |
# File 'lib/mercadopago/resources/chargeback.rb', line 19 def get(chargeback_id, request_options: nil) _get(uri: "/v1/chargebacks/#{chargeback_id}", request_options: ) end |
#search(filters: nil, request_options: nil) ⇒ Hash{Symbol => Object}
Searches chargebacks matching the given filters.
30 31 32 33 34 |
# File 'lib/mercadopago/resources/chargeback.rb', line 30 def search(filters: nil, request_options: nil) raise TypeError, 'Param filters must be a Hash' unless filters.nil? || filters.is_a?(Hash) _get(uri: '/v1/chargebacks/search', filters: filters, request_options: ) end |