finch-api 0.1.0.pre.alpha.29 → 0.1.0.pre.alpha.31

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 (211) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +49 -0
  3. data/README.md +1 -1
  4. data/lib/finch_api/errors.rb +25 -11
  5. data/lib/finch_api/file_part.rb +10 -7
  6. data/lib/finch_api/internal/individuals_page.rb +1 -1
  7. data/lib/finch_api/internal/page.rb +1 -1
  8. data/lib/finch_api/internal/responses_page.rb +1 -1
  9. data/lib/finch_api/internal/single_page.rb +1 -1
  10. data/lib/finch_api/internal/transport/base_client.rb +11 -7
  11. data/lib/finch_api/internal/transport/pooled_net_requester.rb +34 -31
  12. data/lib/finch_api/internal/type/base_page.rb +1 -1
  13. data/lib/finch_api/internal/type/file_input.rb +7 -4
  14. data/lib/finch_api/internal/util.rb +8 -7
  15. data/lib/finch_api/models/access_token_create_params.rb +13 -13
  16. data/lib/finch_api/models/connect/session_new_params.rb +66 -50
  17. data/lib/finch_api/models/connect/session_reauthenticate_params.rb +10 -10
  18. data/lib/finch_api/models/create_access_token_response.rb +9 -1
  19. data/lib/finch_api/models/hris/benefit_contribution.rb +124 -29
  20. data/lib/finch_api/models/hris/benefit_create_params.rb +9 -1
  21. data/lib/finch_api/models/hris/benefit_list_params.rb +9 -1
  22. data/lib/finch_api/models/hris/benefit_list_supported_benefits_params.rb +9 -1
  23. data/lib/finch_api/models/hris/benefit_retrieve_params.rb +9 -1
  24. data/lib/finch_api/models/hris/benefit_update_params.rb +9 -1
  25. data/lib/finch_api/models/hris/benefits/individual_benefit.rb +222 -6
  26. data/lib/finch_api/models/hris/benefits/individual_enroll_many_params.rb +40 -2
  27. data/lib/finch_api/models/hris/benefits/individual_enrolled_ids_params.rb +9 -1
  28. data/lib/finch_api/models/hris/benefits/individual_retrieve_many_benefits_params.rb +9 -1
  29. data/lib/finch_api/models/hris/benefits/individual_unenroll_many_params.rb +9 -1
  30. data/lib/finch_api/models/hris/company/pay_statement_item/rule_create_params.rb +9 -1
  31. data/lib/finch_api/models/hris/company/pay_statement_item/rule_delete_params.rb +9 -1
  32. data/lib/finch_api/models/hris/company/pay_statement_item/rule_list_params.rb +9 -1
  33. data/lib/finch_api/models/hris/company/pay_statement_item/rule_update_params.rb +10 -1
  34. data/lib/finch_api/models/hris/company/pay_statement_item_list_params.rb +9 -1
  35. data/lib/finch_api/models/hris/company_retrieve_params.rb +9 -1
  36. data/lib/finch_api/models/hris/directory_list_individuals_params.rb +9 -1
  37. data/lib/finch_api/models/hris/directory_list_params.rb +9 -1
  38. data/lib/finch_api/models/hris/document_list_params.rb +9 -1
  39. data/lib/finch_api/models/hris/document_response.rb +11 -11
  40. data/lib/finch_api/models/hris/document_retreive_params.rb +9 -1
  41. data/lib/finch_api/models/hris/employment_retrieve_many_params.rb +9 -1
  42. data/lib/finch_api/models/hris/individual_retrieve_many_params.rb +11 -1
  43. data/lib/finch_api/models/hris/pay_statement.rb +53 -103
  44. data/lib/finch_api/models/hris/pay_statement_retrieve_many_params.rb +9 -1
  45. data/lib/finch_api/models/hris/payment_list_params.rb +9 -1
  46. data/lib/finch_api/models/hris/supported_benefit.rb +1 -0
  47. data/lib/finch_api/models/hris/w42005.rb +20 -20
  48. data/lib/finch_api/models/hris/w42020.rb +30 -30
  49. data/lib/finch_api/models/introspection.rb +38 -23
  50. data/lib/finch_api/models/jobs/automated_list_params.rb +1 -14
  51. data/lib/finch_api/models/jobs/automated_retrieve_params.rb +1 -14
  52. data/lib/finch_api/models/jobs/manual_retrieve_params.rb +1 -14
  53. data/lib/finch_api/models/payroll/pay_group_list_params.rb +11 -1
  54. data/lib/finch_api/models/payroll/pay_group_retrieve_params.rb +9 -1
  55. data/lib/finch_api/models/provider.rb +42 -1092
  56. data/lib/finch_api/models/provider_list_response.rb +143 -0
  57. data/lib/finch_api/models/request_forwarding_forward_params.rb +10 -6
  58. data/lib/finch_api/models/request_forwarding_forward_response.rb +69 -48
  59. data/lib/finch_api/resources/access_tokens.rb +3 -3
  60. data/lib/finch_api/resources/connect/sessions.rb +12 -12
  61. data/lib/finch_api/resources/hris/benefits/individuals.rb +24 -10
  62. data/lib/finch_api/resources/hris/benefits.rb +37 -16
  63. data/lib/finch_api/resources/hris/company/pay_statement_item/rules.rb +38 -15
  64. data/lib/finch_api/resources/hris/company/pay_statement_item.rb +3 -1
  65. data/lib/finch_api/resources/hris/company.rb +6 -2
  66. data/lib/finch_api/resources/hris/directory.rb +3 -1
  67. data/lib/finch_api/resources/hris/documents.rb +9 -3
  68. data/lib/finch_api/resources/hris/employments.rb +7 -3
  69. data/lib/finch_api/resources/hris/individuals.rb +10 -4
  70. data/lib/finch_api/resources/hris/pay_statements.rb +7 -3
  71. data/lib/finch_api/resources/hris/payments.rb +3 -1
  72. data/lib/finch_api/resources/jobs/automated.rb +3 -16
  73. data/lib/finch_api/resources/jobs/manual.rb +2 -10
  74. data/lib/finch_api/resources/payroll/pay_groups.rb +12 -3
  75. data/lib/finch_api/resources/providers.rb +2 -2
  76. data/lib/finch_api/resources/request_forwarding.rb +2 -2
  77. data/lib/finch_api/version.rb +1 -1
  78. data/lib/finch_api.rb +1 -0
  79. data/rbi/finch_api/errors.rbi +29 -2
  80. data/rbi/finch_api/file_part.rbi +1 -1
  81. data/rbi/finch_api/internal/transport/base_client.rbi +4 -5
  82. data/rbi/finch_api/internal/type/base_page.rbi +1 -1
  83. data/rbi/finch_api/internal/util.rbi +1 -1
  84. data/rbi/finch_api/models/access_token_create_params.rbi +19 -13
  85. data/rbi/finch_api/models/connect/session_new_params.rbi +124 -98
  86. data/rbi/finch_api/models/connect/session_reauthenticate_params.rbi +23 -23
  87. data/rbi/finch_api/models/create_access_token_response.rbi +8 -0
  88. data/rbi/finch_api/models/hris/benefit_contribution.rbi +270 -52
  89. data/rbi/finch_api/models/hris/benefit_create_params.rbi +11 -0
  90. data/rbi/finch_api/models/hris/benefit_list_params.rbi +24 -5
  91. data/rbi/finch_api/models/hris/benefit_list_supported_benefits_params.rbi +24 -5
  92. data/rbi/finch_api/models/hris/benefit_retrieve_params.rbi +24 -5
  93. data/rbi/finch_api/models/hris/benefit_update_params.rbi +15 -1
  94. data/rbi/finch_api/models/hris/benefits/individual_benefit.rbi +515 -20
  95. data/rbi/finch_api/models/hris/benefits/individual_enroll_many_params.rbi +87 -0
  96. data/rbi/finch_api/models/hris/benefits/individual_enrolled_ids_params.rbi +22 -5
  97. data/rbi/finch_api/models/hris/benefits/individual_retrieve_many_benefits_params.rbi +11 -0
  98. data/rbi/finch_api/models/hris/benefits/individual_unenroll_many_params.rbi +11 -0
  99. data/rbi/finch_api/models/hris/company/pay_statement_item/rule_create_params.rbi +11 -0
  100. data/rbi/finch_api/models/hris/company/pay_statement_item/rule_delete_params.rbi +22 -5
  101. data/rbi/finch_api/models/hris/company/pay_statement_item/rule_list_params.rbi +22 -5
  102. data/rbi/finch_api/models/hris/company/pay_statement_item/rule_update_params.rbi +15 -1
  103. data/rbi/finch_api/models/hris/company/pay_statement_item_list_params.rbi +11 -0
  104. data/rbi/finch_api/models/hris/company_retrieve_params.rbi +24 -5
  105. data/rbi/finch_api/models/hris/directory_list_individuals_params.rbi +11 -0
  106. data/rbi/finch_api/models/hris/directory_list_params.rbi +11 -0
  107. data/rbi/finch_api/models/hris/document_list_params.rbi +11 -0
  108. data/rbi/finch_api/models/hris/document_response.rbi +14 -29
  109. data/rbi/finch_api/models/hris/document_retreive_params.rbi +24 -5
  110. data/rbi/finch_api/models/hris/employment_retrieve_many_params.rbi +11 -0
  111. data/rbi/finch_api/models/hris/individual_retrieve_many_params.rbi +16 -1
  112. data/rbi/finch_api/models/hris/pay_statement.rbi +69 -272
  113. data/rbi/finch_api/models/hris/pay_statement_retrieve_many_params.rbi +11 -0
  114. data/rbi/finch_api/models/hris/payment_list_params.rbi +11 -0
  115. data/rbi/finch_api/models/hris/supported_benefit.rbi +5 -0
  116. data/rbi/finch_api/models/hris/w42005.rbi +28 -38
  117. data/rbi/finch_api/models/hris/w42020.rbi +37 -43
  118. data/rbi/finch_api/models/introspection.rbi +57 -33
  119. data/rbi/finch_api/models/jobs/automated_list_params.rbi +0 -15
  120. data/rbi/finch_api/models/jobs/automated_retrieve_params.rbi +5 -25
  121. data/rbi/finch_api/models/jobs/manual_retrieve_params.rbi +5 -25
  122. data/rbi/finch_api/models/payroll/pay_group_list_params.rbi +11 -0
  123. data/rbi/finch_api/models/payroll/pay_group_retrieve_params.rbi +24 -5
  124. data/rbi/finch_api/models/provider.rbi +75 -2507
  125. data/rbi/finch_api/models/provider_list_response.rbi +280 -0
  126. data/rbi/finch_api/models/request_forwarding_forward_params.rbi +6 -6
  127. data/rbi/finch_api/models/request_forwarding_forward_response.rbi +93 -60
  128. data/rbi/finch_api/resources/access_tokens.rbi +5 -5
  129. data/rbi/finch_api/resources/connect/sessions.rbi +22 -14
  130. data/rbi/finch_api/resources/hris/benefits/individuals.rbi +20 -3
  131. data/rbi/finch_api/resources/hris/benefits.rbi +39 -12
  132. data/rbi/finch_api/resources/hris/company/pay_statement_item/rules.rbi +35 -8
  133. data/rbi/finch_api/resources/hris/company/pay_statement_item.rbi +3 -0
  134. data/rbi/finch_api/resources/hris/company.rbi +9 -4
  135. data/rbi/finch_api/resources/hris/directory.rbi +3 -0
  136. data/rbi/finch_api/resources/hris/documents.rbi +6 -0
  137. data/rbi/finch_api/resources/hris/employments.rbi +4 -1
  138. data/rbi/finch_api/resources/hris/individuals.rbi +10 -1
  139. data/rbi/finch_api/resources/hris/pay_statements.rbi +4 -1
  140. data/rbi/finch_api/resources/hris/payments.rbi +3 -0
  141. data/rbi/finch_api/resources/jobs/automated.rbi +1 -14
  142. data/rbi/finch_api/resources/jobs/manual.rbi +1 -9
  143. data/rbi/finch_api/resources/payroll/pay_groups.rbi +15 -2
  144. data/rbi/finch_api/resources/providers.rbi +1 -1
  145. data/rbi/finch_api/resources/request_forwarding.rbi +2 -2
  146. data/sig/finch_api/errors.rbs +7 -0
  147. data/sig/finch_api/file_part.rbs +1 -1
  148. data/sig/finch_api/models/access_token_create_params.rbs +11 -7
  149. data/sig/finch_api/models/connect/session_new_params.rbs +45 -45
  150. data/sig/finch_api/models/connect/session_reauthenticate_params.rbs +15 -15
  151. data/sig/finch_api/models/create_access_token_response.rbs +5 -0
  152. data/sig/finch_api/models/hris/benefit_contribution.rbs +107 -21
  153. data/sig/finch_api/models/hris/benefit_create_params.rbs +7 -0
  154. data/sig/finch_api/models/hris/benefit_list_params.rbs +14 -3
  155. data/sig/finch_api/models/hris/benefit_list_supported_benefits_params.rbs +14 -3
  156. data/sig/finch_api/models/hris/benefit_retrieve_params.rbs +14 -3
  157. data/sig/finch_api/models/hris/benefit_update_params.rbs +8 -1
  158. data/sig/finch_api/models/hris/benefits/individual_benefit.rbs +201 -8
  159. data/sig/finch_api/models/hris/benefits/individual_enroll_many_params.rbs +30 -1
  160. data/sig/finch_api/models/hris/benefits/individual_enrolled_ids_params.rbs +14 -3
  161. data/sig/finch_api/models/hris/benefits/individual_retrieve_many_benefits_params.rbs +7 -1
  162. data/sig/finch_api/models/hris/benefits/individual_unenroll_many_params.rbs +7 -1
  163. data/sig/finch_api/models/hris/benfit_contribution.rbs +1 -1
  164. data/sig/finch_api/models/hris/company/pay_statement_item/rule_create_params.rbs +7 -0
  165. data/sig/finch_api/models/hris/company/pay_statement_item/rule_delete_params.rbs +14 -3
  166. data/sig/finch_api/models/hris/company/pay_statement_item/rule_list_params.rbs +14 -3
  167. data/sig/finch_api/models/hris/company/pay_statement_item/rule_update_params.rbs +7 -1
  168. data/sig/finch_api/models/hris/company/pay_statement_item_list_params.rbs +7 -0
  169. data/sig/finch_api/models/hris/company_retrieve_params.rbs +14 -3
  170. data/sig/finch_api/models/hris/directory_list_individuals_params.rbs +7 -1
  171. data/sig/finch_api/models/hris/directory_list_params.rbs +7 -1
  172. data/sig/finch_api/models/hris/document_list_params.rbs +7 -0
  173. data/sig/finch_api/models/hris/document_response.rbs +11 -19
  174. data/sig/finch_api/models/hris/document_retreive_params.rbs +14 -3
  175. data/sig/finch_api/models/hris/employment_retrieve_many_params.rbs +8 -1
  176. data/sig/finch_api/models/hris/individual_retrieve_many_params.rbs +7 -0
  177. data/sig/finch_api/models/hris/pay_statement.rbs +28 -96
  178. data/sig/finch_api/models/hris/pay_statement_retrieve_many_params.rbs +8 -1
  179. data/sig/finch_api/models/hris/payment_list_params.rbs +7 -1
  180. data/sig/finch_api/models/hris/supported_benefit.rbs +2 -1
  181. data/sig/finch_api/models/hris/w42005.rbs +23 -37
  182. data/sig/finch_api/models/hris/w42020.rbs +35 -45
  183. data/sig/finch_api/models/introspection.rbs +29 -20
  184. data/sig/finch_api/models/jobs/automated_list_params.rbs +1 -7
  185. data/sig/finch_api/models/jobs/automated_retrieve_params.rbs +3 -13
  186. data/sig/finch_api/models/jobs/manual_retrieve_params.rbs +3 -13
  187. data/sig/finch_api/models/payroll/pay_group_list_params.rbs +11 -1
  188. data/sig/finch_api/models/payroll/pay_group_retrieve_params.rbs +14 -3
  189. data/sig/finch_api/models/provider.rbs +31 -1366
  190. data/sig/finch_api/models/provider_list_response.rbs +128 -0
  191. data/sig/finch_api/models/request_forwarding_forward_params.rbs +8 -8
  192. data/sig/finch_api/models/request_forwarding_forward_response.rbs +40 -30
  193. data/sig/finch_api/resources/access_tokens.rbs +2 -2
  194. data/sig/finch_api/resources/connect/sessions.rbs +9 -9
  195. data/sig/finch_api/resources/hris/benefits/individuals.rbs +4 -0
  196. data/sig/finch_api/resources/hris/benefits.rbs +5 -0
  197. data/sig/finch_api/resources/hris/company/pay_statement_item/rules.rbs +4 -0
  198. data/sig/finch_api/resources/hris/company/pay_statement_item.rbs +1 -0
  199. data/sig/finch_api/resources/hris/company.rbs +1 -0
  200. data/sig/finch_api/resources/hris/directory.rbs +1 -0
  201. data/sig/finch_api/resources/hris/documents.rbs +2 -0
  202. data/sig/finch_api/resources/hris/employments.rbs +1 -0
  203. data/sig/finch_api/resources/hris/individuals.rbs +1 -0
  204. data/sig/finch_api/resources/hris/pay_statements.rbs +1 -0
  205. data/sig/finch_api/resources/hris/payments.rbs +1 -0
  206. data/sig/finch_api/resources/jobs/automated.rbs +0 -2
  207. data/sig/finch_api/resources/jobs/manual.rbs +0 -1
  208. data/sig/finch_api/resources/payroll/pay_groups.rbs +2 -0
  209. data/sig/finch_api/resources/providers.rbs +1 -1
  210. data/sig/finch_api/resources/request_forwarding.rbs +2 -2
  211. metadata +5 -2
@@ -8,114 +8,110 @@ module FinchAPI
8
8
  extend FinchAPI::Internal::Type::RequestParameters::Converter
9
9
  include FinchAPI::Internal::Type::RequestParameters
10
10
 
11
+ # @!attribute customer_email
12
+ # Email address of the customer
13
+ #
14
+ # @return [String, nil]
15
+ required :customer_email, String, nil?: true
16
+
11
17
  # @!attribute customer_id
18
+ # Unique identifier for the customer
12
19
  #
13
20
  # @return [String]
14
21
  required :customer_id, String
15
22
 
16
23
  # @!attribute customer_name
24
+ # Name of the customer
17
25
  #
18
26
  # @return [String]
19
27
  required :customer_name, String
20
28
 
21
- # @!attribute products
22
- #
23
- # @return [Array<Symbol, FinchAPI::Models::Connect::SessionNewParams::Product>]
24
- required :products,
25
- -> { FinchAPI::Internal::Type::ArrayOf[enum: FinchAPI::Connect::SessionNewParams::Product] }
26
-
27
- # @!attribute customer_email
28
- #
29
- # @return [String, nil]
30
- optional :customer_email, String, nil?: true
31
-
32
29
  # @!attribute integration
30
+ # Integration configuration for the connect session
33
31
  #
34
32
  # @return [FinchAPI::Models::Connect::SessionNewParams::Integration, nil]
35
- optional :integration, -> { FinchAPI::Connect::SessionNewParams::Integration }, nil?: true
33
+ required :integration, -> { FinchAPI::Connect::SessionNewParams::Integration }, nil?: true
36
34
 
37
35
  # @!attribute manual
36
+ # Enable manual authentication mode
38
37
  #
39
38
  # @return [Boolean, nil]
40
- optional :manual, FinchAPI::Internal::Type::Boolean, nil?: true
39
+ required :manual, FinchAPI::Internal::Type::Boolean, nil?: true
41
40
 
42
41
  # @!attribute minutes_to_expire
43
42
  # The number of minutes until the session expires (defaults to 129,600, which is
44
43
  # 90 days)
45
44
  #
46
45
  # @return [Float, nil]
47
- optional :minutes_to_expire, Float, nil?: true
46
+ required :minutes_to_expire, Float, nil?: true
47
+
48
+ # @!attribute products
49
+ # The Finch products to request access to
50
+ #
51
+ # @return [Array<Symbol, FinchAPI::Models::Connect::SessionNewParams::Product>]
52
+ required :products,
53
+ -> { FinchAPI::Internal::Type::ArrayOf[enum: FinchAPI::Connect::SessionNewParams::Product] }
48
54
 
49
55
  # @!attribute redirect_uri
56
+ # The URI to redirect to after the Connect flow is completed
50
57
  #
51
58
  # @return [String, nil]
52
- optional :redirect_uri, String, nil?: true
59
+ required :redirect_uri, String, nil?: true
53
60
 
54
61
  # @!attribute sandbox
62
+ # Sandbox mode for testing
55
63
  #
56
64
  # @return [Symbol, FinchAPI::Models::Connect::SessionNewParams::Sandbox, nil]
57
- optional :sandbox, enum: -> { FinchAPI::Connect::SessionNewParams::Sandbox }, nil?: true
65
+ required :sandbox, enum: -> { FinchAPI::Connect::SessionNewParams::Sandbox }, nil?: true
58
66
 
59
- # @!method initialize(customer_id:, customer_name:, products:, customer_email: nil, integration: nil, manual: nil, minutes_to_expire: nil, redirect_uri: nil, sandbox: nil, request_options: {})
67
+ # @!method initialize(customer_email:, customer_id:, customer_name:, integration:, manual:, minutes_to_expire:, products:, redirect_uri:, sandbox:, request_options: {})
60
68
  # Some parameter documentations has been truncated, see
61
69
  # {FinchAPI::Models::Connect::SessionNewParams} for more details.
62
70
  #
63
- # @param customer_id [String]
71
+ # @param customer_email [String, nil] Email address of the customer
64
72
  #
65
- # @param customer_name [String]
73
+ # @param customer_id [String] Unique identifier for the customer
66
74
  #
67
- # @param products [Array<Symbol, FinchAPI::Models::Connect::SessionNewParams::Product>]
75
+ # @param customer_name [String] Name of the customer
68
76
  #
69
- # @param customer_email [String, nil]
77
+ # @param integration [FinchAPI::Models::Connect::SessionNewParams::Integration, nil] Integration configuration for the connect session
70
78
  #
71
- # @param integration [FinchAPI::Models::Connect::SessionNewParams::Integration, nil]
72
- #
73
- # @param manual [Boolean, nil]
79
+ # @param manual [Boolean, nil] Enable manual authentication mode
74
80
  #
75
81
  # @param minutes_to_expire [Float, nil] The number of minutes until the session expires (defaults to 129,600, which is 9
76
82
  #
77
- # @param redirect_uri [String, nil]
83
+ # @param products [Array<Symbol, FinchAPI::Models::Connect::SessionNewParams::Product>] The Finch products to request access to
84
+ #
85
+ # @param redirect_uri [String, nil] The URI to redirect to after the Connect flow is completed
78
86
  #
79
- # @param sandbox [Symbol, FinchAPI::Models::Connect::SessionNewParams::Sandbox, nil]
87
+ # @param sandbox [Symbol, FinchAPI::Models::Connect::SessionNewParams::Sandbox, nil] Sandbox mode for testing
80
88
  #
81
89
  # @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}]
82
90
 
83
- # The Finch products that can be requested during the Connect flow.
84
- module Product
85
- extend FinchAPI::Internal::Type::Enum
86
-
87
- COMPANY = :company
88
- DIRECTORY = :directory
89
- INDIVIDUAL = :individual
90
- EMPLOYMENT = :employment
91
- PAYMENT = :payment
92
- PAY_STATEMENT = :pay_statement
93
- BENEFITS = :benefits
94
- SSN = :ssn
95
- DEDUCTION = :deduction
96
- DOCUMENTS = :documents
97
-
98
- # @!method self.values
99
- # @return [Array<Symbol>]
100
- end
101
-
102
91
  class Integration < FinchAPI::Internal::Type::BaseModel
103
92
  # @!attribute auth_method
93
+ # The authentication method to use
104
94
  #
105
95
  # @return [Symbol, FinchAPI::Models::Connect::SessionNewParams::Integration::AuthMethod, nil]
106
- optional :auth_method,
96
+ required :auth_method,
107
97
  enum: -> { FinchAPI::Connect::SessionNewParams::Integration::AuthMethod },
108
98
  nil?: true
109
99
 
110
100
  # @!attribute provider
101
+ # The provider to integrate with
111
102
  #
112
103
  # @return [String, nil]
113
- optional :provider, String, nil?: true
104
+ required :provider, String, nil?: true
114
105
 
115
- # @!method initialize(auth_method: nil, provider: nil)
116
- # @param auth_method [Symbol, FinchAPI::Models::Connect::SessionNewParams::Integration::AuthMethod, nil]
117
- # @param provider [String, nil]
106
+ # @!method initialize(auth_method:, provider:)
107
+ # Integration configuration for the connect session
108
+ #
109
+ # @param auth_method [Symbol, FinchAPI::Models::Connect::SessionNewParams::Integration::AuthMethod, nil] The authentication method to use
110
+ #
111
+ # @param provider [String, nil] The provider to integrate with
118
112
 
113
+ # The authentication method to use
114
+ #
119
115
  # @see FinchAPI::Models::Connect::SessionNewParams::Integration#auth_method
120
116
  module AuthMethod
121
117
  extend FinchAPI::Internal::Type::Enum
@@ -130,6 +126,26 @@ module FinchAPI
130
126
  end
131
127
  end
132
128
 
129
+ # The Finch products that can be requested during the Connect flow.
130
+ module Product
131
+ extend FinchAPI::Internal::Type::Enum
132
+
133
+ BENEFITS = :benefits
134
+ COMPANY = :company
135
+ DEDUCTION = :deduction
136
+ DIRECTORY = :directory
137
+ DOCUMENTS = :documents
138
+ EMPLOYMENT = :employment
139
+ INDIVIDUAL = :individual
140
+ PAYMENT = :payment
141
+ PAY_STATEMENT = :pay_statement
142
+ SSN = :ssn
143
+
144
+ # @!method self.values
145
+ # @return [Array<Symbol>]
146
+ end
147
+
148
+ # Sandbox mode for testing
133
149
  module Sandbox
134
150
  extend FinchAPI::Internal::Type::Enum
135
151
 
@@ -18,14 +18,14 @@ module FinchAPI
18
18
  # The number of minutes until the session expires (defaults to 43,200, which is 30
19
19
  # days)
20
20
  #
21
- # @return [Integer, nil]
22
- optional :minutes_to_expire, Integer, nil?: true
21
+ # @return [Integer]
22
+ required :minutes_to_expire, Integer
23
23
 
24
24
  # @!attribute products
25
25
  # The products to request access to (optional for reauthentication)
26
26
  #
27
27
  # @return [Array<Symbol, FinchAPI::Models::Connect::SessionReauthenticateParams::Product>, nil]
28
- optional :products,
28
+ required :products,
29
29
  -> {
30
30
  FinchAPI::Internal::Type::ArrayOf[enum: FinchAPI::Connect::SessionReauthenticateParams::Product]
31
31
  },
@@ -35,15 +35,15 @@ module FinchAPI
35
35
  # The URI to redirect to after the Connect flow is completed
36
36
  #
37
37
  # @return [String, nil]
38
- optional :redirect_uri, String, nil?: true
38
+ required :redirect_uri, String, nil?: true
39
39
 
40
- # @!method initialize(connection_id:, minutes_to_expire: nil, products: nil, redirect_uri: nil, request_options: {})
40
+ # @!method initialize(connection_id:, minutes_to_expire:, products:, redirect_uri:, request_options: {})
41
41
  # Some parameter documentations has been truncated, see
42
42
  # {FinchAPI::Models::Connect::SessionReauthenticateParams} for more details.
43
43
  #
44
44
  # @param connection_id [String] The ID of the existing connection to reauthenticate
45
45
  #
46
- # @param minutes_to_expire [Integer, nil] The number of minutes until the session expires (defaults to 43,200, which is 30
46
+ # @param minutes_to_expire [Integer] The number of minutes until the session expires (defaults to 43,200, which is 30
47
47
  #
48
48
  # @param products [Array<Symbol, FinchAPI::Models::Connect::SessionReauthenticateParams::Product>, nil] The products to request access to (optional for reauthentication)
49
49
  #
@@ -55,16 +55,16 @@ module FinchAPI
55
55
  module Product
56
56
  extend FinchAPI::Internal::Type::Enum
57
57
 
58
+ BENEFITS = :benefits
58
59
  COMPANY = :company
60
+ DEDUCTION = :deduction
59
61
  DIRECTORY = :directory
60
- INDIVIDUAL = :individual
62
+ DOCUMENTS = :documents
61
63
  EMPLOYMENT = :employment
64
+ INDIVIDUAL = :individual
62
65
  PAYMENT = :payment
63
66
  PAY_STATEMENT = :pay_statement
64
- BENEFITS = :benefits
65
67
  SSN = :ssn
66
- DEDUCTION = :deduction
67
- DOCUMENTS = :documents
68
68
 
69
69
  # @!method self.values
70
70
  # @return [Array<Symbol>]
@@ -31,6 +31,12 @@ module FinchAPI
31
31
  # @return [Symbol, FinchAPI::Models::CreateAccessTokenResponse::ConnectionType]
32
32
  required :connection_type, enum: -> { FinchAPI::CreateAccessTokenResponse::ConnectionType }
33
33
 
34
+ # @!attribute entity_ids
35
+ # An array of entity IDs that can be accessed with this access token
36
+ #
37
+ # @return [Array<String>]
38
+ required :entity_ids, FinchAPI::Internal::Type::ArrayOf[String]
39
+
34
40
  # @!attribute products
35
41
  # An array of the authorized products associated with the `access_token`
36
42
  #
@@ -74,7 +80,7 @@ module FinchAPI
74
80
  # @return [String, nil]
75
81
  optional :customer_id, String, nil?: true
76
82
 
77
- # @!method initialize(access_token:, client_type:, connection_id:, connection_type:, products:, provider_id:, token_type:, account_id: nil, company_id: nil, customer_id: nil)
83
+ # @!method initialize(access_token:, client_type:, connection_id:, connection_type:, entity_ids:, products:, provider_id:, token_type:, account_id: nil, company_id: nil, customer_id: nil)
78
84
  # Some parameter documentations has been truncated, see
79
85
  # {FinchAPI::Models::CreateAccessTokenResponse} for more details.
80
86
  #
@@ -86,6 +92,8 @@ module FinchAPI
86
92
  #
87
93
  # @param connection_type [Symbol, FinchAPI::Models::CreateAccessTokenResponse::ConnectionType] The type of the connection associated with the token.
88
94
  #
95
+ # @param entity_ids [Array<String>] An array of entity IDs that can be accessed with this access token
96
+ #
89
97
  # @param products [Array<String>] An array of the authorized products associated with the `access_token`
90
98
  #
91
99
  # @param provider_id [String] The ID of the provider associated with the `access_token`
@@ -3,36 +3,131 @@
3
3
  module FinchAPI
4
4
  module Models
5
5
  module HRIS
6
- class BenefitContribution < FinchAPI::Internal::Type::BaseModel
7
- # @!attribute amount
8
- # Contribution amount in cents (if `fixed`) or basis points (if `percent`).
9
- #
10
- # @return [Integer, nil]
11
- required :amount, Integer, nil?: true
12
-
13
- # @!attribute type
14
- # Contribution type.
15
- #
16
- # @return [Symbol, FinchAPI::Models::HRIS::BenefitContribution::Type, nil]
17
- required :type, enum: -> { FinchAPI::HRIS::BenefitContribution::Type }, nil?: true
18
-
19
- # @!method initialize(amount:, type:)
20
- # @param amount [Integer, nil] Contribution amount in cents (if `fixed`) or basis points (if `percent`).
21
- #
22
- # @param type [Symbol, FinchAPI::Models::HRIS::BenefitContribution::Type, nil] Contribution type.
23
-
24
- # Contribution type.
25
- #
26
- # @see FinchAPI::Models::HRIS::BenefitContribution#type
27
- module Type
28
- extend FinchAPI::Internal::Type::Enum
29
-
30
- FIXED = :fixed
31
- PERCENT = :percent
32
-
33
- # @!method self.values
34
- # @return [Array<Symbol>]
6
+ module BenefitContribution
7
+ extend FinchAPI::Internal::Type::Union
8
+
9
+ variant -> { FinchAPI::HRIS::BenefitContribution::UnionMember0 }
10
+
11
+ variant -> { FinchAPI::HRIS::BenefitContribution::UnionMember1 }
12
+
13
+ variant -> { FinchAPI::HRIS::BenefitContribution::UnionMember2 }
14
+
15
+ class UnionMember0 < FinchAPI::Internal::Type::BaseModel
16
+ # @!attribute amount
17
+ # Contribution amount in cents.
18
+ #
19
+ # @return [Integer]
20
+ required :amount, Integer
21
+
22
+ # @!attribute type
23
+ # Fixed contribution type.
24
+ #
25
+ # @return [Symbol, FinchAPI::Models::HRIS::BenefitContribution::UnionMember0::Type]
26
+ required :type, enum: -> { FinchAPI::HRIS::BenefitContribution::UnionMember0::Type }
27
+
28
+ # @!method initialize(amount:, type:)
29
+ # @param amount [Integer] Contribution amount in cents.
30
+ #
31
+ # @param type [Symbol, FinchAPI::Models::HRIS::BenefitContribution::UnionMember0::Type] Fixed contribution type.
32
+
33
+ # Fixed contribution type.
34
+ #
35
+ # @see FinchAPI::Models::HRIS::BenefitContribution::UnionMember0#type
36
+ module Type
37
+ extend FinchAPI::Internal::Type::Enum
38
+
39
+ FIXED = :fixed
40
+
41
+ # @!method self.values
42
+ # @return [Array<Symbol>]
43
+ end
35
44
  end
45
+
46
+ class UnionMember1 < FinchAPI::Internal::Type::BaseModel
47
+ # @!attribute amount
48
+ # Contribution amount in basis points (1/100th of a percent).
49
+ #
50
+ # @return [Integer]
51
+ required :amount, Integer
52
+
53
+ # @!attribute type
54
+ # Percentage contribution type.
55
+ #
56
+ # @return [Symbol, FinchAPI::Models::HRIS::BenefitContribution::UnionMember1::Type]
57
+ required :type, enum: -> { FinchAPI::HRIS::BenefitContribution::UnionMember1::Type }
58
+
59
+ # @!method initialize(amount:, type:)
60
+ # @param amount [Integer] Contribution amount in basis points (1/100th of a percent).
61
+ #
62
+ # @param type [Symbol, FinchAPI::Models::HRIS::BenefitContribution::UnionMember1::Type] Percentage contribution type.
63
+
64
+ # Percentage contribution type.
65
+ #
66
+ # @see FinchAPI::Models::HRIS::BenefitContribution::UnionMember1#type
67
+ module Type
68
+ extend FinchAPI::Internal::Type::Enum
69
+
70
+ PERCENT = :percent
71
+
72
+ # @!method self.values
73
+ # @return [Array<Symbol>]
74
+ end
75
+ end
76
+
77
+ class UnionMember2 < FinchAPI::Internal::Type::BaseModel
78
+ # @!attribute tiers
79
+ # Array of tier objects defining employer match tiers based on employee
80
+ # contribution thresholds.
81
+ #
82
+ # @return [Array<FinchAPI::Models::HRIS::BenefitContribution::UnionMember2::Tier>]
83
+ required :tiers,
84
+ -> { FinchAPI::Internal::Type::ArrayOf[FinchAPI::HRIS::BenefitContribution::UnionMember2::Tier] }
85
+
86
+ # @!attribute type
87
+ # Tiered contribution type (only valid for company_contribution).
88
+ #
89
+ # @return [Symbol, FinchAPI::Models::HRIS::BenefitContribution::UnionMember2::Type]
90
+ required :type, enum: -> { FinchAPI::HRIS::BenefitContribution::UnionMember2::Type }
91
+
92
+ # @!method initialize(tiers:, type:)
93
+ # Some parameter documentations has been truncated, see
94
+ # {FinchAPI::Models::HRIS::BenefitContribution::UnionMember2} for more details.
95
+ #
96
+ # @param tiers [Array<FinchAPI::Models::HRIS::BenefitContribution::UnionMember2::Tier>] Array of tier objects defining employer match tiers based on employee contributi
97
+ #
98
+ # @param type [Symbol, FinchAPI::Models::HRIS::BenefitContribution::UnionMember2::Type] Tiered contribution type (only valid for company_contribution).
99
+
100
+ class Tier < FinchAPI::Internal::Type::BaseModel
101
+ # @!attribute match
102
+ #
103
+ # @return [Integer]
104
+ required :match, Integer
105
+
106
+ # @!attribute threshold
107
+ #
108
+ # @return [Integer]
109
+ required :threshold, Integer
110
+
111
+ # @!method initialize(match:, threshold:)
112
+ # @param match [Integer]
113
+ # @param threshold [Integer]
114
+ end
115
+
116
+ # Tiered contribution type (only valid for company_contribution).
117
+ #
118
+ # @see FinchAPI::Models::HRIS::BenefitContribution::UnionMember2#type
119
+ module Type
120
+ extend FinchAPI::Internal::Type::Enum
121
+
122
+ TIERED = :tiered
123
+
124
+ # @!method self.values
125
+ # @return [Array<Symbol>]
126
+ end
127
+ end
128
+
129
+ # @!method self.variants
130
+ # @return [Array(FinchAPI::Models::HRIS::BenefitContribution::UnionMember0, FinchAPI::Models::HRIS::BenefitContribution::UnionMember1, FinchAPI::Models::HRIS::BenefitContribution::UnionMember2)]
36
131
  end
37
132
  end
38
133
  end
@@ -8,6 +8,12 @@ module FinchAPI
8
8
  extend FinchAPI::Internal::Type::RequestParameters::Converter
9
9
  include FinchAPI::Internal::Type::RequestParameters
10
10
 
11
+ # @!attribute entity_ids
12
+ # The entity IDs to specify which entities' data to access.
13
+ #
14
+ # @return [Array<String>, nil]
15
+ optional :entity_ids, FinchAPI::Internal::Type::ArrayOf[String]
16
+
11
17
  # @!attribute company_contribution
12
18
  # The company match for this benefit.
13
19
  #
@@ -36,10 +42,12 @@ module FinchAPI
36
42
  # @return [Symbol, FinchAPI::Models::HRIS::BenefitType, nil]
37
43
  optional :type, enum: -> { FinchAPI::HRIS::BenefitType }, nil?: true
38
44
 
39
- # @!method initialize(company_contribution: nil, description: nil, frequency: nil, type: nil, request_options: {})
45
+ # @!method initialize(entity_ids: nil, company_contribution: nil, description: nil, frequency: nil, type: nil, request_options: {})
40
46
  # Some parameter documentations has been truncated, see
41
47
  # {FinchAPI::Models::HRIS::BenefitCreateParams} for more details.
42
48
  #
49
+ # @param entity_ids [Array<String>] The entity IDs to specify which entities' data to access.
50
+ #
43
51
  # @param company_contribution [FinchAPI::Models::HRIS::BenefitCreateParams::CompanyContribution, nil] The company match for this benefit.
44
52
  #
45
53
  # @param description [String] Name of the benefit as it appears in the provider and pay statements. Recommend
@@ -8,7 +8,15 @@ module FinchAPI
8
8
  extend FinchAPI::Internal::Type::RequestParameters::Converter
9
9
  include FinchAPI::Internal::Type::RequestParameters
10
10
 
11
- # @!method initialize(request_options: {})
11
+ # @!attribute entity_ids
12
+ # The entity IDs to specify which entities' data to access.
13
+ #
14
+ # @return [Array<String>, nil]
15
+ optional :entity_ids, FinchAPI::Internal::Type::ArrayOf[String]
16
+
17
+ # @!method initialize(entity_ids: nil, request_options: {})
18
+ # @param entity_ids [Array<String>] The entity IDs to specify which entities' data to access.
19
+ #
12
20
  # @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}]
13
21
  end
14
22
  end
@@ -8,7 +8,15 @@ module FinchAPI
8
8
  extend FinchAPI::Internal::Type::RequestParameters::Converter
9
9
  include FinchAPI::Internal::Type::RequestParameters
10
10
 
11
- # @!method initialize(request_options: {})
11
+ # @!attribute entity_ids
12
+ # The entity IDs to specify which entities' data to access.
13
+ #
14
+ # @return [Array<String>, nil]
15
+ optional :entity_ids, FinchAPI::Internal::Type::ArrayOf[String]
16
+
17
+ # @!method initialize(entity_ids: nil, request_options: {})
18
+ # @param entity_ids [Array<String>] The entity IDs to specify which entities' data to access.
19
+ #
12
20
  # @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}]
13
21
  end
14
22
  end
@@ -8,7 +8,15 @@ module FinchAPI
8
8
  extend FinchAPI::Internal::Type::RequestParameters::Converter
9
9
  include FinchAPI::Internal::Type::RequestParameters
10
10
 
11
- # @!method initialize(request_options: {})
11
+ # @!attribute entity_ids
12
+ # The entity IDs to specify which entities' data to access.
13
+ #
14
+ # @return [Array<String>, nil]
15
+ optional :entity_ids, FinchAPI::Internal::Type::ArrayOf[String]
16
+
17
+ # @!method initialize(entity_ids: nil, request_options: {})
18
+ # @param entity_ids [Array<String>] The entity IDs to specify which entities' data to access.
19
+ #
12
20
  # @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}]
13
21
  end
14
22
  end
@@ -8,13 +8,21 @@ module FinchAPI
8
8
  extend FinchAPI::Internal::Type::RequestParameters::Converter
9
9
  include FinchAPI::Internal::Type::RequestParameters
10
10
 
11
+ # @!attribute entity_ids
12
+ # The entity IDs to specify which entities' data to access.
13
+ #
14
+ # @return [Array<String>, nil]
15
+ optional :entity_ids, FinchAPI::Internal::Type::ArrayOf[String]
16
+
11
17
  # @!attribute description
12
18
  # Updated name or description.
13
19
  #
14
20
  # @return [String, nil]
15
21
  optional :description, String
16
22
 
17
- # @!method initialize(description: nil, request_options: {})
23
+ # @!method initialize(entity_ids: nil, description: nil, request_options: {})
24
+ # @param entity_ids [Array<String>] The entity IDs to specify which entities' data to access.
25
+ #
18
26
  # @param description [String] Updated name or description.
19
27
  #
20
28
  # @param request_options [FinchAPI::RequestOptions, Hash{Symbol=>Object}]