straddle 0.2.0 → 0.3.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 (111) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +23 -0
  3. data/README.md +1 -1
  4. data/lib/straddle/internal/transport/base_client.rb +7 -1
  5. data/lib/straddle/internal/transport/pooled_net_requester.rb +36 -26
  6. data/lib/straddle/internal/util.rb +5 -5
  7. data/lib/straddle/models/bridge/link_bank_account_params.rb +31 -2
  8. data/lib/straddle/models/bridge/link_create_paykey_params.rb +31 -2
  9. data/lib/straddle/models/bridge/link_create_paykey_response.rb +31 -2
  10. data/lib/straddle/models/bridge/link_create_tan_params.rb +30 -2
  11. data/lib/straddle/models/bridge/link_create_tan_response.rb +31 -2
  12. data/lib/straddle/models/bridge/link_plaid_params.rb +30 -2
  13. data/lib/straddle/models/bridge_initialize_params.rb +30 -2
  14. data/lib/straddle/models/customers/review_refresh_review_params.rb +40 -0
  15. data/lib/straddle/models/embed/linked_bank_account_list_params.rb +51 -1
  16. data/lib/straddle/models/funding_event_list_params.rb +9 -1
  17. data/lib/straddle/models/funding_event_summary_item_v1.rb +25 -1
  18. data/lib/straddle/models/funding_event_summary_paged_v1.rb +25 -1
  19. data/lib/straddle/models/paykey_reveal_response.rb +31 -2
  20. data/lib/straddle/models/paykey_summary_paged_v1.rb +30 -2
  21. data/lib/straddle/models/paykey_unmasked_v1.rb +30 -2
  22. data/lib/straddle/models/{customer_refresh_review_params.rb → paykey_update_balance_params.rb} +2 -2
  23. data/lib/straddle/models/paykey_v1.rb +30 -2
  24. data/lib/straddle/models/paykeys/review_decision_params.rb +56 -0
  25. data/lib/straddle/models/paykeys/review_get_params.rb +34 -0
  26. data/lib/straddle/models/paykeys/review_get_response.rb +642 -0
  27. data/lib/straddle/models/paykeys/review_refresh_review_params.rb +40 -0
  28. data/lib/straddle/models/payment_summary_paged_v1.rb +9 -1
  29. data/lib/straddle/models.rb +3 -3
  30. data/lib/straddle/resources/bridge/link.rb +12 -4
  31. data/lib/straddle/resources/bridge.rb +3 -1
  32. data/lib/straddle/resources/customers/review.rb +37 -0
  33. data/lib/straddle/resources/customers.rb +0 -37
  34. data/lib/straddle/resources/embed/linked_bank_accounts.rb +15 -2
  35. data/lib/straddle/resources/funding_events.rb +4 -1
  36. data/lib/straddle/resources/paykeys/review.rb +128 -0
  37. data/lib/straddle/resources/paykeys.rb +36 -39
  38. data/lib/straddle/version.rb +1 -1
  39. data/lib/straddle.rb +8 -2
  40. data/manifest.yaml +1 -0
  41. data/rbi/straddle/internal/transport/base_client.rbi +5 -0
  42. data/rbi/straddle/internal/transport/pooled_net_requester.rbi +6 -2
  43. data/rbi/straddle/internal/type/base_model.rbi +8 -4
  44. data/rbi/straddle/models/bridge/link_bank_account_params.rbi +76 -1
  45. data/rbi/straddle/models/bridge/link_create_paykey_params.rbi +76 -1
  46. data/rbi/straddle/models/bridge/link_create_paykey_response.rbi +76 -1
  47. data/rbi/straddle/models/bridge/link_create_tan_params.rbi +76 -1
  48. data/rbi/straddle/models/bridge/link_create_tan_response.rbi +76 -1
  49. data/rbi/straddle/models/bridge/link_plaid_params.rbi +76 -1
  50. data/rbi/straddle/models/bridge_initialize_params.rbi +76 -1
  51. data/rbi/straddle/models/customers/review_refresh_review_params.rbi +76 -0
  52. data/rbi/straddle/models/embed/linked_bank_account_list_params.rbi +149 -0
  53. data/rbi/straddle/models/funding_event_list_params.rbi +8 -0
  54. data/rbi/straddle/models/funding_event_summary_item_v1.rbi +24 -0
  55. data/rbi/straddle/models/funding_event_summary_paged_v1.rbi +24 -0
  56. data/rbi/straddle/models/paykey_reveal_response.rbi +76 -1
  57. data/rbi/straddle/models/paykey_summary_paged_v1.rbi +76 -1
  58. data/rbi/straddle/models/paykey_unmasked_v1.rbi +76 -1
  59. data/rbi/straddle/models/{customer_refresh_review_params.rbi → paykey_update_balance_params.rbi} +2 -2
  60. data/rbi/straddle/models/paykey_v1.rbi +76 -1
  61. data/rbi/straddle/models/paykeys/review_decision_params.rbi +115 -0
  62. data/rbi/straddle/models/paykeys/review_get_params.rbi +67 -0
  63. data/rbi/straddle/models/paykeys/review_get_response.rbi +1524 -0
  64. data/rbi/straddle/models/paykeys/review_refresh_review_params.rbi +76 -0
  65. data/rbi/straddle/models/payment_summary_paged_v1.rbi +8 -0
  66. data/rbi/straddle/models.rbi +3 -3
  67. data/rbi/straddle/resources/bridge/link.rbi +16 -0
  68. data/rbi/straddle/resources/bridge.rbi +4 -0
  69. data/rbi/straddle/resources/customers/review.rbi +27 -0
  70. data/rbi/straddle/resources/customers.rbi +0 -27
  71. data/rbi/straddle/resources/embed/linked_bank_accounts.rbi +10 -0
  72. data/rbi/straddle/resources/funding_events.rbi +3 -0
  73. data/rbi/straddle/resources/paykeys/review.rbi +94 -0
  74. data/rbi/straddle/resources/paykeys.rbi +19 -21
  75. data/sig/straddle/internal/transport/base_client.rbs +2 -0
  76. data/sig/straddle/internal/transport/pooled_net_requester.rbs +4 -1
  77. data/sig/straddle/models/bridge/link_bank_account_params.rbs +28 -1
  78. data/sig/straddle/models/bridge/link_create_paykey_params.rbs +28 -1
  79. data/sig/straddle/models/bridge/link_create_paykey_response.rbs +28 -1
  80. data/sig/straddle/models/bridge/link_create_tan_params.rbs +28 -1
  81. data/sig/straddle/models/bridge/link_create_tan_response.rbs +28 -1
  82. data/sig/straddle/models/bridge/link_plaid_params.rbs +28 -1
  83. data/sig/straddle/models/bridge_initialize_params.rbs +28 -1
  84. data/sig/straddle/models/customers/review_refresh_review_params.rbs +51 -0
  85. data/sig/straddle/models/embed/linked_bank_account_list_params.rbs +46 -0
  86. data/sig/straddle/models/funding_event_list_params.rbs +5 -0
  87. data/sig/straddle/models/funding_event_summary_item_v1.rbs +15 -0
  88. data/sig/straddle/models/funding_event_summary_paged_v1.rbs +15 -0
  89. data/sig/straddle/models/paykey_reveal_response.rbs +28 -1
  90. data/sig/straddle/models/paykey_summary_paged_v1.rbs +28 -1
  91. data/sig/straddle/models/paykey_unmasked_v1.rbs +28 -1
  92. data/sig/straddle/models/{customer_refresh_review_params.rbs → paykey_update_balance_params.rbs} +2 -2
  93. data/sig/straddle/models/paykey_v1.rbs +28 -1
  94. data/sig/straddle/models/paykeys/review_decision_params.rbs +67 -0
  95. data/sig/straddle/models/paykeys/review_get_params.rbs +44 -0
  96. data/sig/straddle/models/paykeys/review_get_response.rbs +627 -0
  97. data/sig/straddle/models/paykeys/review_refresh_review_params.rbs +51 -0
  98. data/sig/straddle/models/payment_summary_paged_v1.rbs +5 -0
  99. data/sig/straddle/models.rbs +3 -3
  100. data/sig/straddle/resources/bridge/link.rbs +4 -0
  101. data/sig/straddle/resources/bridge.rbs +1 -0
  102. data/sig/straddle/resources/customers/review.rbs +9 -0
  103. data/sig/straddle/resources/customers.rbs +0 -9
  104. data/sig/straddle/resources/embed/linked_bank_accounts.rbs +2 -0
  105. data/sig/straddle/resources/funding_events.rbs +1 -0
  106. data/sig/straddle/resources/paykeys/review.rbs +36 -0
  107. data/sig/straddle/resources/paykeys.rbs +7 -6
  108. metadata +23 -8
  109. data/lib/straddle/models/paykey_review_params.rb +0 -54
  110. data/rbi/straddle/models/paykey_review_params.rbi +0 -98
  111. data/sig/straddle/models/paykey_review_params.rbs +0 -65
@@ -0,0 +1,76 @@
1
+ # typed: strong
2
+
3
+ module Straddle
4
+ module Models
5
+ module Paykeys
6
+ class ReviewRefreshReviewParams < Straddle::Internal::Type::BaseModel
7
+ extend Straddle::Internal::Type::RequestParameters::Converter
8
+ include Straddle::Internal::Type::RequestParameters
9
+
10
+ OrHash =
11
+ T.type_alias do
12
+ T.any(
13
+ Straddle::Paykeys::ReviewRefreshReviewParams,
14
+ Straddle::Internal::AnyHash
15
+ )
16
+ end
17
+
18
+ sig { returns(T.nilable(String)) }
19
+ attr_reader :correlation_id
20
+
21
+ sig { params(correlation_id: String).void }
22
+ attr_writer :correlation_id
23
+
24
+ sig { returns(T.nilable(String)) }
25
+ attr_reader :idempotency_key
26
+
27
+ sig { params(idempotency_key: String).void }
28
+ attr_writer :idempotency_key
29
+
30
+ sig { returns(T.nilable(String)) }
31
+ attr_reader :request_id
32
+
33
+ sig { params(request_id: String).void }
34
+ attr_writer :request_id
35
+
36
+ sig { returns(T.nilable(String)) }
37
+ attr_reader :straddle_account_id
38
+
39
+ sig { params(straddle_account_id: String).void }
40
+ attr_writer :straddle_account_id
41
+
42
+ sig do
43
+ params(
44
+ correlation_id: String,
45
+ idempotency_key: String,
46
+ request_id: String,
47
+ straddle_account_id: String,
48
+ request_options: Straddle::RequestOptions::OrHash
49
+ ).returns(T.attached_class)
50
+ end
51
+ def self.new(
52
+ correlation_id: nil,
53
+ idempotency_key: nil,
54
+ request_id: nil,
55
+ straddle_account_id: nil,
56
+ request_options: {}
57
+ )
58
+ end
59
+
60
+ sig do
61
+ override.returns(
62
+ {
63
+ correlation_id: String,
64
+ idempotency_key: String,
65
+ request_id: String,
66
+ straddle_account_id: String,
67
+ request_options: Straddle::RequestOptions
68
+ }
69
+ )
70
+ end
71
+ def to_hash
72
+ end
73
+ end
74
+ end
75
+ end
76
+ end
@@ -132,6 +132,10 @@ module Straddle
132
132
  sig { params(status_details: Straddle::StatusDetailsV1::OrHash).void }
133
133
  attr_writer :status_details
134
134
 
135
+ # Trace ids.
136
+ sig { returns(T::Hash[Symbol, String]) }
137
+ attr_accessor :trace_ids
138
+
135
139
  # The time the `charge` or `payout` was last updated.
136
140
  sig { returns(Time) }
137
141
  attr_accessor :updated_at
@@ -178,6 +182,7 @@ module Straddle
178
182
  Straddle::PaymentSummaryPagedV1::Data::PaymentType::OrSymbol,
179
183
  status: Straddle::PaymentSummaryPagedV1::Data::Status::OrSymbol,
180
184
  status_details: Straddle::StatusDetailsV1::OrHash,
185
+ trace_ids: T::Hash[Symbol, String],
181
186
  updated_at: Time,
182
187
  customer_details: Straddle::CustomerDetailsV1::OrHash,
183
188
  effective_at: T.nilable(Time),
@@ -213,6 +218,8 @@ module Straddle
213
218
  status:,
214
219
  # Details about the current status of the `charge` or `payout`.
215
220
  status_details:,
221
+ # Trace ids.
222
+ trace_ids:,
216
223
  # The time the `charge` or `payout` was last updated.
217
224
  updated_at:,
218
225
  # Information about the customer associated with the charge or payout.
@@ -246,6 +253,7 @@ module Straddle
246
253
  status:
247
254
  Straddle::PaymentSummaryPagedV1::Data::Status::TaggedSymbol,
248
255
  status_details: Straddle::StatusDetailsV1,
256
+ trace_ids: T::Hash[Symbol, String],
249
257
  updated_at: Time,
250
258
  customer_details: Straddle::CustomerDetailsV1,
251
259
  effective_at: T.nilable(Time),
@@ -35,8 +35,6 @@ module Straddle
35
35
 
36
36
  CustomerListParams = Straddle::Models::CustomerListParams
37
37
 
38
- CustomerRefreshReviewParams = Straddle::Models::CustomerRefreshReviewParams
39
-
40
38
  Customers = Straddle::Models::Customers
41
39
 
42
40
  CustomerSummaryPagedV1 = Straddle::Models::CustomerSummaryPagedV1
@@ -75,7 +73,7 @@ module Straddle
75
73
 
76
74
  PaykeyRevealParams = Straddle::Models::PaykeyRevealParams
77
75
 
78
- PaykeyReviewParams = Straddle::Models::PaykeyReviewParams
76
+ Paykeys = Straddle::Models::Paykeys
79
77
 
80
78
  PaykeySummaryPagedV1 = Straddle::Models::PaykeySummaryPagedV1
81
79
 
@@ -83,6 +81,8 @@ module Straddle
83
81
 
84
82
  PaykeyUnmaskedV1 = Straddle::Models::PaykeyUnmaskedV1
85
83
 
84
+ PaykeyUpdateBalanceParams = Straddle::Models::PaykeyUpdateBalanceParams
85
+
86
86
  PaykeyV1 = Straddle::Models::PaykeyV1
87
87
 
88
88
  PaymentListParams = Straddle::Models::PaymentListParams
@@ -15,6 +15,7 @@ module Straddle
15
15
  customer_id: String,
16
16
  routing_number: String,
17
17
  config: Straddle::Bridge::LinkBankAccountParams::Config::OrHash,
18
+ external_id: T.nilable(String),
18
19
  metadata: T.nilable(T::Hash[Symbol, String]),
19
20
  correlation_id: String,
20
21
  idempotency_key: String,
@@ -34,6 +35,9 @@ module Straddle
34
35
  routing_number:,
35
36
  # Body param:
36
37
  config: nil,
38
+ # Body param: Unique identifier for the paykey in your database, used for
39
+ # cross-referencing between Straddle and your systems.
40
+ external_id: nil,
37
41
  # Body param: Up to 20 additional user-defined key-value pairs. Useful for storing
38
42
  # additional information about the paykey in a structured format.
39
43
  metadata: nil,
@@ -59,6 +63,7 @@ module Straddle
59
63
  customer_id: String,
60
64
  quiltt_token: String,
61
65
  config: Straddle::Bridge::LinkCreatePaykeyParams::Config::OrHash,
66
+ external_id: T.nilable(String),
62
67
  metadata: T.nilable(T::Hash[Symbol, String]),
63
68
  correlation_id: String,
64
69
  idempotency_key: String,
@@ -75,6 +80,9 @@ module Straddle
75
80
  quiltt_token:,
76
81
  # Body param:
77
82
  config: nil,
83
+ # Body param: Unique identifier for the paykey in your database, used for
84
+ # cross-referencing between Straddle and your systems.
85
+ external_id: nil,
78
86
  # Body param: Up to 20 additional user-defined key-value pairs. Useful for storing
79
87
  # additional information about the paykey in a structured format.
80
88
  metadata: nil,
@@ -100,6 +108,7 @@ module Straddle
100
108
  routing_number: String,
101
109
  tan: String,
102
110
  config: Straddle::Bridge::LinkCreateTanParams::Config::OrHash,
111
+ external_id: T.nilable(String),
103
112
  metadata: T.nilable(T::Hash[Symbol, String]),
104
113
  correlation_id: String,
105
114
  idempotency_key: String,
@@ -119,6 +128,9 @@ module Straddle
119
128
  tan:,
120
129
  # Body param:
121
130
  config: nil,
131
+ # Body param: Unique identifier for the paykey in your database, used for
132
+ # cross-referencing between Straddle and your systems.
133
+ external_id: nil,
122
134
  # Body param: Up to 20 additional user-defined key-value pairs. Useful for storing
123
135
  # additional information about the paykey in a structured format.
124
136
  metadata: nil,
@@ -144,6 +156,7 @@ module Straddle
144
156
  customer_id: String,
145
157
  plaid_token: String,
146
158
  config: Straddle::Bridge::LinkPlaidParams::Config::OrHash,
159
+ external_id: T.nilable(String),
147
160
  metadata: T.nilable(T::Hash[Symbol, String]),
148
161
  correlation_id: String,
149
162
  idempotency_key: String,
@@ -160,6 +173,9 @@ module Straddle
160
173
  plaid_token:,
161
174
  # Body param:
162
175
  config: nil,
176
+ # Body param: Unique identifier for the paykey in your database, used for
177
+ # cross-referencing between Straddle and your systems.
178
+ external_id: nil,
163
179
  # Body param: Up to 20 additional user-defined key-value pairs. Useful for storing
164
180
  # additional information about the paykey in a structured format.
165
181
  metadata: nil,
@@ -11,6 +11,7 @@ module Straddle
11
11
  params(
12
12
  customer_id: String,
13
13
  config: Straddle::BridgeInitializeParams::Config::OrHash,
14
+ external_id: T.nilable(String),
14
15
  correlation_id: String,
15
16
  idempotency_key: String,
16
17
  request_id: String,
@@ -24,6 +25,9 @@ module Straddle
24
25
  customer_id:,
25
26
  # Body param:
26
27
  config: nil,
28
+ # Body param: Unique identifier for the paykey in your database, used for
29
+ # cross-referencing between Straddle and your systems.
30
+ external_id: nil,
27
31
  # Header param: Optional client generated identifier to trace and debug a series
28
32
  # of requests.
29
33
  correlation_id: nil,
@@ -68,6 +68,33 @@ module Straddle
68
68
  )
69
69
  end
70
70
 
71
+ # Updates the decision of a customer's identity validation. This endpoint allows
72
+ # you to modify the outcome of a customer decision and is useful for correcting or
73
+ # updating the status of a customer's verification.
74
+ sig do
75
+ params(
76
+ id: String,
77
+ correlation_id: String,
78
+ idempotency_key: String,
79
+ request_id: String,
80
+ straddle_account_id: String,
81
+ request_options: Straddle::RequestOptions::OrHash
82
+ ).returns(Straddle::CustomerV1)
83
+ end
84
+ def refresh_review(
85
+ id,
86
+ # Optional client generated identifier to trace and debug a series of requests.
87
+ correlation_id: nil,
88
+ # Optional client generated value to use for idempotent requests.
89
+ idempotency_key: nil,
90
+ # Optional client generated identifier to trace and debug a request.
91
+ request_id: nil,
92
+ # For use by platforms to specify an account id and set scope of a request.
93
+ straddle_account_id: nil,
94
+ request_options: {}
95
+ )
96
+ end
97
+
71
98
  # @api private
72
99
  sig { params(client: Straddle::Client).returns(T.attached_class) }
73
100
  def self.new(client:)
@@ -257,33 +257,6 @@ module Straddle
257
257
  )
258
258
  end
259
259
 
260
- # Updates the decision of a customer's identity validation. This endpoint allows
261
- # you to modify the outcome of a customer decision and is useful for correcting or
262
- # updating the status of a customer's verification.
263
- sig do
264
- params(
265
- id: String,
266
- correlation_id: String,
267
- idempotency_key: String,
268
- request_id: String,
269
- straddle_account_id: String,
270
- request_options: Straddle::RequestOptions::OrHash
271
- ).returns(Straddle::CustomerV1)
272
- end
273
- def refresh_review(
274
- id,
275
- # Optional client generated identifier to trace and debug a series of requests.
276
- correlation_id: nil,
277
- # Optional client generated value to use for idempotent requests.
278
- idempotency_key: nil,
279
- # Optional client generated identifier to trace and debug a request.
280
- request_id: nil,
281
- # For use by platforms to specify an account id and set scope of a request.
282
- straddle_account_id: nil,
283
- request_options: {}
284
- )
285
- end
286
-
287
260
  # Retrieves the unmasked details, including PII, of an existing customer. Supply
288
261
  # the unique customer ID that was returned from your 'create customer' request,
289
262
  # and Straddle will return the corresponding customer information. This endpoint
@@ -101,9 +101,13 @@ module Straddle
101
101
  Straddle::Embed::LinkedBankAccountListParams::Level::OrSymbol,
102
102
  page_number: Integer,
103
103
  page_size: Integer,
104
+ purpose:
105
+ Straddle::Embed::LinkedBankAccountListParams::Purpose::OrSymbol,
104
106
  sort_by: String,
105
107
  sort_order:
106
108
  Straddle::Embed::LinkedBankAccountListParams::SortOrder::OrSymbol,
109
+ status:
110
+ Straddle::Embed::LinkedBankAccountListParams::Status::OrSymbol,
107
111
  correlation_id: String,
108
112
  request_id: String,
109
113
  request_options: Straddle::RequestOptions::OrHash
@@ -122,10 +126,16 @@ module Straddle
122
126
  page_number: nil,
123
127
  # Query param: Page size. Max value: 1000
124
128
  page_size: nil,
129
+ # Query param: The purpose of the linked bank accounts to return. Possible values:
130
+ # 'charges', 'payouts', 'billing'.
131
+ purpose: nil,
125
132
  # Query param: Sort By.
126
133
  sort_by: nil,
127
134
  # Query param: Sort Order.
128
135
  sort_order: nil,
136
+ # Query param: The status of the linked bank accounts to return. Possible values:
137
+ # 'created', 'onboarding', 'active', 'inactive', 'rejected'.
138
+ status: nil,
129
139
  # Header param: Optional client generated identifier to trace and debug a series
130
140
  # of requests.
131
141
  correlation_id: nil,
@@ -13,6 +13,7 @@ module Straddle
13
13
  event_type: Straddle::FundingEventListParams::EventType::OrSymbol,
14
14
  page_number: Integer,
15
15
  page_size: Integer,
16
+ search_text: T.nilable(String),
16
17
  sort_by: Straddle::FundingEventListParams::SortBy::OrSymbol,
17
18
  sort_order: Straddle::FundingEventListParams::SortOrder::OrSymbol,
18
19
  trace_number: T.nilable(String),
@@ -43,6 +44,8 @@ module Straddle
43
44
  page_number: nil,
44
45
  # Query param: Results page size. Max value: 1000
45
46
  page_size: nil,
47
+ # Query param: Search text.
48
+ search_text: nil,
46
49
  # Query param: The field to sort the results by.
47
50
  sort_by: nil,
48
51
  # Query param: The order in which to sort the results.
@@ -0,0 +1,94 @@
1
+ # typed: strong
2
+
3
+ module Straddle
4
+ module Resources
5
+ class Paykeys
6
+ class Review
7
+ # Update the status of a paykey when in review status
8
+ sig do
9
+ params(
10
+ id: String,
11
+ status: Straddle::Paykeys::ReviewDecisionParams::Status::OrSymbol,
12
+ correlation_id: String,
13
+ idempotency_key: String,
14
+ request_id: String,
15
+ straddle_account_id: String,
16
+ request_options: Straddle::RequestOptions::OrHash
17
+ ).returns(Straddle::PaykeyV1)
18
+ end
19
+ def decision(
20
+ # Path param:
21
+ id,
22
+ # Body param:
23
+ status:,
24
+ # Header param: Optional client generated identifier to trace and debug a series
25
+ # of requests.
26
+ correlation_id: nil,
27
+ # Header param: Optional client generated value to use for idempotent requests.
28
+ idempotency_key: nil,
29
+ # Header param: Optional client generated identifier to trace and debug a request.
30
+ request_id: nil,
31
+ # Header param: For use by platforms to specify an account id and set scope of a
32
+ # request.
33
+ straddle_account_id: nil,
34
+ request_options: {}
35
+ )
36
+ end
37
+
38
+ # Get additional details about a paykey.
39
+ sig do
40
+ params(
41
+ id: String,
42
+ correlation_id: String,
43
+ request_id: String,
44
+ straddle_account_id: String,
45
+ request_options: Straddle::RequestOptions::OrHash
46
+ ).returns(Straddle::Models::Paykeys::ReviewGetResponse)
47
+ end
48
+ def get(
49
+ id,
50
+ # Optional client generated identifier to trace and debug a series of requests.
51
+ correlation_id: nil,
52
+ # Optional client generated identifier to trace and debug a request.
53
+ request_id: nil,
54
+ # For use by platforms to specify an account id and set scope of a request.
55
+ straddle_account_id: nil,
56
+ request_options: {}
57
+ )
58
+ end
59
+
60
+ # Updates the decision of a paykey's review validation. This endpoint allows you
61
+ # to refresh the outcome of a paykey's decision and is useful for correcting or
62
+ # updating the status of a paykey's verification.
63
+ sig do
64
+ params(
65
+ id: String,
66
+ correlation_id: String,
67
+ idempotency_key: String,
68
+ request_id: String,
69
+ straddle_account_id: String,
70
+ request_options: Straddle::RequestOptions::OrHash
71
+ ).returns(Straddle::PaykeyV1)
72
+ end
73
+ def refresh_review(
74
+ id,
75
+ # Optional client generated identifier to trace and debug a series of requests.
76
+ correlation_id: nil,
77
+ # Optional client generated value to use for idempotent requests.
78
+ idempotency_key: nil,
79
+ # Optional client generated identifier to trace and debug a request.
80
+ request_id: nil,
81
+ # For use by platforms to specify an account id and set scope of a request.
82
+ straddle_account_id: nil,
83
+ request_options: {}
84
+ )
85
+ end
86
+
87
+ # @api private
88
+ sig { params(client: Straddle::Client).returns(T.attached_class) }
89
+ def self.new(client:)
90
+ end
91
+ end
92
+ end
93
+ end
94
+ end
@@ -3,6 +3,9 @@
3
3
  module Straddle
4
4
  module Resources
5
5
  class Paykeys
6
+ sig { returns(Straddle::Resources::Paykeys::Review) }
7
+ attr_reader :review
8
+
6
9
  # Returns a list of paykeys associated with a Straddle account. This endpoint
7
10
  # supports advanced sorting and filtering options.
8
11
  sig do
@@ -130,54 +133,49 @@ module Straddle
130
133
  )
131
134
  end
132
135
 
133
- # Update the status of a paykey when in review status
136
+ # Retrieves the unmasked details of an existing paykey. Supply the unique paykey
137
+ # `id` and Straddle will return the corresponding paykey record, including the
138
+ # unmasked bank account details. This endpoint needs to be enabled by Straddle for
139
+ # your account and should only be used when absolutely necessary.
134
140
  sig do
135
141
  params(
136
142
  id: String,
137
- status: Straddle::PaykeyReviewParams::Status::OrSymbol,
138
143
  correlation_id: String,
139
- idempotency_key: String,
140
144
  request_id: String,
141
145
  straddle_account_id: String,
142
146
  request_options: Straddle::RequestOptions::OrHash
143
- ).returns(Straddle::PaykeyV1)
147
+ ).returns(Straddle::PaykeyUnmaskedV1)
144
148
  end
145
- def review(
146
- # Path param:
149
+ def unmasked(
147
150
  id,
148
- # Body param:
149
- status:,
150
- # Header param: Optional client generated identifier to trace and debug a series
151
- # of requests.
151
+ # Optional client generated identifier to trace and debug a series of requests.
152
152
  correlation_id: nil,
153
- # Header param: Optional client generated value to use for idempotent requests.
154
- idempotency_key: nil,
155
- # Header param: Optional client generated identifier to trace and debug a request.
153
+ # Optional client generated identifier to trace and debug a request.
156
154
  request_id: nil,
157
- # Header param: For use by platforms to specify an account id and set scope of a
158
- # request.
155
+ # For use by platforms to specify an account id and set scope of a request.
159
156
  straddle_account_id: nil,
160
157
  request_options: {}
161
158
  )
162
159
  end
163
160
 
164
- # Retrieves the unmasked details of an existing paykey. Supply the unique paykey
165
- # `id` and Straddle will return the corresponding paykey record, including the
166
- # unmasked bank account details. This endpoint needs to be enabled by Straddle for
167
- # your account and should only be used when absolutely necessary.
161
+ # Updates the balance of a paykey. This endpoint allows you to refresh the balance
162
+ # of a paykey.
168
163
  sig do
169
164
  params(
170
165
  id: String,
171
166
  correlation_id: String,
167
+ idempotency_key: String,
172
168
  request_id: String,
173
169
  straddle_account_id: String,
174
170
  request_options: Straddle::RequestOptions::OrHash
175
- ).returns(Straddle::PaykeyUnmaskedV1)
171
+ ).returns(Straddle::PaykeyV1)
176
172
  end
177
- def unmasked(
173
+ def update_balance(
178
174
  id,
179
175
  # Optional client generated identifier to trace and debug a series of requests.
180
176
  correlation_id: nil,
177
+ # Optional client generated value to use for idempotent requests.
178
+ idempotency_key: nil,
181
179
  # Optional client generated identifier to trace and debug a request.
182
180
  request_id: nil,
183
181
  # For use by platforms to specify an account id and set scope of a request.
@@ -87,6 +87,8 @@ module Straddle
87
87
 
88
88
  private def auth_headers: -> ::Hash[String, String]
89
89
 
90
+ private def user_agent: -> String
91
+
90
92
  private def generate_idempotency_key: -> String
91
93
 
92
94
  private def build_request: (
@@ -17,7 +17,10 @@ module Straddle
17
17
 
18
18
  DEFAULT_MAX_CONNECTIONS: Integer
19
19
 
20
- def self.connect: (URI::Generic url) -> top
20
+ def self.connect: (
21
+ cert_store: OpenSSL::X509::Store,
22
+ url: URI::Generic
23
+ ) -> top
21
24
 
22
25
  def self.calibrate_socket_timeout: (top conn, Float deadline) -> void
23
26
 
@@ -8,6 +8,7 @@ module Straddle
8
8
  customer_id: String,
9
9
  routing_number: String,
10
10
  config: Straddle::Bridge::LinkBankAccountParams::Config,
11
+ external_id: String?,
11
12
  metadata: ::Hash[Symbol, String]?,
12
13
  correlation_id: String,
13
14
  idempotency_key: String,
@@ -34,6 +35,8 @@ module Straddle
34
35
  Straddle::Bridge::LinkBankAccountParams::Config
35
36
  ) -> Straddle::Bridge::LinkBankAccountParams::Config
36
37
 
38
+ attr_accessor external_id: String?
39
+
37
40
  attr_accessor metadata: ::Hash[Symbol, String]?
38
41
 
39
42
  attr_reader correlation_id: String?
@@ -58,6 +61,7 @@ module Straddle
58
61
  customer_id: String,
59
62
  routing_number: String,
60
63
  ?config: Straddle::Bridge::LinkBankAccountParams::Config,
64
+ ?external_id: String?,
61
65
  ?metadata: ::Hash[Symbol, String]?,
62
66
  ?correlation_id: String,
63
67
  ?idempotency_key: String,
@@ -72,6 +76,7 @@ module Straddle
72
76
  customer_id: String,
73
77
  routing_number: String,
74
78
  config: Straddle::Bridge::LinkBankAccountParams::Config,
79
+ external_id: String?,
75
80
  metadata: ::Hash[Symbol, String]?,
76
81
  correlation_id: String,
77
82
  idempotency_key: String,
@@ -93,10 +98,17 @@ module Straddle
93
98
 
94
99
  type config =
95
100
  {
101
+ processing_method: Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method,
96
102
  sandbox_outcome: Straddle::Models::Bridge::LinkBankAccountParams::Config::sandbox_outcome
97
103
  }
98
104
 
99
105
  class Config < Straddle::Internal::Type::BaseModel
106
+ attr_reader processing_method: Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method?
107
+
108
+ def processing_method=: (
109
+ Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method
110
+ ) -> Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method
111
+
100
112
  attr_reader sandbox_outcome: Straddle::Models::Bridge::LinkBankAccountParams::Config::sandbox_outcome?
101
113
 
102
114
  def sandbox_outcome=: (
@@ -104,14 +116,28 @@ module Straddle
104
116
  ) -> Straddle::Models::Bridge::LinkBankAccountParams::Config::sandbox_outcome
105
117
 
106
118
  def initialize: (
119
+ ?processing_method: Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method,
107
120
  ?sandbox_outcome: Straddle::Models::Bridge::LinkBankAccountParams::Config::sandbox_outcome
108
121
  ) -> void
109
122
 
110
123
  def to_hash: -> {
124
+ processing_method: Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method,
111
125
  sandbox_outcome: Straddle::Models::Bridge::LinkBankAccountParams::Config::sandbox_outcome
112
126
  }
113
127
 
114
- type sandbox_outcome = :standard | :active | :rejected
128
+ type processing_method = :inline | :background | :skip
129
+
130
+ module ProcessingMethod
131
+ extend Straddle::Internal::Type::Enum
132
+
133
+ INLINE: :inline
134
+ BACKGROUND: :background
135
+ SKIP: :skip
136
+
137
+ def self?.values: -> ::Array[Straddle::Models::Bridge::LinkBankAccountParams::Config::processing_method]
138
+ end
139
+
140
+ type sandbox_outcome = :standard | :active | :rejected | :review
115
141
 
116
142
  module SandboxOutcome
117
143
  extend Straddle::Internal::Type::Enum
@@ -119,6 +145,7 @@ module Straddle
119
145
  STANDARD: :standard
120
146
  ACTIVE: :active
121
147
  REJECTED: :rejected
148
+ REVIEW: :review
122
149
 
123
150
  def self?.values: -> ::Array[Straddle::Models::Bridge::LinkBankAccountParams::Config::sandbox_outcome]
124
151
  end