Class: Stripe::TestHelpers::Treasury::OutboundTransferService
- Inherits:
-
StripeService
- Object
- StripeService
- Stripe::TestHelpers::Treasury::OutboundTransferService
- Defined in:
- lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb
Defined Under Namespace
Classes: FailParams, PostParams, ReturnOutboundTransferParams, UpdateParams
Instance Method Summary collapse
-
#fail(outbound_transfer, params = {}, opts = {}) ⇒ Object
Transitions a test mode created OutboundTransfer to the failed status.
-
#post(outbound_transfer, params = {}, opts = {}) ⇒ Object
Transitions a test mode created OutboundTransfer to the posted status.
-
#return_outbound_transfer(outbound_transfer, params = {}, opts = {}) ⇒ Object
Transitions a test mode created OutboundTransfer to the returned status.
-
#update(outbound_transfer, params = {}, opts = {}) ⇒ Object
Updates a test mode created OutboundTransfer with tracking details.
Methods inherited from StripeService
#initialize, #request, #request_stream
Constructor Details
This class inherits a constructor from Stripe::StripeService
Instance Method Details
#fail(outbound_transfer, params = {}, opts = {}) ⇒ Object
Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
96 97 98 99 100 101 102 103 104 |
# File 'lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb', line 96 def fail(outbound_transfer, params = {}, opts = {}) request( method: :post, path: format("/v1/test_helpers/treasury/outbound_transfers/%<outbound_transfer>s/fail", { outbound_transfer: CGI.escape(outbound_transfer) }), params: params, opts: opts, base_address: :api ) end |
#post(outbound_transfer, params = {}, opts = {}) ⇒ Object
Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
107 108 109 110 111 112 113 114 115 |
# File 'lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb', line 107 def post(outbound_transfer, params = {}, opts = {}) request( method: :post, path: format("/v1/test_helpers/treasury/outbound_transfers/%<outbound_transfer>s/post", { outbound_transfer: CGI.escape(outbound_transfer) }), params: params, opts: opts, base_address: :api ) end |
#return_outbound_transfer(outbound_transfer, params = {}, opts = {}) ⇒ Object
Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
118 119 120 121 122 123 124 125 126 |
# File 'lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb', line 118 def return_outbound_transfer(outbound_transfer, params = {}, opts = {}) request( method: :post, path: format("/v1/test_helpers/treasury/outbound_transfers/%<outbound_transfer>s/return", { outbound_transfer: CGI.escape(outbound_transfer) }), params: params, opts: opts, base_address: :api ) end |
#update(outbound_transfer, params = {}, opts = {}) ⇒ Object
Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
129 130 131 132 133 134 135 136 137 |
# File 'lib/stripe/services/test_helpers/treasury/outbound_transfer_service.rb', line 129 def update(outbound_transfer, params = {}, opts = {}) request( method: :post, path: format("/v1/test_helpers/treasury/outbound_transfers/%<outbound_transfer>s", { outbound_transfer: CGI.escape(outbound_transfer) }), params: params, opts: opts, base_address: :api ) end |