Class: Stripe::V2::MoneyManagement::PayoutIntentService
- Inherits:
-
StripeService
- Object
- StripeService
- Stripe::V2::MoneyManagement::PayoutIntentService
- Defined in:
- lib/stripe/services/v2/money_management/payout_intent_service.rb
Instance Method Summary collapse
-
#cancel(id, params = {}, opts = {}) ⇒ Object
Cancels a PayoutIntent.
-
#confirm(id, params = {}, opts = {}) ⇒ Object
Confirms a PayoutIntent that is in the requires_action state, transitioning it to pending.
-
#create(params = {}, opts = {}) ⇒ Object
Creates a PayoutIntent.
-
#fx_quote(id, params = {}, opts = {}) ⇒ Object
Refreshes FX quote for a PayoutIntent.
-
#list(params = {}, opts = {}) ⇒ Object
Returns a list of PayoutIntents.
-
#retrieve(id, params = {}, opts = {}) ⇒ Object
Retrieves the details of an existing PayoutIntent by passing the unique PayoutIntent ID.
-
#update(id, params = {}, opts = {}) ⇒ Object
Updates a PayoutIntent.
Methods inherited from StripeService
#initialize, #request, #request_stream
Constructor Details
This class inherits a constructor from Stripe::StripeService
Instance Method Details
#cancel(id, params = {}, opts = {}) ⇒ Object
Cancels a PayoutIntent. Only pending PayoutIntents, processing PayoutIntents with cancelable OutboundPayment/Transfer, or requires_action PayoutIntents can be canceled.
** raises NotCancelableError
11 12 13 14 15 16 17 18 19 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 11 def cancel(id, params = {}, opts = {}) request( method: :post, path: format("/v2/money_management/payout_intents/%<id>s/cancel", { id: CGI.escape(id) }), params: params, opts: opts, base_address: :api ) end |
#confirm(id, params = {}, opts = {}) ⇒ Object
Confirms a PayoutIntent that is in the requires_action state, transitioning it to pending.
** raises FxQuoteNeedsRefreshError
24 25 26 27 28 29 30 31 32 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 24 def confirm(id, params = {}, opts = {}) request( method: :post, path: format("/v2/money_management/payout_intents/%<id>s/confirm", { id: CGI.escape(id) }), params: params, opts: opts, base_address: :api ) end |
#create(params = {}, opts = {}) ⇒ Object
Creates a PayoutIntent.
** raises FeatureNotEnabledError
37 38 39 40 41 42 43 44 45 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 37 def create(params = {}, opts = {}) request( method: :post, path: "/v2/money_management/payout_intents", params: params, opts: opts, base_address: :api ) end |
#fx_quote(id, params = {}, opts = {}) ⇒ Object
Refreshes FX quote for a PayoutIntent.
48 49 50 51 52 53 54 55 56 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 48 def fx_quote(id, params = {}, opts = {}) request( method: :post, path: format("/v2/money_management/payout_intents/%<id>s/fx_quote", { id: CGI.escape(id) }), params: params, opts: opts, base_address: :api ) end |
#list(params = {}, opts = {}) ⇒ Object
Returns a list of PayoutIntents.
59 60 61 62 63 64 65 66 67 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 59 def list(params = {}, opts = {}) request( method: :get, path: "/v2/money_management/payout_intents", params: params, opts: opts, base_address: :api ) end |
#retrieve(id, params = {}, opts = {}) ⇒ Object
Retrieves the details of an existing PayoutIntent by passing the unique PayoutIntent ID.
70 71 72 73 74 75 76 77 78 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 70 def retrieve(id, params = {}, opts = {}) request( method: :get, path: format("/v2/money_management/payout_intents/%<id>s", { id: CGI.escape(id) }), params: params, opts: opts, base_address: :api ) end |
#update(id, params = {}, opts = {}) ⇒ Object
Updates a PayoutIntent. Only pending or requires_action PayoutIntents that are editable can be updated.
** raises FeatureNotEnabledError
83 84 85 86 87 88 89 90 91 |
# File 'lib/stripe/services/v2/money_management/payout_intent_service.rb', line 83 def update(id, params = {}, opts = {}) request( method: :post, path: format("/v2/money_management/payout_intents/%<id>s", { id: CGI.escape(id) }), params: params, opts: opts, base_address: :api ) end |