Class: Dodopayments::Resources::Payouts::Breakup
- Inherits:
-
Object
- Object
- Dodopayments::Resources::Payouts::Breakup
- Defined in:
- lib/dodopayments/resources/payouts/breakup.rb,
lib/dodopayments/resources/payouts/breakup/details.rb
Defined Under Namespace
Classes: Details
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(client:) ⇒ Breakup
constructor
private
A new instance of Breakup.
-
#retrieve(payout_id, request_options: {}) ⇒ Array<Dodopayments::Models::Payouts::BreakupRetrieveResponseItem>
Returns the breakdown of a payout by event type (payments, refunds, disputes, fees, etc.) in the payout’s currency.
Constructor Details
#initialize(client:) ⇒ Breakup
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Breakup.
36 37 38 39 |
# File 'lib/dodopayments/resources/payouts/breakup.rb', line 36 def initialize(client:) @client = client @details = Dodopayments::Resources::Payouts::Breakup::Details.new(client: client) end |
Instance Attribute Details
#details ⇒ Dodopayments::Resources::Payouts::Breakup::Details (readonly)
8 9 10 |
# File 'lib/dodopayments/resources/payouts/breakup.rb', line 8 def details @details end |
Instance Method Details
#retrieve(payout_id, request_options: {}) ⇒ Array<Dodopayments::Models::Payouts::BreakupRetrieveResponseItem>
Returns the breakdown of a payout by event type (payments, refunds, disputes, fees, etc.) in the payout’s currency. Each amount is proportionally allocated based on USD equivalent values, ensuring the total sums exactly to the payout amount.
24 25 26 27 28 29 30 31 |
# File 'lib/dodopayments/resources/payouts/breakup.rb', line 24 def retrieve(payout_id, params = {}) @client.request( method: :get, path: ["payouts/%1$s/breakup", payout_id], model: Dodopayments::Internal::Type::ArrayOf[Dodopayments::Models::Payouts::BreakupRetrieveResponseItem], options: params[:request_options] ) end |