moov_ruby 26.4.8 → 26.7.0.pre.dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (163) hide show
  1. checksums.yaml +4 -4
  2. data/lib/moov/account_terminal_applications.rb +16 -16
  3. data/lib/moov/accounts.rb +54 -52
  4. data/lib/moov/adjustments.rb +8 -8
  5. data/lib/moov/apple_pay.rb +20 -20
  6. data/lib/moov/authentication.rb +8 -8
  7. data/lib/moov/avatars.rb +4 -4
  8. data/lib/moov/bank_accounts.rb +36 -36
  9. data/lib/moov/branding.rb +12 -12
  10. data/lib/moov/capabilities.rb +20 -20
  11. data/lib/moov/card_issuing.rb +25 -25
  12. data/lib/moov/cards.rb +178 -20
  13. data/lib/moov/disputes.rb +44 -44
  14. data/lib/moov/end_to_end_encryption.rb +8 -8
  15. data/lib/moov/enriched_address.rb +4 -4
  16. data/lib/moov/enriched_profile.rb +4 -4
  17. data/lib/moov/fee_plans.rb +40 -40
  18. data/lib/moov/files.rb +12 -12
  19. data/lib/moov/google_pay.rb +4 -4
  20. data/lib/moov/images.rb +28 -28
  21. data/lib/moov/industries.rb +4 -4
  22. data/lib/moov/institutions.rb +8 -8
  23. data/lib/moov/invoices.rb +28 -28
  24. data/lib/moov/issuing_transactions.rb +20 -20
  25. data/lib/moov/models/components/addcapabilities.rb +1 -5
  26. data/lib/moov/models/components/amountdecimalrange.rb +36 -0
  27. data/lib/moov/models/components/amountdecimalrange.rbi +15 -0
  28. data/lib/moov/models/components/amountdecimalrangeupdate.rb +36 -0
  29. data/lib/moov/models/components/amountdecimalrangeupdate.rbi +15 -0
  30. data/lib/moov/models/components/authorizeduser.rb +36 -0
  31. data/lib/moov/models/components/authorizeduser.rbi +15 -0
  32. data/lib/moov/models/components/capability.rb +1 -7
  33. data/lib/moov/models/components/capabilityid.rb +1 -7
  34. data/lib/moov/models/components/cardmetadata.rb +79 -0
  35. data/lib/moov/models/components/cardmetadata.rbi +35 -0
  36. data/lib/moov/models/components/cardmetadatarequest.rb +38 -0
  37. data/lib/moov/models/components/cardmetadatarequest.rbi +15 -0
  38. data/lib/moov/models/components/createaccount.rb +1 -5
  39. data/lib/moov/models/components/createauthorizeduser.rb +40 -0
  40. data/lib/moov/models/components/createauthorizeduser.rbi +17 -0
  41. data/lib/moov/models/components/createauthorizedusererror.rb +40 -0
  42. data/lib/moov/models/components/createauthorizedusererror.rbi +17 -0
  43. data/lib/moov/models/components/createauthorizeduserupdate.rb +40 -0
  44. data/lib/moov/models/components/createauthorizeduserupdate.rbi +17 -0
  45. data/lib/moov/models/components/createdtransfer.rb +2 -6
  46. data/lib/moov/models/components/createdtransfer.rbi +0 -2
  47. data/lib/moov/models/components/createpaymentlink.rb +15 -15
  48. data/lib/moov/models/components/createpaymentlink.rbi +4 -4
  49. data/lib/moov/models/components/createpaymentlinkamountdetails.rb +32 -0
  50. data/lib/moov/models/components/createpaymentlinkamountdetails.rbi +13 -0
  51. data/lib/moov/models/components/createpaymentlinkamountdetailsvalidationerror.rb +32 -0
  52. data/lib/moov/models/components/createpaymentlinkamountdetailsvalidationerror.rbi +13 -0
  53. data/lib/moov/models/components/createtransfer.rb +2 -6
  54. data/lib/moov/models/components/createtransfer.rbi +0 -2
  55. data/lib/moov/models/components/createtransferamountdetails.rb +6 -2
  56. data/lib/moov/models/components/createtransferamountdetails.rbi +2 -0
  57. data/lib/moov/models/components/createtransferamountdetailsvalidationerror.rb +6 -2
  58. data/lib/moov/models/components/createtransferamountdetailsvalidationerror.rbi +2 -0
  59. data/lib/moov/models/components/fullissuedcard.rb +10 -22
  60. data/lib/moov/models/components/fullissuedcard.rbi +4 -10
  61. data/lib/moov/models/components/invoice.rb +1 -1
  62. data/lib/moov/models/components/issuedcard.rb +10 -22
  63. data/lib/moov/models/components/issuedcard.rbi +4 -10
  64. data/lib/moov/models/components/onboardinginvite.rb +1 -1
  65. data/lib/moov/models/components/onboardinginviterequest.rb +1 -1
  66. data/lib/moov/models/components/paymentlink.rb +15 -15
  67. data/lib/moov/models/components/paymentlink.rbi +4 -4
  68. data/lib/moov/models/components/paymentlinkamountdetails.rb +32 -0
  69. data/lib/moov/models/components/paymentlinkamountdetails.rbi +13 -0
  70. data/lib/moov/models/components/paymentlinkpaymentdetails.rb +14 -2
  71. data/lib/moov/models/components/paymentlinkpaymentdetails.rbi +6 -0
  72. data/lib/moov/models/components/paymentlinkpaymentdetails_amounttype.rb +19 -0
  73. data/lib/moov/models/components/paymentlinkpaymentdetails_amounttype.rbi +11 -0
  74. data/lib/moov/models/components/paymentlinkpaymentdetailsupdate.rb +14 -2
  75. data/lib/moov/models/components/paymentlinkpaymentdetailsupdate.rbi +6 -0
  76. data/lib/moov/models/components/paymentlinkpaymentdetailsupdate_amounttype.rb +19 -0
  77. data/lib/moov/models/components/paymentlinkpaymentdetailsupdate_amounttype.rbi +11 -0
  78. data/lib/moov/models/components/requestcard.rb +17 -17
  79. data/lib/moov/models/components/requestcard.rbi +8 -8
  80. data/lib/moov/models/components/transfer.rb +2 -6
  81. data/lib/moov/models/components/transfer.rbi +0 -2
  82. data/lib/moov/models/components/transferamountdetails.rb +6 -2
  83. data/lib/moov/models/components/transferamountdetails.rbi +2 -0
  84. data/lib/moov/models/components/transferconfig.rb +2 -6
  85. data/lib/moov/models/components/transferconfig.rbi +0 -2
  86. data/lib/moov/models/components/transferdestination.rb +2 -8
  87. data/lib/moov/models/components/transferdestination.rbi +0 -2
  88. data/lib/moov/models/components/updateinvoice.rb +6 -6
  89. data/lib/moov/models/components/updateissuedcard.rb +9 -13
  90. data/lib/moov/models/components/updateissuedcard.rbi +4 -6
  91. data/lib/moov/models/components/updatepaymentlink.rb +6 -6
  92. data/lib/moov/models/components/updatepaymentlink.rbi +2 -2
  93. data/lib/moov/models/components/updatepaymentlinkamountdetails.rb +32 -0
  94. data/lib/moov/models/components/updatepaymentlinkamountdetails.rbi +13 -0
  95. data/lib/moov/models/components/updatepaymentlinkamountdetailsvalidationerror.rb +32 -0
  96. data/lib/moov/models/components/updatepaymentlinkamountdetailsvalidationerror.rbi +13 -0
  97. data/lib/moov/models/components/webhookdatabankaccountdeleted.rb +2 -6
  98. data/lib/moov/models/components/webhookdatabankaccountdeleted.rbi +0 -2
  99. data/lib/moov/models/components/webhookdatacapabilityrequested.rb +1 -7
  100. data/lib/moov/models/components/webhookdatacapabilityupdated.rb +1 -7
  101. data/lib/moov/models/components/webhookdatasweepcreated.rb +2 -6
  102. data/lib/moov/models/components/webhookdatasweepcreated.rbi +0 -2
  103. data/lib/moov/models/components/webhookdatasweepupdated.rb +2 -6
  104. data/lib/moov/models/components/webhookdatasweepupdated.rbi +0 -2
  105. data/lib/moov/models/components/webhookevent.rb +2 -2
  106. data/lib/moov/models/components/webhookeventtype.rb +0 -1
  107. data/lib/moov/models/components.rb +15 -6
  108. data/lib/moov/models/errors/cardmetadatarequesterror.rb +44 -0
  109. data/lib/moov/models/errors/cardmetadatarequesterror.rbi +19 -0
  110. data/lib/moov/models/errors/createpaymentlinkerror.rb +6 -6
  111. data/lib/moov/models/errors/createpaymentlinkerror.rbi +2 -2
  112. data/lib/moov/models/errors/requestcarderror.rb +14 -14
  113. data/lib/moov/models/errors/requestcarderror.rbi +8 -8
  114. data/lib/moov/models/errors/transfer_error.rb +2 -6
  115. data/lib/moov/models/errors/transfer_error.rbi +0 -2
  116. data/lib/moov/models/errors/transfervalidationerror.rb +2 -6
  117. data/lib/moov/models/errors/transfervalidationerror.rbi +0 -2
  118. data/lib/moov/models/errors/updateissuedcarderror.rb +8 -12
  119. data/lib/moov/models/errors/updateissuedcarderror.rbi +4 -6
  120. data/lib/moov/models/errors/updatepaymentlinkerror.rb +6 -6
  121. data/lib/moov/models/errors/updatepaymentlinkerror.rbi +2 -2
  122. data/lib/moov/models/errors.rb +1 -0
  123. data/lib/moov/models/operations/disablecapability_request.rb +1 -7
  124. data/lib/moov/models/operations/getcapability_request.rb +1 -7
  125. data/lib/moov/models/operations/{listcancellations_response.rb → getcardmetadata_response.rb} +6 -6
  126. data/lib/moov/models/operations/{listcancellations_response.rbi → getcardmetadata_response.rbi} +4 -4
  127. data/lib/moov/models/operations.rb +1 -2
  128. data/lib/moov/onboarding.rb +16 -16
  129. data/lib/moov/payment_links.rb +24 -24
  130. data/lib/moov/payment_methods.rb +8 -8
  131. data/lib/moov/ping.rb +4 -4
  132. data/lib/moov/products.rb +20 -20
  133. data/lib/moov/receipts.rb +8 -8
  134. data/lib/moov/representatives.rb +20 -20
  135. data/lib/moov/resolution_links.rb +16 -16
  136. data/lib/moov/scheduling.rb +24 -24
  137. data/lib/moov/sdkconfiguration.rb +4 -4
  138. data/lib/moov/statements.rb +8 -8
  139. data/lib/moov/support.rb +20 -20
  140. data/lib/moov/sweeps.rb +24 -24
  141. data/lib/moov/terminal_applications.rb +20 -20
  142. data/lib/moov/transfer_config.rb +12 -12
  143. data/lib/moov/transfers.rb +48 -171
  144. data/lib/moov/underwriting.rb +12 -12
  145. data/lib/moov/utils/retries.rb +1 -4
  146. data/lib/moov/wallet_transactions.rb +8 -8
  147. data/lib/moov/wallets.rb +16 -16
  148. data/lib/moov/webhooks.rb +32 -32
  149. metadata +38 -20
  150. data/lib/moov/models/components/billingaddress.rb +0 -52
  151. data/lib/moov/models/components/billingaddress.rbi +0 -23
  152. data/lib/moov/models/components/rtpfailurecode.rb +0 -27
  153. data/lib/moov/models/components/rtpfailurecode.rbi +0 -11
  154. data/lib/moov/models/components/rtptransactiondetails.rb +0 -58
  155. data/lib/moov/models/components/rtptransactiondetails.rbi +0 -25
  156. data/lib/moov/models/components/rtptransactionstatus.rb +0 -21
  157. data/lib/moov/models/components/rtptransactionstatus.rbi +0 -11
  158. data/lib/moov/models/components/transfercontrols.rb +0 -48
  159. data/lib/moov/models/components/transfercontrols.rbi +0 -21
  160. data/lib/moov/models/components/webhookdataauthorizationexpiring.rb +0 -44
  161. data/lib/moov/models/components/webhookdataauthorizationexpiring.rbi +0 -19
  162. data/lib/moov/models/operations/listcancellations_request.rb +0 -36
  163. data/lib/moov/models/operations/listcancellations_request.rbi +0 -15
@@ -84,7 +84,7 @@ module Moov
84
84
 
85
85
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
86
86
  timeout ||= @sdk_configuration.timeout
87
-
87
+
88
88
 
89
89
  connection = @sdk_configuration.client
90
90
 
@@ -99,7 +99,7 @@ module Moov
99
99
  error = T.let(nil, T.nilable(StandardError))
100
100
  http_response = T.let(nil, T.nilable(Faraday::Response))
101
101
 
102
-
102
+
103
103
  begin
104
104
  http_response = T.must(connection).post(url) do |req|
105
105
  req.body = body
@@ -136,13 +136,13 @@ module Moov
136
136
  response: http_response
137
137
  )
138
138
  end
139
-
139
+
140
140
  if http_response.nil?
141
141
  raise error if !error.nil?
142
142
  raise 'no response'
143
143
  end
144
144
  end
145
-
145
+
146
146
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
147
147
  if Utils.match_status_code(http_response.status, ['200'])
148
148
  if Utils.match_content_type(content_type, 'application/json')
@@ -253,7 +253,7 @@ module Moov
253
253
 
254
254
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
255
255
  timeout ||= @sdk_configuration.timeout
256
-
256
+
257
257
 
258
258
  connection = @sdk_configuration.client
259
259
 
@@ -268,7 +268,7 @@ module Moov
268
268
  error = T.let(nil, T.nilable(StandardError))
269
269
  http_response = T.let(nil, T.nilable(Faraday::Response))
270
270
 
271
-
271
+
272
272
  begin
273
273
  http_response = T.must(connection).post(url) do |req|
274
274
  req.body = body
@@ -305,13 +305,13 @@ module Moov
305
305
  response: http_response
306
306
  )
307
307
  end
308
-
308
+
309
309
  if http_response.nil?
310
310
  raise error if !error.nil?
311
311
  raise 'no response'
312
312
  end
313
313
  end
314
-
314
+
315
315
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
316
316
  if Utils.match_status_code(http_response.status, ['200'])
317
317
  if Utils.match_content_type(content_type, 'application/json')
@@ -470,7 +470,7 @@ module Moov
470
470
 
471
471
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
472
472
  timeout ||= @sdk_configuration.timeout
473
-
473
+
474
474
 
475
475
  connection = @sdk_configuration.client
476
476
 
@@ -485,7 +485,7 @@ module Moov
485
485
  error = T.let(nil, T.nilable(StandardError))
486
486
  http_response = T.let(nil, T.nilable(Faraday::Response))
487
487
 
488
-
488
+
489
489
  begin
490
490
  http_response = T.must(connection).get(url) do |req|
491
491
  req.headers.merge!(headers)
@@ -522,13 +522,13 @@ module Moov
522
522
  response: http_response
523
523
  )
524
524
  end
525
-
525
+
526
526
  if http_response.nil?
527
527
  raise error if !error.nil?
528
528
  raise 'no response'
529
529
  end
530
530
  end
531
-
531
+
532
532
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
533
533
  if Utils.match_status_code(http_response.status, ['200'])
534
534
  if Utils.match_content_type(content_type, 'application/json')
@@ -624,7 +624,7 @@ module Moov
624
624
 
625
625
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
626
626
  timeout ||= @sdk_configuration.timeout
627
-
627
+
628
628
 
629
629
  connection = @sdk_configuration.client
630
630
 
@@ -639,7 +639,7 @@ module Moov
639
639
  error = T.let(nil, T.nilable(StandardError))
640
640
  http_response = T.let(nil, T.nilable(Faraday::Response))
641
641
 
642
-
642
+
643
643
  begin
644
644
  http_response = T.must(connection).post(url) do |req|
645
645
  req.body = body
@@ -676,13 +676,13 @@ module Moov
676
676
  response: http_response
677
677
  )
678
678
  end
679
-
679
+
680
680
  if http_response.nil?
681
681
  raise error if !error.nil?
682
682
  raise 'no response'
683
683
  end
684
684
  end
685
-
685
+
686
686
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
687
687
  if Utils.match_status_code(http_response.status, ['200'])
688
688
  if Utils.match_content_type(content_type, 'application/json')
@@ -751,7 +751,7 @@ module Moov
751
751
 
752
752
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
753
753
  timeout ||= @sdk_configuration.timeout
754
-
754
+
755
755
 
756
756
  connection = @sdk_configuration.client
757
757
 
@@ -766,7 +766,7 @@ module Moov
766
766
  error = T.let(nil, T.nilable(StandardError))
767
767
  http_response = T.let(nil, T.nilable(Faraday::Response))
768
768
 
769
-
769
+
770
770
  begin
771
771
  http_response = T.must(connection).get(url) do |req|
772
772
  req.headers.merge!(headers)
@@ -802,13 +802,13 @@ module Moov
802
802
  response: http_response
803
803
  )
804
804
  end
805
-
805
+
806
806
  if http_response.nil?
807
807
  raise error if !error.nil?
808
808
  raise 'no response'
809
809
  end
810
810
  end
811
-
811
+
812
812
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
813
813
  if Utils.match_status_code(http_response.status, ['200'])
814
814
  if Utils.match_content_type(content_type, 'application/json')
@@ -888,7 +888,7 @@ module Moov
888
888
 
889
889
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
890
890
  timeout ||= @sdk_configuration.timeout
891
-
891
+
892
892
 
893
893
  connection = @sdk_configuration.client
894
894
 
@@ -903,7 +903,7 @@ module Moov
903
903
  error = T.let(nil, T.nilable(StandardError))
904
904
  http_response = T.let(nil, T.nilable(Faraday::Response))
905
905
 
906
-
906
+
907
907
  begin
908
908
  http_response = T.must(connection).patch(url) do |req|
909
909
  req.body = body
@@ -940,13 +940,13 @@ module Moov
940
940
  response: http_response
941
941
  )
942
942
  end
943
-
943
+
944
944
  if http_response.nil?
945
945
  raise error if !error.nil?
946
946
  raise 'no response'
947
947
  end
948
948
  end
949
-
949
+
950
950
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
951
951
  if Utils.match_status_code(http_response.status, ['200'])
952
952
  if Utils.match_content_type(content_type, 'application/json')
@@ -1027,7 +1027,7 @@ module Moov
1027
1027
 
1028
1028
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1029
1029
  timeout ||= @sdk_configuration.timeout
1030
-
1030
+
1031
1031
 
1032
1032
  connection = @sdk_configuration.client
1033
1033
 
@@ -1042,7 +1042,7 @@ module Moov
1042
1042
  error = T.let(nil, T.nilable(StandardError))
1043
1043
  http_response = T.let(nil, T.nilable(Faraday::Response))
1044
1044
 
1045
-
1045
+
1046
1046
  begin
1047
1047
  http_response = T.must(connection).post(url) do |req|
1048
1048
  req.headers.merge!(headers)
@@ -1078,13 +1078,13 @@ module Moov
1078
1078
  response: http_response
1079
1079
  )
1080
1080
  end
1081
-
1081
+
1082
1082
  if http_response.nil?
1083
1083
  raise error if !error.nil?
1084
1084
  raise 'no response'
1085
1085
  end
1086
1086
  end
1087
-
1087
+
1088
1088
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1089
1089
  if Utils.match_status_code(http_response.status, ['200', '202'])
1090
1090
  if Utils.match_content_type(content_type, 'application/json')
@@ -1138,129 +1138,6 @@ module Moov
1138
1138
  end
1139
1139
 
1140
1140
 
1141
- sig { params(account_id: ::String, transfer_id: ::String, timeout_ms: T.nilable(Integer), http_headers: T.nilable(T::Hash[T.any(String, Symbol), String])).returns(Models::Operations::ListCancellationsResponse) }
1142
- def list_cancellations(account_id:, transfer_id:, timeout_ms: nil, http_headers: nil)
1143
- # list_cancellations - Get a list of cancellations for a transfer.
1144
- #
1145
- # To access this endpoint using a [token](https://docs.moov.io/api/authentication/access-tokens/) you'll need
1146
- # to specify the `/accounts/{accountID}/transfers.read` scope.
1147
- request = Models::Operations::ListCancellationsRequest.new(
1148
- account_id: account_id,
1149
- transfer_id: transfer_id
1150
- )
1151
- url, params = @sdk_configuration.get_server_details
1152
- base_url = Utils.template_url(url, params)
1153
- url = Utils.generate_url(
1154
- Models::Operations::ListCancellationsRequest,
1155
- base_url,
1156
- '/accounts/{accountID}/transfers/{transferID}/cancellations',
1157
- request
1158
- )
1159
- headers = {}
1160
- headers = T.cast(headers, T::Hash[String, String])
1161
- headers['Accept'] = 'application/json'
1162
- headers['user-agent'] = @sdk_configuration.user_agent
1163
-
1164
- security = @sdk_configuration.security_source&.call
1165
-
1166
- timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1167
- timeout ||= @sdk_configuration.timeout
1168
-
1169
-
1170
- connection = @sdk_configuration.client
1171
-
1172
- hook_ctx = SDKHooks::HookContext.new(
1173
- config: @sdk_configuration,
1174
- base_url: base_url,
1175
- oauth2_scopes: nil,
1176
- operation_id: 'listCancellations',
1177
- security_source: @sdk_configuration.security_source
1178
- )
1179
-
1180
- error = T.let(nil, T.nilable(StandardError))
1181
- http_response = T.let(nil, T.nilable(Faraday::Response))
1182
-
1183
-
1184
- begin
1185
- http_response = T.must(connection).get(url) do |req|
1186
- req.headers.merge!(headers)
1187
- req.options.timeout = timeout unless timeout.nil?
1188
- Utils.configure_request_security(req, security)
1189
- http_headers&.each do |key, value|
1190
- req.headers[key.to_s] = value
1191
- end
1192
-
1193
- @sdk_configuration.hooks.before_request(
1194
- hook_ctx: SDKHooks::BeforeRequestHookContext.new(
1195
- hook_ctx: hook_ctx
1196
- ),
1197
- request: req
1198
- )
1199
- end
1200
- rescue StandardError => e
1201
- error = e
1202
- ensure
1203
- if http_response.nil? || Utils.error_status?(http_response.status)
1204
- http_response = @sdk_configuration.hooks.after_error(
1205
- error: error,
1206
- hook_ctx: SDKHooks::AfterErrorHookContext.new(
1207
- hook_ctx: hook_ctx
1208
- ),
1209
- response: http_response
1210
- )
1211
- else
1212
- http_response = @sdk_configuration.hooks.after_success(
1213
- hook_ctx: SDKHooks::AfterSuccessHookContext.new(
1214
- hook_ctx: hook_ctx
1215
- ),
1216
- response: http_response
1217
- )
1218
- end
1219
-
1220
- if http_response.nil?
1221
- raise error if !error.nil?
1222
- raise 'no response'
1223
- end
1224
- end
1225
-
1226
- content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1227
- if Utils.match_status_code(http_response.status, ['200'])
1228
- if Utils.match_content_type(content_type, 'application/json')
1229
- http_response = @sdk_configuration.hooks.after_success(
1230
- hook_ctx: SDKHooks::AfterSuccessHookContext.new(
1231
- hook_ctx: hook_ctx
1232
- ),
1233
- response: http_response
1234
- )
1235
- response_data = http_response.env.response_body
1236
- obj = Crystalline.unmarshal_json(JSON.parse(response_data), Crystalline::Array.new(Models::Components::Cancellation))
1237
- response = Models::Operations::ListCancellationsResponse.new(
1238
- status_code: http_response.status,
1239
- content_type: content_type,
1240
- raw_response: http_response,
1241
- headers: http_response.headers,
1242
- cancellations: T.unsafe(obj)
1243
- )
1244
-
1245
- return response
1246
- else
1247
- raise ::Moov::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received'
1248
- end
1249
- elsif Utils.match_status_code(http_response.status, ['401', '403', '429'])
1250
- raise ::Moov::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred'
1251
- elsif Utils.match_status_code(http_response.status, ['500', '504'])
1252
- raise ::Moov::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred'
1253
- elsif Utils.match_status_code(http_response.status, ['4XX'])
1254
- raise ::Moov::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred'
1255
- elsif Utils.match_status_code(http_response.status, ['5XX'])
1256
- raise ::Moov::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'API error occurred'
1257
- else
1258
- raise ::Moov::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown status code received'
1259
-
1260
- end
1261
- end
1262
-
1263
-
1264
1141
  sig { params(account_id: ::String, transfer_id: ::String, cancellation_id: ::String, timeout_ms: T.nilable(Integer), http_headers: T.nilable(T::Hash[T.any(String, Symbol), String])).returns(Models::Operations::GetCancellationResponse) }
1265
1142
  def get_cancellation(account_id:, transfer_id:, cancellation_id:, timeout_ms: nil, http_headers: nil)
1266
1143
  # get_cancellation - Get details of a cancellation for a transfer.
@@ -1289,7 +1166,7 @@ module Moov
1289
1166
 
1290
1167
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1291
1168
  timeout ||= @sdk_configuration.timeout
1292
-
1169
+
1293
1170
 
1294
1171
  connection = @sdk_configuration.client
1295
1172
 
@@ -1304,7 +1181,7 @@ module Moov
1304
1181
  error = T.let(nil, T.nilable(StandardError))
1305
1182
  http_response = T.let(nil, T.nilable(Faraday::Response))
1306
1183
 
1307
-
1184
+
1308
1185
  begin
1309
1186
  http_response = T.must(connection).get(url) do |req|
1310
1187
  req.headers.merge!(headers)
@@ -1340,13 +1217,13 @@ module Moov
1340
1217
  response: http_response
1341
1218
  )
1342
1219
  end
1343
-
1220
+
1344
1221
  if http_response.nil?
1345
1222
  raise error if !error.nil?
1346
1223
  raise 'no response'
1347
1224
  end
1348
1225
  end
1349
-
1226
+
1350
1227
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1351
1228
  if Utils.match_status_code(http_response.status, ['200'])
1352
1229
  if Utils.match_content_type(content_type, 'application/json')
@@ -1421,7 +1298,7 @@ module Moov
1421
1298
 
1422
1299
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1423
1300
  timeout ||= @sdk_configuration.timeout
1424
-
1301
+
1425
1302
 
1426
1303
  connection = @sdk_configuration.client
1427
1304
 
@@ -1436,7 +1313,7 @@ module Moov
1436
1313
  error = T.let(nil, T.nilable(StandardError))
1437
1314
  http_response = T.let(nil, T.nilable(Faraday::Response))
1438
1315
 
1439
-
1316
+
1440
1317
  begin
1441
1318
  http_response = T.must(connection).post(url) do |req|
1442
1319
  req.body = body
@@ -1473,13 +1350,13 @@ module Moov
1473
1350
  response: http_response
1474
1351
  )
1475
1352
  end
1476
-
1353
+
1477
1354
  if http_response.nil?
1478
1355
  raise error if !error.nil?
1479
1356
  raise 'no response'
1480
1357
  end
1481
1358
  end
1482
-
1359
+
1483
1360
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1484
1361
  if Utils.match_status_code(http_response.status, ['200'])
1485
1362
  if Utils.match_content_type(content_type, 'application/json')
@@ -1612,7 +1489,7 @@ module Moov
1612
1489
 
1613
1490
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1614
1491
  timeout ||= @sdk_configuration.timeout
1615
-
1492
+
1616
1493
 
1617
1494
  connection = @sdk_configuration.client
1618
1495
 
@@ -1627,7 +1504,7 @@ module Moov
1627
1504
  error = T.let(nil, T.nilable(StandardError))
1628
1505
  http_response = T.let(nil, T.nilable(Faraday::Response))
1629
1506
 
1630
-
1507
+
1631
1508
  begin
1632
1509
  http_response = T.must(connection).get(url) do |req|
1633
1510
  req.headers.merge!(headers)
@@ -1663,13 +1540,13 @@ module Moov
1663
1540
  response: http_response
1664
1541
  )
1665
1542
  end
1666
-
1543
+
1667
1544
  if http_response.nil?
1668
1545
  raise error if !error.nil?
1669
1546
  raise 'no response'
1670
1547
  end
1671
1548
  end
1672
-
1549
+
1673
1550
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1674
1551
  if Utils.match_status_code(http_response.status, ['200'])
1675
1552
  if Utils.match_content_type(content_type, 'application/json')
@@ -1736,7 +1613,7 @@ module Moov
1736
1613
 
1737
1614
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1738
1615
  timeout ||= @sdk_configuration.timeout
1739
-
1616
+
1740
1617
 
1741
1618
  connection = @sdk_configuration.client
1742
1619
 
@@ -1751,7 +1628,7 @@ module Moov
1751
1628
  error = T.let(nil, T.nilable(StandardError))
1752
1629
  http_response = T.let(nil, T.nilable(Faraday::Response))
1753
1630
 
1754
-
1631
+
1755
1632
  begin
1756
1633
  http_response = T.must(connection).get(url) do |req|
1757
1634
  req.headers.merge!(headers)
@@ -1787,13 +1664,13 @@ module Moov
1787
1664
  response: http_response
1788
1665
  )
1789
1666
  end
1790
-
1667
+
1791
1668
  if http_response.nil?
1792
1669
  raise error if !error.nil?
1793
1670
  raise 'no response'
1794
1671
  end
1795
1672
  end
1796
-
1673
+
1797
1674
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1798
1675
  if Utils.match_status_code(http_response.status, ['200'])
1799
1676
  if Utils.match_content_type(content_type, 'application/json')
@@ -1873,7 +1750,7 @@ module Moov
1873
1750
 
1874
1751
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
1875
1752
  timeout ||= @sdk_configuration.timeout
1876
-
1753
+
1877
1754
 
1878
1755
  connection = @sdk_configuration.client
1879
1756
 
@@ -1888,7 +1765,7 @@ module Moov
1888
1765
  error = T.let(nil, T.nilable(StandardError))
1889
1766
  http_response = T.let(nil, T.nilable(Faraday::Response))
1890
1767
 
1891
-
1768
+
1892
1769
  begin
1893
1770
  http_response = T.must(connection).post(url) do |req|
1894
1771
  req.body = body
@@ -1925,13 +1802,13 @@ module Moov
1925
1802
  response: http_response
1926
1803
  )
1927
1804
  end
1928
-
1805
+
1929
1806
  if http_response.nil?
1930
1807
  raise error if !error.nil?
1931
1808
  raise 'no response'
1932
1809
  end
1933
1810
  end
1934
-
1811
+
1935
1812
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
1936
1813
  if Utils.match_status_code(http_response.status, ['200', '202'])
1937
1814
  if Utils.match_content_type(content_type, 'application/json')
@@ -69,7 +69,7 @@ module Moov
69
69
 
70
70
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
71
71
  timeout ||= @sdk_configuration.timeout
72
-
72
+
73
73
 
74
74
  connection = @sdk_configuration.client
75
75
 
@@ -84,7 +84,7 @@ module Moov
84
84
  error = T.let(nil, T.nilable(StandardError))
85
85
  http_response = T.let(nil, T.nilable(Faraday::Response))
86
86
 
87
-
87
+
88
88
  begin
89
89
  http_response = T.must(connection).get(url) do |req|
90
90
  req.headers.merge!(headers)
@@ -120,13 +120,13 @@ module Moov
120
120
  response: http_response
121
121
  )
122
122
  end
123
-
123
+
124
124
  if http_response.nil?
125
125
  raise error if !error.nil?
126
126
  raise 'no response'
127
127
  end
128
128
  end
129
-
129
+
130
130
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
131
131
  if Utils.match_status_code(http_response.status, ['200'])
132
132
  if Utils.match_content_type(content_type, 'application/json')
@@ -205,7 +205,7 @@ module Moov
205
205
 
206
206
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
207
207
  timeout ||= @sdk_configuration.timeout
208
-
208
+
209
209
 
210
210
  connection = @sdk_configuration.client
211
211
 
@@ -220,7 +220,7 @@ module Moov
220
220
  error = T.let(nil, T.nilable(StandardError))
221
221
  http_response = T.let(nil, T.nilable(Faraday::Response))
222
222
 
223
-
223
+
224
224
  begin
225
225
  http_response = T.must(connection).post(url) do |req|
226
226
  req.body = body
@@ -257,13 +257,13 @@ module Moov
257
257
  response: http_response
258
258
  )
259
259
  end
260
-
260
+
261
261
  if http_response.nil?
262
262
  raise error if !error.nil?
263
263
  raise 'no response'
264
264
  end
265
265
  end
266
-
266
+
267
267
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
268
268
  if Utils.match_status_code(http_response.status, ['200'])
269
269
  if Utils.match_content_type(content_type, 'application/json')
@@ -372,7 +372,7 @@ module Moov
372
372
 
373
373
  timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
374
374
  timeout ||= @sdk_configuration.timeout
375
-
375
+
376
376
 
377
377
  connection = @sdk_configuration.client
378
378
 
@@ -387,7 +387,7 @@ module Moov
387
387
  error = T.let(nil, T.nilable(StandardError))
388
388
  http_response = T.let(nil, T.nilable(Faraday::Response))
389
389
 
390
-
390
+
391
391
  begin
392
392
  http_response = T.must(connection).put(url) do |req|
393
393
  req.body = body
@@ -424,13 +424,13 @@ module Moov
424
424
  response: http_response
425
425
  )
426
426
  end
427
-
427
+
428
428
  if http_response.nil?
429
429
  raise error if !error.nil?
430
430
  raise 'no response'
431
431
  end
432
432
  end
433
-
433
+
434
434
  content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
435
435
  if Utils.match_status_code(http_response.status, ['200'])
436
436
  if Utils.match_content_type(content_type, 'application/json')
@@ -80,15 +80,12 @@ module Moov
80
80
  if @strategy == 'backoff' && @backoff
81
81
  retry_options[:backoff_factor] = @backoff.exponent unless @backoff.exponent.nil?
82
82
  retry_options[:interval] = (@backoff.initial_interval.to_f / 1000) unless @backoff.initial_interval.nil?
83
- retry_options[:max_interval] = (@backoff.max_interval.to_f / 1000) unless @backoff.max_interval.nil?
83
+ retry_options[:max_interval] = @backoff.max_interval unless @backoff.max_interval.nil?
84
84
 
85
85
  unless @backoff.max_elapsed_time.nil?
86
86
  stop_time = initial_time + (@backoff.max_elapsed_time.to_f / 1000)
87
87
  retry_options[:retry_if] = ->(_env, _exc) { Time.now < stop_time }
88
88
  end
89
-
90
- retry_options[:rate_limit_retry_header] = 'retry-after-ms'
91
- retry_options[:header_parser_block] = ->(value) { value.to_f / 1000 }
92
89
  end
93
90
 
94
91
  retry_options