@@ -147,8 +147,7 @@ private constructor(
147147 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
148148 * server responded with an unexpected value).
149149 */
150- fun accountToken (): Optional <String > =
151- Optional .ofNullable(accountToken.getNullable(" account_token" ))
150+ fun accountToken (): Optional <String > = accountToken.getOptional(" account_token" )
152151
153152 /* *
154153 * Only present when user_type == "BUSINESS". List of all entities with >25% ownership in the
@@ -158,7 +157,7 @@ private constructor(
158157 * server responded with an unexpected value).
159158 */
160159 fun beneficialOwnerEntities (): Optional <List <AccountHolderBusinessResponse >> =
161- Optional .ofNullable( beneficialOwnerEntities.getNullable (" beneficial_owner_entities" ) )
160+ beneficialOwnerEntities.getOptional (" beneficial_owner_entities" )
162161
163162 /* *
164163 * Only present when user_type == "BUSINESS". List of all individuals with >25% ownership in the
@@ -168,7 +167,7 @@ private constructor(
168167 * server responded with an unexpected value).
169168 */
170169 fun beneficialOwnerIndividuals (): Optional <List <AccountHolderIndividualResponse >> =
171- Optional .ofNullable( beneficialOwnerIndividuals.getNullable (" beneficial_owner_individuals" ) )
170+ beneficialOwnerIndividuals.getOptional (" beneficial_owner_individuals" )
172171
173172 /* *
174173 * Only applicable for customers using the KYC-Exempt workflow to enroll authorized users of
@@ -179,7 +178,7 @@ private constructor(
179178 * server responded with an unexpected value).
180179 */
181180 fun businessAccountToken (): Optional <String > =
182- Optional .ofNullable( businessAccountToken.getNullable (" business_account_token" ) )
181+ businessAccountToken.getOptional (" business_account_token" )
183182
184183 /* *
185184 * Only present when user_type == "BUSINESS". Information about the business for which the
@@ -189,7 +188,7 @@ private constructor(
189188 * server responded with an unexpected value).
190189 */
191190 fun businessEntity (): Optional <AccountHolderBusinessResponse > =
192- Optional .ofNullable( businessEntity.getNullable (" business_entity" ) )
191+ businessEntity.getOptional (" business_entity" )
193192
194193 /* *
195194 * Only present when user_type == "BUSINESS". An individual with significant responsibility for
@@ -203,7 +202,7 @@ private constructor(
203202 * server responded with an unexpected value).
204203 */
205204 fun controlPerson (): Optional <AccountHolderIndividualResponse > =
206- Optional .ofNullable( controlPerson.getNullable (" control_person" ) )
205+ controlPerson.getOptional (" control_person" )
207206
208207 /* *
209208 * < Deprecated. Use control_person.email when user_type == "BUSINESS". Use
@@ -213,16 +212,15 @@ private constructor(
213212 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
214213 * server responded with an unexpected value).
215214 */
216- fun email (): Optional <String > = Optional .ofNullable( email.getNullable (" email" ) )
215+ fun email (): Optional <String > = email.getOptional (" email" )
217216
218217 /* *
219218 * The type of KYC exemption for a KYC-Exempt Account Holder.
220219 *
221220 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
222221 * server responded with an unexpected value).
223222 */
224- fun exemptionType (): Optional <ExemptionType > =
225- Optional .ofNullable(exemptionType.getNullable(" exemption_type" ))
223+ fun exemptionType (): Optional <ExemptionType > = exemptionType.getOptional(" exemption_type" )
226224
227225 /* *
228226 * Customer-provided token that indicates a relationship with an object outside of the Lithic
@@ -231,7 +229,7 @@ private constructor(
231229 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
232230 * server responded with an unexpected value).
233231 */
234- fun externalId (): Optional <String > = Optional .ofNullable( externalId.getNullable (" external_id" ) )
232+ fun externalId (): Optional <String > = externalId.getOptional (" external_id" )
235233
236234 /* *
237235 * Only present when user_type == "INDIVIDUAL". Information about the individual for which the
@@ -241,16 +239,15 @@ private constructor(
241239 * server responded with an unexpected value).
242240 */
243241 fun individual (): Optional <AccountHolderIndividualResponse > =
244- Optional .ofNullable( individual.getNullable (" individual" ) )
242+ individual.getOptional (" individual" )
245243
246244 /* *
247245 * Only present when user_type == "BUSINESS". User-submitted description of the business.
248246 *
249247 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
250248 * server responded with an unexpected value).
251249 */
252- fun natureOfBusiness (): Optional <String > =
253- Optional .ofNullable(natureOfBusiness.getNullable(" nature_of_business" ))
250+ fun natureOfBusiness (): Optional <String > = natureOfBusiness.getOptional(" nature_of_business" )
254251
255252 /* *
256253 * < Deprecated. Use control_person.phone_number when user_type == "BUSINESS". Use
@@ -260,8 +257,7 @@ private constructor(
260257 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
261258 * server responded with an unexpected value).
262259 */
263- fun phoneNumber (): Optional <String > =
264- Optional .ofNullable(phoneNumber.getNullable(" phone_number" ))
260+ fun phoneNumber (): Optional <String > = phoneNumber.getOptional(" phone_number" )
265261
266262 /* *
267263 * Only present for "KYB_BASIC" workflow. A list of documents required for the account holder to
@@ -271,7 +267,7 @@ private constructor(
271267 * server responded with an unexpected value).
272268 */
273269 fun requiredDocuments (): Optional <List <RequiredDocument >> =
274- Optional .ofNullable( requiredDocuments.getNullable (" required_documents" ) )
270+ requiredDocuments.getOptional (" required_documents" )
275271
276272 /* *
277273 * <Deprecated. Use verification_application.status instead>
@@ -284,16 +280,15 @@ private constructor(
284280 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
285281 * server responded with an unexpected value).
286282 */
287- fun status (): Optional <Status > = Optional .ofNullable( status.getNullable (" status" ) )
283+ fun status (): Optional <Status > = status.getOptional (" status" )
288284
289285 /* *
290286 * <Deprecated. Use verification_application.status_reasons> Reason for the evaluation status.
291287 *
292288 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
293289 * server responded with an unexpected value).
294290 */
295- fun statusReasons (): Optional <List <StatusReason >> =
296- Optional .ofNullable(statusReasons.getNullable(" status_reasons" ))
291+ fun statusReasons (): Optional <List <StatusReason >> = statusReasons.getOptional(" status_reasons" )
297292
298293 /* *
299294 * The type of Account Holder. If the type is "INDIVIDUAL", the "individual" attribute will be
@@ -304,7 +299,7 @@ private constructor(
304299 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
305300 * server responded with an unexpected value).
306301 */
307- fun userType (): Optional <UserType > = Optional .ofNullable( userType.getNullable (" user_type" ) )
302+ fun userType (): Optional <UserType > = userType.getOptional (" user_type" )
308303
309304 /* *
310305 * Information about the most recent identity verification attempt
@@ -313,15 +308,15 @@ private constructor(
313308 * server responded with an unexpected value).
314309 */
315310 fun verificationApplication (): Optional <AccountHolderVerificationApplication > =
316- Optional .ofNullable( verificationApplication.getNullable (" verification_application" ) )
311+ verificationApplication.getOptional (" verification_application" )
317312
318313 /* *
319314 * Only present when user_type == "BUSINESS". Business's primary website.
320315 *
321316 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
322317 * server responded with an unexpected value).
323318 */
324- fun websiteUrl (): Optional <String > = Optional .ofNullable( websiteUrl.getNullable (" website_url" ) )
319+ fun websiteUrl (): Optional <String > = websiteUrl.getOptional (" website_url" )
325320
326321 /* *
327322 * Returns the raw JSON value of [token].
@@ -1187,8 +1182,7 @@ private constructor(
11871182 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
11881183 * server responded with an unexpected value).
11891184 */
1190- fun parentCompany (): Optional <String > =
1191- Optional .ofNullable(parentCompany.getNullable(" parent_company" ))
1185+ fun parentCompany (): Optional <String > = parentCompany.getOptional(" parent_company" )
11921186
11931187 /* *
11941188 * Returns the raw JSON value of [address].
@@ -2564,8 +2558,7 @@ private constructor(
25642558 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
25652559 * server responded with an unexpected value).
25662560 */
2567- fun created (): Optional <OffsetDateTime > =
2568- Optional .ofNullable(created.getNullable(" created" ))
2561+ fun created (): Optional <OffsetDateTime > = created.getOptional(" created" )
25692562
25702563 /* *
25712564 * KYC and KYB evaluation states.
@@ -2576,7 +2569,7 @@ private constructor(
25762569 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
25772570 * server responded with an unexpected value).
25782571 */
2579- fun status (): Optional <Status > = Optional .ofNullable( status.getNullable (" status" ) )
2572+ fun status (): Optional <Status > = status.getOptional (" status" )
25802573
25812574 /* *
25822575 * Reason for the evaluation status.
@@ -2585,16 +2578,15 @@ private constructor(
25852578 * server responded with an unexpected value).
25862579 */
25872580 fun statusReasons (): Optional <List <StatusReason >> =
2588- Optional .ofNullable( statusReasons.getNullable (" status_reasons" ) )
2581+ statusReasons.getOptional (" status_reasons" )
25892582
25902583 /* *
25912584 * Timestamp of when the application was last updated.
25922585 *
25932586 * @throws LithicInvalidDataException if the JSON field has an unexpected type (e.g. if the
25942587 * server responded with an unexpected value).
25952588 */
2596- fun updated (): Optional <OffsetDateTime > =
2597- Optional .ofNullable(updated.getNullable(" updated" ))
2589+ fun updated (): Optional <OffsetDateTime > = updated.getOptional(" updated" )
25982590
25992591 /* *
26002592 * Returns the raw JSON value of [created].
0 commit comments