finch-api 0.1.0.pre.alpha.25 → 0.1.0.pre.alpha.27

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 (59) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +29 -0
  3. data/README.md +1 -1
  4. data/lib/finch_api/client.rb +3 -1
  5. data/lib/finch_api/internal/transport/pooled_net_requester.rb +1 -9
  6. data/lib/finch_api/internal/type/array_of.rb +1 -0
  7. data/lib/finch_api/internal/type/base_model.rb +4 -9
  8. data/lib/finch_api/internal/type/converter.rb +27 -0
  9. data/lib/finch_api/internal/type/hash_of.rb +1 -0
  10. data/lib/finch_api/internal/type/union.rb +9 -7
  11. data/lib/finch_api/internal/util.rb +1 -1
  12. data/lib/finch_api/models/account_update_event.rb +28 -84
  13. data/lib/finch_api/models/disconnect_response.rb +2 -2
  14. data/lib/finch_api/models/hris/benefit_create_params.rb +1 -3
  15. data/lib/finch_api/models/hris/benefits/individual_enroll_many_params.rb +6 -18
  16. data/lib/finch_api/models/hris/company/pay_statement_item/rule_create_params.rb +3 -10
  17. data/lib/finch_api/models/hris/company/pay_statement_item_list_params.rb +1 -3
  18. data/lib/finch_api/models/hris/company_benefit.rb +1 -3
  19. data/lib/finch_api/models/hris/document_list_params.rb +1 -4
  20. data/lib/finch_api/models/hris/employment_retrieve_many_params.rb +1 -3
  21. data/lib/finch_api/models/hris/individual_retrieve_many_params.rb +1 -3
  22. data/lib/finch_api/models/hris/pay_statement.rb +1 -4
  23. data/lib/finch_api/models/hris/pay_statement_retrieve_many_params.rb +1 -3
  24. data/lib/finch_api/models/jobs/automated_async_job.rb +1 -1
  25. data/lib/finch_api/models/jobs/automated_list_params.rb +14 -1
  26. data/lib/finch_api/models/jobs/automated_retrieve_params.rb +14 -1
  27. data/lib/finch_api/models/jobs/manual_async_job.rb +5 -3
  28. data/lib/finch_api/models/jobs/manual_retrieve_params.rb +14 -1
  29. data/lib/finch_api/models/provider.rb +19 -68
  30. data/lib/finch_api/models/request_forwarding_forward_response.rb +10 -10
  31. data/lib/finch_api/models/sandbox/connection_create_params.rb +1 -4
  32. data/lib/finch_api/models/sandbox/directory_create_params.rb +1 -4
  33. data/lib/finch_api/models/sandbox/payment_create_params.rb +7 -22
  34. data/lib/finch_api/resources/jobs/automated.rb +16 -3
  35. data/lib/finch_api/resources/jobs/manual.rb +10 -2
  36. data/lib/finch_api/resources/request_forwarding.rb +2 -2
  37. data/lib/finch_api/version.rb +1 -1
  38. data/rbi/finch_api/errors.rbi +2 -2
  39. data/rbi/finch_api/internal/type/converter.rbi +54 -0
  40. data/rbi/finch_api/internal/type/union.rbi +9 -2
  41. data/rbi/finch_api/models/disconnect_response.rbi +2 -2
  42. data/rbi/finch_api/models/jobs/automated_async_job.rbi +2 -2
  43. data/rbi/finch_api/models/jobs/automated_list_params.rbi +15 -0
  44. data/rbi/finch_api/models/jobs/automated_retrieve_params.rbi +25 -5
  45. data/rbi/finch_api/models/jobs/manual_async_job.rbi +3 -3
  46. data/rbi/finch_api/models/jobs/manual_retrieve_params.rbi +25 -5
  47. data/rbi/finch_api/models/request_forwarding_forward_response.rbi +14 -14
  48. data/rbi/finch_api/resources/jobs/automated.rbi +14 -1
  49. data/rbi/finch_api/resources/jobs/manual.rbi +9 -1
  50. data/rbi/finch_api/resources/request_forwarding.rbi +2 -2
  51. data/sig/finch_api/internal/type/converter.rbs +17 -0
  52. data/sig/finch_api/internal/type/union.rbs +2 -2
  53. data/sig/finch_api/models/jobs/automated_list_params.rbs +7 -1
  54. data/sig/finch_api/models/jobs/automated_retrieve_params.rbs +13 -3
  55. data/sig/finch_api/models/jobs/manual_async_job.rbs +4 -4
  56. data/sig/finch_api/models/jobs/manual_retrieve_params.rbs +13 -3
  57. data/sig/finch_api/resources/jobs/automated.rbs +2 -0
  58. data/sig/finch_api/resources/jobs/manual.rbs +1 -0
  59. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f3c8431e4db980889ff2c1fea7dcab2ae21b4112b1820d8b63bcff5acc09b583
4
- data.tar.gz: a58d7b32889c7a9119ab8ce32375a9e032e06985362b061ae1ffef760f88dac9
3
+ metadata.gz: 01be9b1e24c793e45dc2a3e63d0fcbee0e16f72d5c22e04bb77bf802a761aa24
4
+ data.tar.gz: 4963b833fb1a24c64c2d5caa3ebd8047dbe0c88913a50b2c10d86de5c9a983d4
5
5
  SHA512:
6
- metadata.gz: d41b2f2d72b0b1d3f42d71df89b94ee74de89e363ac7d1363af87e21fa2aa208d4da3253702ea61ac4853a3fcad6a1d565e6b046ad7bb0fc241d07a21ecdd706
7
- data.tar.gz: be15170af9cdb5b095ded36138ea08224122aa6edf11030d3153e349df9a3156d75bbf19f539b776f916d80ffb2e97817d32eea5571502ece7c523aaca3de63a
6
+ metadata.gz: 8ad61d884ef0fe3c5b31fb8dd5f26a899e5446d89b6c8c8cea9f6df76ed4ccb81e4f84116690ee1e79700590c72c82a22ffa54c7448266517f57c1e0c69dbc58
7
+ data.tar.gz: '079c8a914dc98d12916da58d6fac6a6b4e01be56294786fc6b416b0ec299751f233b5aca4754ba008216184cf8accf4784ee9f61c176314e8646035df3e92c63'
data/CHANGELOG.md CHANGED
@@ -1,5 +1,34 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.0-alpha.27 (2025-08-19)
4
+
5
+ Full Changelog: [v0.1.0-alpha.26...v0.1.0-alpha.27](https://github.com/Finch-API/finch-api-ruby/compare/v0.1.0-alpha.26...v0.1.0-alpha.27)
6
+
7
+ ### Bug Fixes
8
+
9
+ * bump sorbet version and fix new type errors from the breaking change ([166381e](https://github.com/Finch-API/finch-api-ruby/commit/166381ebd49719646b7c0242605bd7caace4b780))
10
+
11
+ ## 0.1.0-alpha.26 (2025-08-14)
12
+
13
+ Full Changelog: [v0.1.0-alpha.25...v0.1.0-alpha.26](https://github.com/Finch-API/finch-api-ruby/compare/v0.1.0-alpha.25...v0.1.0-alpha.26)
14
+
15
+ ### Features
16
+
17
+ * **api:** api update ([80b711b](https://github.com/Finch-API/finch-api-ruby/commit/80b711bc0c917ce1f1f4daaac3301b5c8e5bd1e7))
18
+ * **api:** api update ([5b2d8f2](https://github.com/Finch-API/finch-api-ruby/commit/5b2d8f2d1c30039ca4d4c5acfa055b5c60acefb9))
19
+
20
+
21
+ ### Bug Fixes
22
+
23
+ * **client:** prioritise bearer auth ([d8817a5](https://github.com/Finch-API/finch-api-ruby/commit/d8817a5e6c6f289dc1dd1a5a5ad35c43049d1f0e))
24
+
25
+
26
+ ### Chores
27
+
28
+ * collect metadata from type DSL ([e919ec0](https://github.com/Finch-API/finch-api-ruby/commit/e919ec0b110aa3a5ba703bf9dd317b2ea4091a28))
29
+ * **internal:** update comment in script ([5969020](https://github.com/Finch-API/finch-api-ruby/commit/59690202144cf2295b6edc7542f10cd6932b0da2))
30
+ * update @stainless-api/prism-cli to v5.15.0 ([2953337](https://github.com/Finch-API/finch-api-ruby/commit/29533376815ef4be96be5fde8de45fcf3f48a232))
31
+
3
32
  ## 0.1.0-alpha.25 (2025-07-31)
4
33
 
5
34
  Full Changelog: [v0.1.0-alpha.24...v0.1.0-alpha.25](https://github.com/Finch-API/finch-api-ruby/compare/v0.1.0-alpha.24...v0.1.0-alpha.25)
data/README.md CHANGED
@@ -17,7 +17,7 @@ To use this gem, install via Bundler by adding the following to your application
17
17
  <!-- x-release-please-start-version -->
18
18
 
19
19
  ```ruby
20
- gem "finch-api", "~> 0.1.0.pre.alpha.25"
20
+ gem "finch-api", "~> 0.1.0.pre.alpha.27"
21
21
  ```
22
22
 
23
23
  <!-- x-release-please-end -->
@@ -58,7 +58,9 @@ module FinchAPI
58
58
  #
59
59
  # @return [Hash{String=>String}]
60
60
  private def auth_headers
61
- {**bearer_auth, **basic_auth}
61
+ return bearer_auth unless bearer_auth.empty?
62
+ return basic_auth unless basic_auth.empty?
63
+ {}
62
64
  end
63
65
 
64
66
  # @api private
@@ -193,15 +193,7 @@ module FinchAPI
193
193
  end
194
194
 
195
195
  define_sorbet_constant!(:Request) do
196
- T.type_alias do
197
- {
198
- method: Symbol,
199
- url: URI::Generic,
200
- headers: T::Hash[String, String],
201
- body: T.anything,
202
- deadline: Float
203
- }
204
- end
196
+ T.type_alias { {method: Symbol, url: URI::Generic, headers: T::Hash[String, String], body: T.anything, deadline: Float} }
205
197
  end
206
198
  end
207
199
  end
@@ -148,6 +148,7 @@ module FinchAPI
148
148
  # @option spec [Boolean] :"nil?"
149
149
  def initialize(type_info, spec = {})
150
150
  @item_type_fn = FinchAPI::Internal::Type::Converter.type_info(type_info || spec)
151
+ @meta = FinchAPI::Internal::Type::Converter.meta_info(type_info, spec)
151
152
  @nilable = spec.fetch(:nil?, false)
152
153
  end
153
154
 
@@ -52,6 +52,7 @@ module FinchAPI
52
52
  #
53
53
  # @option spec [Boolean] :"nil?"
54
54
  private def add_field(name_sym, required:, type_info:, spec:)
55
+ meta = FinchAPI::Internal::Type::Converter.meta_info(type_info, spec)
55
56
  type_fn, info =
56
57
  case type_info
57
58
  in Proc | FinchAPI::Internal::Type::Converter | Class
@@ -63,14 +64,7 @@ module FinchAPI
63
64
  setter = :"#{name_sym}="
64
65
  api_name = info.fetch(:api_name, name_sym)
65
66
  nilable = info.fetch(:nil?, false)
66
- const = if required && !nilable
67
- info.fetch(
68
- :const,
69
- FinchAPI::Internal::OMIT
70
- )
71
- else
72
- FinchAPI::Internal::OMIT
73
- end
67
+ const = required && !nilable ? info.fetch(:const, FinchAPI::Internal::OMIT) : FinchAPI::Internal::OMIT
74
68
 
75
69
  [name_sym, setter].each { undef_method(_1) } if known_fields.key?(name_sym)
76
70
 
@@ -81,7 +75,8 @@ module FinchAPI
81
75
  required: required,
82
76
  nilable: nilable,
83
77
  const: const,
84
- type_fn: type_fn
78
+ type_fn: type_fn,
79
+ meta: meta
85
80
  }
86
81
 
87
82
  define_method(setter) do |value|
@@ -98,6 +98,33 @@ module FinchAPI
98
98
  end
99
99
  end
100
100
 
101
+ # @api private
102
+ #
103
+ # @param type_info [Hash{Symbol=>Object}, Proc, FinchAPI::Internal::Type::Converter, Class] .
104
+ #
105
+ # @option type_info [NilClass, TrueClass, FalseClass, Integer, Float, Symbol] :const
106
+ #
107
+ # @option type_info [Proc] :enum
108
+ #
109
+ # @option type_info [Proc] :union
110
+ #
111
+ # @option type_info [Boolean] :"nil?"
112
+ #
113
+ # @param spec [Hash{Symbol=>Object}, Proc, FinchAPI::Internal::Type::Converter, Class] .
114
+ #
115
+ # @option spec [NilClass, TrueClass, FalseClass, Integer, Float, Symbol] :const
116
+ #
117
+ # @option spec [Proc] :enum
118
+ #
119
+ # @option spec [Proc] :union
120
+ #
121
+ # @option spec [Boolean] :"nil?"
122
+ #
123
+ # @return [Hash{Symbol=>Object}]
124
+ def meta_info(type_info, spec)
125
+ [spec, type_info].grep(Hash).first.to_h.except(:const, :enum, :union, :nil?)
126
+ end
127
+
101
128
  # @api private
102
129
  #
103
130
  # @param translate_names [Boolean]
@@ -168,6 +168,7 @@ module FinchAPI
168
168
  # @option spec [Boolean] :"nil?"
169
169
  def initialize(type_info, spec = {})
170
170
  @item_type_fn = FinchAPI::Internal::Type::Converter.type_info(type_info || spec)
171
+ @meta = FinchAPI::Internal::Type::Converter.meta_info(type_info, spec)
171
172
  @nilable = spec.fetch(:nil?, false)
172
173
  end
173
174
 
@@ -33,20 +33,20 @@ module FinchAPI
33
33
  #
34
34
  # All of the specified variant info for this union.
35
35
  #
36
- # @return [Array<Array(Symbol, Proc)>]
36
+ # @return [Array<Array(Symbol, Proc, Hash{Symbol=>Object})>]
37
37
  private def known_variants = (@known_variants ||= [])
38
38
 
39
39
  # @api private
40
40
  #
41
- # @return [Array<Array(Symbol, Object)>]
41
+ # @return [Array<Array(Symbol, Object, Hash{Symbol=>Object})>]
42
42
  protected def derefed_variants
43
- known_variants.map { |key, variant_fn| [key, variant_fn.call] }
43
+ known_variants.map { |key, variant_fn, meta| [key, variant_fn.call, meta] }
44
44
  end
45
45
 
46
46
  # All of the specified variants for this union.
47
47
  #
48
48
  # @return [Array<Object>]
49
- def variants = derefed_variants.map(&:last)
49
+ def variants = derefed_variants.map { _2 }
50
50
 
51
51
  # @api private
52
52
  #
@@ -72,12 +72,13 @@ module FinchAPI
72
72
  #
73
73
  # @option spec [Boolean] :"nil?"
74
74
  private def variant(key, spec = nil)
75
+ meta = FinchAPI::Internal::Type::Converter.meta_info(nil, spec)
75
76
  variant_info =
76
77
  case key
77
78
  in Symbol
78
- [key, FinchAPI::Internal::Type::Converter.type_info(spec)]
79
+ [key, FinchAPI::Internal::Type::Converter.type_info(spec), meta]
79
80
  in Proc | FinchAPI::Internal::Type::Converter | Class | Hash
80
- [nil, FinchAPI::Internal::Type::Converter.type_info(key)]
81
+ [nil, FinchAPI::Internal::Type::Converter.type_info(key), meta]
81
82
  end
82
83
 
83
84
  known_variants << variant_info
@@ -100,7 +101,8 @@ module FinchAPI
100
101
  return nil if key == FinchAPI::Internal::OMIT
101
102
 
102
103
  key = key.to_sym if key.is_a?(String)
103
- known_variants.find { |k,| k == key }&.last&.call
104
+ _, found = known_variants.find { |k,| k == key }
105
+ found&.call
104
106
  else
105
107
  nil
106
108
  end
@@ -244,7 +244,7 @@ module FinchAPI
244
244
  #
245
245
  # @return [String]
246
246
  def uri_origin(uri)
247
- "#{uri.scheme}://#{uri.host}#{uri.port == uri.default_port ? '' : ":#{uri.port}"}"
247
+ "#{uri.scheme}://#{uri.host}#{":#{uri.port}" unless uri.port == uri.default_port}"
248
248
  end
249
249
 
250
250
  # @api private
@@ -78,41 +78,31 @@ module FinchAPI
78
78
  #
79
79
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory, nil]
80
80
  optional :directory,
81
- -> {
82
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory
83
- }
81
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory }
84
82
 
85
83
  # @!attribute employment
86
84
  #
87
85
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment, nil]
88
86
  optional :employment,
89
- -> {
90
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment
91
- }
87
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment }
92
88
 
93
89
  # @!attribute individual
94
90
  #
95
91
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual, nil]
96
92
  optional :individual,
97
- -> {
98
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual
99
- }
93
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual }
100
94
 
101
95
  # @!attribute pay_group
102
96
  #
103
97
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayGroup, nil]
104
98
  optional :pay_group,
105
- -> {
106
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayGroup
107
- }
99
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayGroup }
108
100
 
109
101
  # @!attribute pay_statement
110
102
  #
111
103
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement, nil]
112
104
  optional :pay_statement,
113
- -> {
114
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement
115
- }
105
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement }
116
106
 
117
107
  # @!attribute payment
118
108
  #
@@ -142,17 +132,13 @@ module FinchAPI
142
132
  #
143
133
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Accounts, nil]
144
134
  optional :accounts,
145
- -> {
146
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Accounts
147
- }
135
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Accounts }
148
136
 
149
137
  # @!attribute departments
150
138
  #
151
139
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Departments, nil]
152
140
  optional :departments,
153
- -> {
154
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Departments
155
- }
141
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Departments }
156
142
 
157
143
  # @!attribute ein
158
144
  #
@@ -163,9 +149,7 @@ module FinchAPI
163
149
  #
164
150
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Entity, nil]
165
151
  optional :entity,
166
- -> {
167
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Entity
168
- }
152
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Entity }
169
153
 
170
154
  # @!attribute legal_name
171
155
  #
@@ -176,9 +160,7 @@ module FinchAPI
176
160
  #
177
161
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Locations, nil]
178
162
  optional :locations,
179
- -> {
180
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Locations
181
- }
163
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Locations }
182
164
 
183
165
  # @!attribute primary_email
184
166
  #
@@ -247,9 +229,7 @@ module FinchAPI
247
229
  #
248
230
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Departments::Parent, nil]
249
231
  optional :parent,
250
- -> {
251
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Departments::Parent
252
- }
232
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Company::Departments::Parent }
253
233
 
254
234
  # @!method initialize(name: nil, parent: nil)
255
235
  # @param name [Boolean]
@@ -332,17 +312,13 @@ module FinchAPI
332
312
  #
333
313
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals, nil]
334
314
  optional :individuals,
335
- -> {
336
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals
337
- }
315
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals }
338
316
 
339
317
  # @!attribute paging
340
318
  #
341
319
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Paging, nil]
342
320
  optional :paging,
343
- -> {
344
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Paging
345
- }
321
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Paging }
346
322
 
347
323
  # @!method initialize(individuals: nil, paging: nil)
348
324
  # @param individuals [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals]
@@ -379,9 +355,7 @@ module FinchAPI
379
355
  #
380
356
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals::Manager, nil]
381
357
  optional :manager,
382
- -> {
383
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals::Manager
384
- }
358
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Directory::Individuals::Manager }
385
359
 
386
360
  # @!attribute middle_name
387
361
  #
@@ -448,17 +422,13 @@ module FinchAPI
448
422
  #
449
423
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Department, nil]
450
424
  optional :department,
451
- -> {
452
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Department
453
- }
425
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Department }
454
426
 
455
427
  # @!attribute employment
456
428
  #
457
429
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Employment, nil]
458
430
  optional :employment,
459
- -> {
460
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Employment
461
- }
431
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Employment }
462
432
 
463
433
  # @!attribute employment_status
464
434
  #
@@ -479,9 +449,7 @@ module FinchAPI
479
449
  #
480
450
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Income, nil]
481
451
  optional :income,
482
- -> {
483
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Income
484
- }
452
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Income }
485
453
 
486
454
  # @!attribute income_history
487
455
  #
@@ -502,17 +470,13 @@ module FinchAPI
502
470
  #
503
471
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Location, nil]
504
472
  optional :location,
505
- -> {
506
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Location
507
- }
473
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Location }
508
474
 
509
475
  # @!attribute manager
510
476
  #
511
477
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Manager, nil]
512
478
  optional :manager,
513
- -> {
514
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Manager
515
- }
479
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Employment::Manager }
516
480
 
517
481
  # @!attribute middle_name
518
482
  #
@@ -668,9 +632,7 @@ module FinchAPI
668
632
  #
669
633
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::Emails, nil]
670
634
  optional :emails,
671
- -> {
672
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::Emails
673
- }
635
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::Emails }
674
636
 
675
637
  # @!attribute encrypted_ssn
676
638
  #
@@ -706,9 +668,7 @@ module FinchAPI
706
668
  #
707
669
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::PhoneNumbers, nil]
708
670
  optional :phone_numbers,
709
- -> {
710
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::PhoneNumbers
711
- }
671
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::PhoneNumbers }
712
672
 
713
673
  # @!attribute preferred_name
714
674
  #
@@ -719,9 +679,7 @@ module FinchAPI
719
679
  #
720
680
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::Residence, nil]
721
681
  optional :residence,
722
- -> {
723
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::Residence
724
- }
682
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Individual::Residence }
725
683
 
726
684
  # @!attribute ssn
727
685
  #
@@ -854,17 +812,13 @@ module FinchAPI
854
812
  #
855
813
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::Paging, nil]
856
814
  optional :paging,
857
- -> {
858
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::Paging
859
- }
815
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::Paging }
860
816
 
861
817
  # @!attribute pay_statements
862
818
  #
863
819
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements, nil]
864
820
  optional :pay_statements,
865
- -> {
866
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements
867
- }
821
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements }
868
822
 
869
823
  # @!method initialize(paging: nil, pay_statements: nil)
870
824
  # @param paging [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::Paging]
@@ -893,25 +847,19 @@ module FinchAPI
893
847
  #
894
848
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::Earnings, nil]
895
849
  optional :earnings,
896
- -> {
897
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::Earnings
898
- }
850
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::Earnings }
899
851
 
900
852
  # @!attribute employee_deductions
901
853
  #
902
854
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::EmployeeDeductions, nil]
903
855
  optional :employee_deductions,
904
- -> {
905
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::EmployeeDeductions
906
- }
856
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::EmployeeDeductions }
907
857
 
908
858
  # @!attribute employer_contributions
909
859
  #
910
860
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::EmployerContributions, nil]
911
861
  optional :employer_contributions,
912
- -> {
913
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::EmployerContributions
914
- }
862
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::EmployerContributions }
915
863
 
916
864
  # @!attribute gross_pay
917
865
  #
@@ -937,9 +885,7 @@ module FinchAPI
937
885
  #
938
886
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::Taxes, nil]
939
887
  optional :taxes,
940
- -> {
941
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::Taxes
942
- }
888
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::PayStatement::PayStatements::Taxes }
943
889
 
944
890
  # @!attribute total_hours
945
891
  #
@@ -1148,9 +1094,7 @@ module FinchAPI
1148
1094
  #
1149
1095
  # @return [FinchAPI::Models::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Payment::PayPeriod, nil]
1150
1096
  optional :pay_period,
1151
- -> {
1152
- FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Payment::PayPeriod
1153
- }
1097
+ -> { FinchAPI::AccountUpdateEvent::Data::AuthenticationMethod::SupportedFields::Payment::PayPeriod }
1154
1098
 
1155
1099
  # @!method initialize(id: nil, company_debit: nil, debit_date: nil, employee_taxes: nil, employer_taxes: nil, gross_pay: nil, individual_ids: nil, net_pay: nil, pay_date: nil, pay_frequencies: nil, pay_group_ids: nil, pay_period: nil)
1156
1100
  # @param id [Boolean]
@@ -5,13 +5,13 @@ module FinchAPI
5
5
  # @see FinchAPI::Resources::Account#disconnect
6
6
  class DisconnectResponse < FinchAPI::Internal::Type::BaseModel
7
7
  # @!attribute status
8
- # If the request is successful, Finch will return success (HTTP 200 status).
8
+ # If the request is successful, Finch will return "success" (HTTP 200 status).
9
9
  #
10
10
  # @return [String]
11
11
  required :status, String
12
12
 
13
13
  # @!method initialize(status:)
14
- # @param status [String] If the request is successful, Finch will return success (HTTP 200 status).
14
+ # @param status [String] If the request is successful, Finch will return "success" (HTTP 200 status).
15
15
  end
16
16
  end
17
17
  end
@@ -55,9 +55,7 @@ module FinchAPI
55
55
  #
56
56
  # @return [Array<FinchAPI::Models::HRIS::BenefitCreateParams::CompanyContribution::Tier>]
57
57
  required :tiers,
58
- -> {
59
- FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::BenefitCreateParams::CompanyContribution::Tier]
60
- }
58
+ -> { FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::BenefitCreateParams::CompanyContribution::Tier] }
61
59
 
62
60
  # @!attribute type
63
61
  #
@@ -14,9 +14,7 @@ module FinchAPI
14
14
  #
15
15
  # @return [Array<FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual>, nil]
16
16
  optional :individuals,
17
- -> {
18
- FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual]
19
- }
17
+ -> { FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual] }
20
18
 
21
19
  # @!method initialize(individuals: nil, request_options: {})
22
20
  # @param individuals [Array<FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual>] Array of the individual_id to enroll and a configuration object.
@@ -49,9 +47,7 @@ module FinchAPI
49
47
  #
50
48
  # @return [Symbol, FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::AnnualContributionLimit, nil]
51
49
  optional :annual_contribution_limit,
52
- enum: -> {
53
- FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::AnnualContributionLimit
54
- }
50
+ enum: -> { FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::AnnualContributionLimit }
55
51
 
56
52
  # @!attribute annual_maximum
57
53
  # Maximum annual amount in cents
@@ -69,9 +65,7 @@ module FinchAPI
69
65
  #
70
66
  # @return [FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::CompanyContribution, nil]
71
67
  optional :company_contribution,
72
- -> {
73
- FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::CompanyContribution
74
- }
68
+ -> { FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::CompanyContribution }
75
69
 
76
70
  # @!attribute effective_date
77
71
  # The date the enrollment will take effect
@@ -83,9 +77,7 @@ module FinchAPI
83
77
  #
84
78
  # @return [FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::EmployeeDeduction, nil]
85
79
  optional :employee_deduction,
86
- -> {
87
- FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::EmployeeDeduction
88
- }
80
+ -> { FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::EmployeeDeduction }
89
81
 
90
82
  # @!method initialize(annual_contribution_limit: nil, annual_maximum: nil, catch_up: nil, company_contribution: nil, effective_date: nil, employee_deduction: nil)
91
83
  # Some parameter documentations has been truncated, see
@@ -131,9 +123,7 @@ module FinchAPI
131
123
  #
132
124
  # @return [Symbol, FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::CompanyContribution::Type, nil]
133
125
  optional :type,
134
- enum: -> {
135
- FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::CompanyContribution::Type
136
- }
126
+ enum: -> { FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::CompanyContribution::Type }
137
127
 
138
128
  # @!method initialize(amount: nil, type: nil)
139
129
  # Some parameter documentations has been truncated, see
@@ -169,9 +159,7 @@ module FinchAPI
169
159
  #
170
160
  # @return [Symbol, FinchAPI::Models::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::EmployeeDeduction::Type, nil]
171
161
  optional :type,
172
- enum: -> {
173
- FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::EmployeeDeduction::Type
174
- }
162
+ enum: -> { FinchAPI::HRIS::Benefits::IndividualEnrollManyParams::Individual::Configuration::EmployeeDeduction::Type }
175
163
 
176
164
  # @!method initialize(amount: nil, type: nil)
177
165
  # Some parameter documentations has been truncated, see
@@ -14,18 +14,13 @@ module FinchAPI
14
14
  # Specifies the fields to be applied when the condition is met.
15
15
  #
16
16
  # @return [FinchAPI::Models::HRIS::Company::PayStatementItem::RuleCreateParams::Attributes, nil]
17
- optional :attributes,
18
- -> {
19
- FinchAPI::HRIS::Company::PayStatementItem::RuleCreateParams::Attributes
20
- }
17
+ optional :attributes, -> { FinchAPI::HRIS::Company::PayStatementItem::RuleCreateParams::Attributes }
21
18
 
22
19
  # @!attribute conditions
23
20
  #
24
21
  # @return [Array<FinchAPI::Models::HRIS::Company::PayStatementItem::RuleCreateParams::Condition>, nil]
25
22
  optional :conditions,
26
- -> {
27
- FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::Company::PayStatementItem::RuleCreateParams::Condition]
28
- }
23
+ -> { FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::Company::PayStatementItem::RuleCreateParams::Condition] }
29
24
 
30
25
  # @!attribute effective_end_date
31
26
  # Specifies when the rules should stop applying rules based on the date.
@@ -89,9 +84,7 @@ module FinchAPI
89
84
  #
90
85
  # @return [Symbol, FinchAPI::Models::HRIS::Company::PayStatementItem::RuleCreateParams::Condition::Operator, nil]
91
86
  optional :operator,
92
- enum: -> {
93
- FinchAPI::HRIS::Company::PayStatementItem::RuleCreateParams::Condition::Operator
94
- }
87
+ enum: -> { FinchAPI::HRIS::Company::PayStatementItem::RuleCreateParams::Condition::Operator }
95
88
 
96
89
  # @!attribute value
97
90
  # The value of the field to be checked in the rule.