Skip to content

Commit 1839dc3

Browse files
fix(types): make externalId/naicsCode/parentCompany optional in enrollment review and kyb
1 parent 5e467b3 commit 1839dc3

3 files changed

Lines changed: 16 additions & 5 deletions

File tree

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 194
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-55d6cdcb852320054c00ae49deb0e42c086bdb82ada1ab7ac1bbbbc7c7cc0eeb.yml
3-
openapi_spec_hash: 71f86153c543bc60978d55b8a2634674
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-711671459efe47bdb250c7ac893569af9b9e1b7c60ded53a77627be76e300a02.yml
3+
openapi_spec_hash: 193dc8a880e100bb74b493de7d4703e1
44
config_hash: 1c5c139a2aa0d1d45c063f953a9bc803

lithic-java-core/src/main/kotlin/com/lithic/api/models/AccountHolderSimulateEnrollmentReviewResponse.kt

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -758,7 +758,10 @@ private constructor(
758758
* Customer-provided token that indicates a relationship with an object outside of the
759759
* Lithic ecosystem.
760760
*/
761-
fun externalId(externalId: String) = externalId(JsonField.of(externalId))
761+
fun externalId(externalId: String?) = externalId(JsonField.ofNullable(externalId))
762+
763+
/** Alias for calling [Builder.externalId] with `externalId.orElse(null)`. */
764+
fun externalId(externalId: Optional<String>) = externalId(externalId.getOrNull())
762765

763766
/**
764767
* Sets [Builder.externalId] to an arbitrary JSON value.
@@ -788,7 +791,10 @@ private constructor(
788791
* Only present when user_type == "BUSINESS". 6-digit North American Industry Classification
789792
* System (NAICS) code for the business.
790793
*/
791-
fun naicsCode(naicsCode: String) = naicsCode(JsonField.of(naicsCode))
794+
fun naicsCode(naicsCode: String?) = naicsCode(JsonField.ofNullable(naicsCode))
795+
796+
/** Alias for calling [Builder.naicsCode] with `naicsCode.orElse(null)`. */
797+
fun naicsCode(naicsCode: Optional<String>) = naicsCode(naicsCode.getOrNull())
792798

793799
/**
794800
* Sets [Builder.naicsCode] to an arbitrary JSON value.

lithic-java-core/src/main/kotlin/com/lithic/api/models/KybBusinessEntity.kt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,12 @@ private constructor(
304304
}
305305

306306
/** Parent company name (if applicable). */
307-
fun parentCompany(parentCompany: String) = parentCompany(JsonField.of(parentCompany))
307+
fun parentCompany(parentCompany: String?) =
308+
parentCompany(JsonField.ofNullable(parentCompany))
309+
310+
/** Alias for calling [Builder.parentCompany] with `parentCompany.orElse(null)`. */
311+
fun parentCompany(parentCompany: Optional<String>) =
312+
parentCompany(parentCompany.getOrNull())
308313

309314
/**
310315
* Sets [Builder.parentCompany] to an arbitrary JSON value.

0 commit comments

Comments
 (0)