From ee0b90db7cf144c61c23891ff8d026b0b6c358da Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 28 Apr 2026 04:38:56 +0000 Subject: [PATCH 01/11] feat: support setting headers via env --- .../main/kotlin/com/cas_parser/api/core/ClientOptions.kt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt index e5fac28..4fb3496 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt @@ -375,6 +375,14 @@ private constructor( (System.getProperty("casparser.apiKey") ?: System.getenv("CAS_PARSER_API_KEY"))?.let { apiKey(it) } + System.getenv("CAS_PARSER_CUSTOM_HEADERS")?.let { customHeadersEnv -> + for (line in customHeadersEnv.split("\n")) { + val colon = line.indexOf(':') + if (colon >= 0) { + putHeader(line.substring(0, colon).trim(), line.substring(colon + 1).trim()) + } + } + } } /** From e0f458f9a0f2a30dc57114fdf7389743a3866ccb Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 30 Apr 2026 04:25:38 +0000 Subject: [PATCH 02/11] codegen metadata --- .stats.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.stats.yml b/.stats.yml index e26d438..4aee240 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 21 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser%2Fcas-parser-e5c0c65637cdf3a6c4360b8193973b73a3d35ad1056ef607c3319ef03e591a55.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-e5c0c65637cdf3a6c4360b8193973b73a3d35ad1056ef607c3319ef03e591a55.yml openapi_spec_hash: 7515d1e5fe3130b9f5411f7aacbc8a64 config_hash: 5509bb7a961ae2e79114b24c381606d4 From 74f96b622b09dd094f302de0d554559d00960d0c Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 1 May 2026 03:25:18 +0000 Subject: [PATCH 03/11] codegen metadata --- .stats.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.stats.yml b/.stats.yml index 4aee240..d5b8f44 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 21 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-e5c0c65637cdf3a6c4360b8193973b73a3d35ad1056ef607c3319ef03e591a55.yml +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-2fd773786951b723a5d7d7342bf1c6ab46f08bd2851e916d188faae379d5aa4c.yml openapi_spec_hash: 7515d1e5fe3130b9f5411f7aacbc8a64 config_hash: 5509bb7a961ae2e79114b24c381606d4 From 2744bf455786d58b2ccb12e2a7e8f125586b71b1 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sat, 2 May 2026 10:18:07 +0000 Subject: [PATCH 04/11] feat(api): api update --- .stats.yml | 4 +-- .../InboundEmailCreateResponse.kt | 27 +++++++++---------- .../inboundemail/InboundEmailListParams.kt | 4 +-- .../inboundemail/InboundEmailListResponse.kt | 27 +++++++++---------- .../InboundEmailRetrieveParams.kt | 2 +- .../InboundEmailRetrieveResponse.kt | 27 +++++++++---------- .../models/inbox/InboxListCasFilesResponse.kt | 12 +++++++-- .../async/InboundEmailServiceAsync.kt | 6 ++--- .../services/blocking/InboundEmailService.kt | 6 ++--- .../InboundEmailDeleteResponseTest.kt | 6 ++--- 10 files changed, 60 insertions(+), 61 deletions(-) diff --git a/.stats.yml b/.stats.yml index d5b8f44..cd58596 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 21 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-2fd773786951b723a5d7d7342bf1c6ab46f08bd2851e916d188faae379d5aa4c.yml -openapi_spec_hash: 7515d1e5fe3130b9f5411f7aacbc8a64 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-c7cca9a7a8e15f8a584c22eab142c4af72a329117f63cc3b3f7cabb25410f2ce.yml +openapi_spec_hash: f40d936e433bbf8c98179d0b36f304c8 config_hash: 5509bb7a961ae2e79114b24c381606d4 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt index 90aaaf9..77d0134 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt @@ -80,8 +80,8 @@ private constructor( allowedSources.getOptional("allowed_sources") /** - * Webhook URL for email notifications. `null` means files are only retrievable via `GET - * /v4/inbound-email/{id}/files` (pull delivery). + * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable via + * `GET /v4/inbound-email/{id}/files` (SDK / pull mode). * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -89,7 +89,7 @@ private constructor( fun callbackUrl(): Optional = callbackUrl.getOptional("callback_url") /** - * When the mailbox was created + * When the inbound email was created * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -129,7 +129,7 @@ private constructor( fun reference(): Optional = reference.getOptional("reference") /** - * Current mailbox status + * Current inbound email lifecycle status * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -137,7 +137,7 @@ private constructor( fun status(): Optional = status.getOptional("status") /** - * When the mailbox was last updated + * When the inbound email was last updated * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -293,13 +293,10 @@ private constructor( } /** - * Webhook URL for email notifications. `null` means files are only retrievable via `GET - * /v4/inbound-email/{id}/files` (pull delivery). + * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable + * via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). */ - fun callbackUrl(callbackUrl: String?) = callbackUrl(JsonField.ofNullable(callbackUrl)) - - /** Alias for calling [Builder.callbackUrl] with `callbackUrl.orElse(null)`. */ - fun callbackUrl(callbackUrl: Optional) = callbackUrl(callbackUrl.getOrNull()) + fun callbackUrl(callbackUrl: String) = callbackUrl(JsonField.of(callbackUrl)) /** * Sets [Builder.callbackUrl] to an arbitrary JSON value. @@ -310,7 +307,7 @@ private constructor( */ fun callbackUrl(callbackUrl: JsonField) = apply { this.callbackUrl = callbackUrl } - /** When the mailbox was created */ + /** When the inbound email was created */ fun createdAt(createdAt: OffsetDateTime) = createdAt(JsonField.of(createdAt)) /** @@ -374,7 +371,7 @@ private constructor( */ fun reference(reference: JsonField) = apply { this.reference = reference } - /** Current mailbox status */ + /** Current inbound email lifecycle status */ fun status(status: Status) = status(JsonField.of(status)) /** @@ -385,7 +382,7 @@ private constructor( */ fun status(status: JsonField) = apply { this.status = status } - /** When the mailbox was last updated */ + /** When the inbound email was last updated */ fun updatedAt(updatedAt: OffsetDateTime) = updatedAt(JsonField.of(updatedAt)) /** @@ -723,7 +720,7 @@ private constructor( override fun toString() = "Metadata{additionalProperties=$additionalProperties}" } - /** Current mailbox status */ + /** Current inbound email lifecycle status */ class Status @JsonCreator private constructor(private val value: JsonField) : Enum { /** diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt index aea16e2..aadb63b 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt @@ -14,8 +14,8 @@ import java.util.Optional import kotlin.jvm.optionals.getOrNull /** - * List all mailboxes associated with your API key. Returns active and inactive mailboxes (deleted - * mailboxes are excluded). + * List all inbound emails associated with your API key. Returns active and paused inbound emails + * (deleted ones are excluded). */ class InboundEmailListParams private constructor( diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt index 0412e52..9c8a3c0 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt @@ -351,8 +351,8 @@ private constructor( allowedSources.getOptional("allowed_sources") /** - * Webhook URL for email notifications. `null` means files are only retrievable via `GET - * /v4/inbound-email/{id}/files` (pull delivery). + * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable + * via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -360,7 +360,7 @@ private constructor( fun callbackUrl(): Optional = callbackUrl.getOptional("callback_url") /** - * When the mailbox was created + * When the inbound email was created * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -400,7 +400,7 @@ private constructor( fun reference(): Optional = reference.getOptional("reference") /** - * Current mailbox status + * Current inbound email lifecycle status * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -408,7 +408,7 @@ private constructor( fun status(): Optional = status.getOptional("status") /** - * When the mailbox was last updated + * When the inbound email was last updated * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -564,13 +564,10 @@ private constructor( } /** - * Webhook URL for email notifications. `null` means files are only retrievable via `GET - * /v4/inbound-email/{id}/files` (pull delivery). + * Webhook URL for email notifications. Empty string (`""`) means files are only + * retrievable via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). */ - fun callbackUrl(callbackUrl: String?) = callbackUrl(JsonField.ofNullable(callbackUrl)) - - /** Alias for calling [Builder.callbackUrl] with `callbackUrl.orElse(null)`. */ - fun callbackUrl(callbackUrl: Optional) = callbackUrl(callbackUrl.getOrNull()) + fun callbackUrl(callbackUrl: String) = callbackUrl(JsonField.of(callbackUrl)) /** * Sets [Builder.callbackUrl] to an arbitrary JSON value. @@ -583,7 +580,7 @@ private constructor( this.callbackUrl = callbackUrl } - /** When the mailbox was created */ + /** When the inbound email was created */ fun createdAt(createdAt: OffsetDateTime) = createdAt(JsonField.of(createdAt)) /** @@ -651,7 +648,7 @@ private constructor( */ fun reference(reference: JsonField) = apply { this.reference = reference } - /** Current mailbox status */ + /** Current inbound email lifecycle status */ fun status(status: Status) = status(JsonField.of(status)) /** @@ -663,7 +660,7 @@ private constructor( */ fun status(status: JsonField) = apply { this.status = status } - /** When the mailbox was last updated */ + /** When the inbound email was last updated */ fun updatedAt(updatedAt: OffsetDateTime) = updatedAt(JsonField.of(updatedAt)) /** @@ -1007,7 +1004,7 @@ private constructor( override fun toString() = "Metadata{additionalProperties=$additionalProperties}" } - /** Current mailbox status */ + /** Current inbound email lifecycle status */ class Status @JsonCreator private constructor(private val value: JsonField) : Enum { /** diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveParams.kt index 1c0676b..676faaa 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveParams.kt @@ -9,7 +9,7 @@ import java.util.Objects import java.util.Optional import kotlin.jvm.optionals.getOrNull -/** Retrieve details of a specific mailbox including statistics. */ +/** Retrieve details of a specific inbound email including statistics. */ class InboundEmailRetrieveParams private constructor( private val inboundEmailId: String?, diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt index 39aad18..7521768 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt @@ -80,8 +80,8 @@ private constructor( allowedSources.getOptional("allowed_sources") /** - * Webhook URL for email notifications. `null` means files are only retrievable via `GET - * /v4/inbound-email/{id}/files` (pull delivery). + * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable via + * `GET /v4/inbound-email/{id}/files` (SDK / pull mode). * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -89,7 +89,7 @@ private constructor( fun callbackUrl(): Optional = callbackUrl.getOptional("callback_url") /** - * When the mailbox was created + * When the inbound email was created * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -129,7 +129,7 @@ private constructor( fun reference(): Optional = reference.getOptional("reference") /** - * Current mailbox status + * Current inbound email lifecycle status * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -137,7 +137,7 @@ private constructor( fun status(): Optional = status.getOptional("status") /** - * When the mailbox was last updated + * When the inbound email was last updated * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -293,13 +293,10 @@ private constructor( } /** - * Webhook URL for email notifications. `null` means files are only retrievable via `GET - * /v4/inbound-email/{id}/files` (pull delivery). + * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable + * via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). */ - fun callbackUrl(callbackUrl: String?) = callbackUrl(JsonField.ofNullable(callbackUrl)) - - /** Alias for calling [Builder.callbackUrl] with `callbackUrl.orElse(null)`. */ - fun callbackUrl(callbackUrl: Optional) = callbackUrl(callbackUrl.getOrNull()) + fun callbackUrl(callbackUrl: String) = callbackUrl(JsonField.of(callbackUrl)) /** * Sets [Builder.callbackUrl] to an arbitrary JSON value. @@ -310,7 +307,7 @@ private constructor( */ fun callbackUrl(callbackUrl: JsonField) = apply { this.callbackUrl = callbackUrl } - /** When the mailbox was created */ + /** When the inbound email was created */ fun createdAt(createdAt: OffsetDateTime) = createdAt(JsonField.of(createdAt)) /** @@ -374,7 +371,7 @@ private constructor( */ fun reference(reference: JsonField) = apply { this.reference = reference } - /** Current mailbox status */ + /** Current inbound email lifecycle status */ fun status(status: Status) = status(JsonField.of(status)) /** @@ -385,7 +382,7 @@ private constructor( */ fun status(status: JsonField) = apply { this.status = status } - /** When the mailbox was last updated */ + /** When the inbound email was last updated */ fun updatedAt(updatedAt: OffsetDateTime) = updatedAt(JsonField.of(updatedAt)) /** @@ -723,7 +720,7 @@ private constructor( override fun toString() = "Metadata{additionalProperties=$additionalProperties}" } - /** Current mailbox status */ + /** Current inbound email lifecycle status */ class Status @JsonCreator private constructor(private val value: JsonField) : Enum { /** diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt index 1373c71..e4b8285 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt @@ -285,7 +285,10 @@ private constructor( fun casType(): Optional = casType.getOptional("cas_type") /** - * URL expiration time in seconds (default 86400 = 24 hours) + * URL expiration time in seconds. Defaults vary by source: + * - Gmail Inbox Import: 86400 (24h) + * - Inbound Email (webhook mode): 172800 (48h) + * - Inbound Email (SDK mode): aligned with the session TTL (~30 min) * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -477,7 +480,12 @@ private constructor( */ fun casType(casType: JsonField) = apply { this.casType = casType } - /** URL expiration time in seconds (default 86400 = 24 hours) */ + /** + * URL expiration time in seconds. Defaults vary by source: + * - Gmail Inbox Import: 86400 (24h) + * - Inbound Email (webhook mode): 172800 (48h) + * - Inbound Email (SDK mode): aligned with the session TTL (~30 min) + */ fun expiresIn(expiresIn: Long) = expiresIn(JsonField.of(expiresIn)) /** diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/async/InboundEmailServiceAsync.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/async/InboundEmailServiceAsync.kt index 70d732d..cfd29f4 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/async/InboundEmailServiceAsync.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/async/InboundEmailServiceAsync.kt @@ -81,7 +81,7 @@ interface InboundEmailServiceAsync { fun create(requestOptions: RequestOptions): CompletableFuture = create(InboundEmailCreateParams.none(), requestOptions) - /** Retrieve details of a specific mailbox including statistics. */ + /** Retrieve details of a specific inbound email including statistics. */ fun retrieve(inboundEmailId: String): CompletableFuture = retrieve(inboundEmailId, InboundEmailRetrieveParams.none()) @@ -119,8 +119,8 @@ interface InboundEmailServiceAsync { retrieve(inboundEmailId, InboundEmailRetrieveParams.none(), requestOptions) /** - * List all mailboxes associated with your API key. Returns active and inactive mailboxes - * (deleted mailboxes are excluded). + * List all inbound emails associated with your API key. Returns active and paused inbound + * emails (deleted ones are excluded). */ fun list(): CompletableFuture = list(InboundEmailListParams.none()) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/blocking/InboundEmailService.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/blocking/InboundEmailService.kt index 6b52989..ab31236 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/blocking/InboundEmailService.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/services/blocking/InboundEmailService.kt @@ -80,7 +80,7 @@ interface InboundEmailService { fun create(requestOptions: RequestOptions): InboundEmailCreateResponse = create(InboundEmailCreateParams.none(), requestOptions) - /** Retrieve details of a specific mailbox including statistics. */ + /** Retrieve details of a specific inbound email including statistics. */ fun retrieve(inboundEmailId: String): InboundEmailRetrieveResponse = retrieve(inboundEmailId, InboundEmailRetrieveParams.none()) @@ -116,8 +116,8 @@ interface InboundEmailService { retrieve(inboundEmailId, InboundEmailRetrieveParams.none(), requestOptions) /** - * List all mailboxes associated with your API key. Returns active and inactive mailboxes - * (deleted mailboxes are excluded). + * List all inbound emails associated with your API key. Returns active and paused inbound + * emails (deleted ones are excluded). */ fun list(): InboundEmailListResponse = list(InboundEmailListParams.none()) diff --git a/cas-parser-java-core/src/test/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponseTest.kt b/cas-parser-java-core/src/test/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponseTest.kt index 0c8f6fe..476763e 100644 --- a/cas-parser-java-core/src/test/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponseTest.kt +++ b/cas-parser-java-core/src/test/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponseTest.kt @@ -13,11 +13,11 @@ internal class InboundEmailDeleteResponseTest { fun create() { val inboundEmailDeleteResponse = InboundEmailDeleteResponse.builder() - .msg("Mailbox deleted successfully") + .msg("Inbound email deleted successfully") .status("success") .build() - assertThat(inboundEmailDeleteResponse.msg()).contains("Mailbox deleted successfully") + assertThat(inboundEmailDeleteResponse.msg()).contains("Inbound email deleted successfully") assertThat(inboundEmailDeleteResponse.status()).contains("success") } @@ -26,7 +26,7 @@ internal class InboundEmailDeleteResponseTest { val jsonMapper = jsonMapper() val inboundEmailDeleteResponse = InboundEmailDeleteResponse.builder() - .msg("Mailbox deleted successfully") + .msg("Inbound email deleted successfully") .status("success") .build() From 298bc41836f9daa2d97dd46cb1cff7a2f8116117 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sat, 2 May 2026 11:18:11 +0000 Subject: [PATCH 05/11] feat(api): api update --- .stats.yml | 4 ++-- .../api/models/inboundemail/InboundEmailCreateResponse.kt | 8 ++++---- .../api/models/inboundemail/InboundEmailListResponse.kt | 8 ++++---- .../models/inboundemail/InboundEmailRetrieveResponse.kt | 8 ++++---- .../api/models/inbox/InboxListCasFilesResponse.kt | 8 ++++---- 5 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.stats.yml b/.stats.yml index cd58596..d224bd8 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 21 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-c7cca9a7a8e15f8a584c22eab142c4af72a329117f63cc3b3f7cabb25410f2ce.yml -openapi_spec_hash: f40d936e433bbf8c98179d0b36f304c8 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-0dce3ce202e44ecf2270f6ca42942cc297bbeeafddb3128f8230ba3ae85c7551.yml +openapi_spec_hash: e9cef5743f686d9f12910c81832accca config_hash: 5509bb7a961ae2e79114b24c381606d4 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt index 77d0134..c3bf786 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt @@ -80,8 +80,8 @@ private constructor( allowedSources.getOptional("allowed_sources") /** - * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable via - * `GET /v4/inbound-email/{id}/files` (SDK / pull mode). + * Webhook URL for email notifications. If set, we POST each parsed email here. If omitted, + * files are only retrievable via `GET /v4/inbound-email/{id}/files`. * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -293,8 +293,8 @@ private constructor( } /** - * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable - * via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). + * Webhook URL for email notifications. If set, we POST each parsed email here. If omitted, + * files are only retrievable via `GET /v4/inbound-email/{id}/files`. */ fun callbackUrl(callbackUrl: String) = callbackUrl(JsonField.of(callbackUrl)) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt index 9c8a3c0..17b898d 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt @@ -351,8 +351,8 @@ private constructor( allowedSources.getOptional("allowed_sources") /** - * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable - * via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). + * Webhook URL for email notifications. If set, we POST each parsed email here. If omitted, + * files are only retrievable via `GET /v4/inbound-email/{id}/files`. * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -564,8 +564,8 @@ private constructor( } /** - * Webhook URL for email notifications. Empty string (`""`) means files are only - * retrievable via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). + * Webhook URL for email notifications. If set, we POST each parsed email here. If + * omitted, files are only retrievable via `GET /v4/inbound-email/{id}/files`. */ fun callbackUrl(callbackUrl: String) = callbackUrl(JsonField.of(callbackUrl)) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt index 7521768..9b4c99a 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt @@ -80,8 +80,8 @@ private constructor( allowedSources.getOptional("allowed_sources") /** - * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable via - * `GET /v4/inbound-email/{id}/files` (SDK / pull mode). + * Webhook URL for email notifications. If set, we POST each parsed email here. If omitted, + * files are only retrievable via `GET /v4/inbound-email/{id}/files`. * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if the * server responded with an unexpected value). @@ -293,8 +293,8 @@ private constructor( } /** - * Webhook URL for email notifications. Empty string (`""`) means files are only retrievable - * via `GET /v4/inbound-email/{id}/files` (SDK / pull mode). + * Webhook URL for email notifications. If set, we POST each parsed email here. If omitted, + * files are only retrievable via `GET /v4/inbound-email/{id}/files`. */ fun callbackUrl(callbackUrl: String) = callbackUrl(JsonField.of(callbackUrl)) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt index e4b8285..7ef110a 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt @@ -287,8 +287,8 @@ private constructor( /** * URL expiration time in seconds. Defaults vary by source: * - Gmail Inbox Import: 86400 (24h) - * - Inbound Email (webhook mode): 172800 (48h) - * - Inbound Email (SDK mode): aligned with the session TTL (~30 min) + * - Inbound Email with `callback_url` set: 172800 (48h) + * - Inbound Email without `callback_url`: aligned with the session TTL (~30 min) * * @throws CasParserInvalidDataException if the JSON field has an unexpected type (e.g. if * the server responded with an unexpected value). @@ -483,8 +483,8 @@ private constructor( /** * URL expiration time in seconds. Defaults vary by source: * - Gmail Inbox Import: 86400 (24h) - * - Inbound Email (webhook mode): 172800 (48h) - * - Inbound Email (SDK mode): aligned with the session TTL (~30 min) + * - Inbound Email with `callback_url` set: 172800 (48h) + * - Inbound Email without `callback_url`: aligned with the session TTL (~30 min) */ fun expiresIn(expiresIn: Long) = expiresIn(JsonField.of(expiresIn)) From b8d38297967dd79a5a85175f316c0fc3469a0f3a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sat, 2 May 2026 23:18:11 +0000 Subject: [PATCH 06/11] codegen metadata --- .stats.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index d224bd8..582a92c 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 21 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-0dce3ce202e44ecf2270f6ca42942cc297bbeeafddb3128f8230ba3ae85c7551.yml -openapi_spec_hash: e9cef5743f686d9f12910c81832accca +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cas-parser/cas-parser-e572d88c2af6e4d7bc4f7e119357fd3f68b1e67d612fd1d3a657d916cde0087c.yml +openapi_spec_hash: a9fc7d947111bffa9184f8ca8be4a579 config_hash: 5509bb7a961ae2e79114b24c381606d4 From 1181b475ff522b2753786939e5b36e783ab78690 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 5 May 2026 03:54:07 +0000 Subject: [PATCH 07/11] docs: clarify forwards compat behavior --- README.md | 4 +- .../client/okhttp/CasParserOkHttpClient.kt | 3 + .../okhttp/CasParserOkHttpClientAsync.kt | 3 + .../com/cas_parser/api/core/ClientOptions.kt | 6 + .../com/cas_parser/api/core/RequestOptions.kt | 9 + .../accesstoken/AccessTokenCreateParams.kt | 9 + .../accesstoken/AccessTokenCreateResponse.kt | 8 + .../camskfintech/CamsKfintechParseParams.kt | 9 + .../api/models/camskfintech/LinkedHolder.kt | 8 + .../api/models/camskfintech/Transaction.kt | 26 ++ .../models/camskfintech/UnifiedResponse.kt | 361 ++++++++++++++++++ .../api/models/cdsl/CdslParsePdfParams.kt | 9 + .../cdsl/fetch/FetchRequestOtpParams.kt | 9 + .../cdsl/fetch/FetchRequestOtpResponse.kt | 8 + .../models/cdsl/fetch/FetchVerifyOtpParams.kt | 9 + .../cdsl/fetch/FetchVerifyOtpResponse.kt | 17 + .../contractnote/ContractNoteParseParams.kt | 18 + .../contractnote/ContractNoteParseResponse.kt | 97 +++++ .../api/models/credits/CreditCheckResponse.kt | 8 + .../inboundemail/InboundEmailCreateParams.kt | 27 ++ .../InboundEmailCreateResponse.kt | 35 ++ .../InboundEmailDeleteResponse.kt | 8 + .../inboundemail/InboundEmailListParams.kt | 9 + .../inboundemail/InboundEmailListResponse.kt | 47 +++ .../InboundEmailRetrieveResponse.kt | 35 ++ .../InboxCheckConnectionStatusResponse.kt | 8 + .../models/inbox/InboxConnectEmailParams.kt | 9 + .../models/inbox/InboxConnectEmailResponse.kt | 8 + .../inbox/InboxDisconnectEmailResponse.kt | 8 + .../models/inbox/InboxListCasFilesParams.kt | 18 + .../models/inbox/InboxListCasFilesResponse.kt | 27 ++ .../kfintech/KfintechGenerateCasParams.kt | 9 + .../kfintech/KfintechGenerateCasResponse.kt | 8 + .../api/models/logs/LogCreateParams.kt | 9 + .../api/models/logs/LogCreateResponse.kt | 17 + .../api/models/logs/LogGetSummaryParams.kt | 9 + .../api/models/logs/LogGetSummaryResponse.kt | 27 ++ .../api/models/nsdl/NsdlParseParams.kt | 9 + .../models/smart/SmartParseCasPdfParams.kt | 9 + .../verifytoken/VerifyTokenVerifyResponse.kt | 8 + 40 files changed, 964 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 7e9b378..6665e07 100644 --- a/README.md +++ b/README.md @@ -562,7 +562,9 @@ In rare cases, the API may return a response that doesn't match the expected typ By default, the SDK will not throw an exception in this case. It will throw [`CasParserInvalidDataException`](cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/CasParserInvalidDataException.kt) only if you directly access the property. -If you would prefer to check that the response is completely well-typed upfront, then either call `validate()`: +Validating the response is _not_ forwards compatible with new types from the API for existing fields. + +If you would still prefer to check that the response is completely well-typed upfront, then either call `validate()`: ```java import com.cas_parser.api.models.credits.CreditCheckResponse; diff --git a/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClient.kt b/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClient.kt index e6b85dd..982e175 100644 --- a/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClient.kt +++ b/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClient.kt @@ -217,6 +217,9 @@ class CasParserOkHttpClient private constructor() { /** * Whether to call `validate` on every response before returning it. * + * Setting this to `true` is _not_ forwards compatible with new types from the API for + * existing fields. + * * Defaults to false, which means the shape of the response will not be validated upfront. * Instead, validation will only occur for the parts of the response that are accessed. */ diff --git a/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClientAsync.kt b/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClientAsync.kt index 71b4321..b3ef3ef 100644 --- a/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClientAsync.kt +++ b/cas-parser-java-client-okhttp/src/main/kotlin/com/cas_parser/api/client/okhttp/CasParserOkHttpClientAsync.kt @@ -217,6 +217,9 @@ class CasParserOkHttpClientAsync private constructor() { /** * Whether to call `validate` on every response before returning it. * + * Setting this to `true` is _not_ forwards compatible with new types from the API for + * existing fields. + * * Defaults to false, which means the shape of the response will not be validated upfront. * Instead, validation will only occur for the parts of the response that are accessed. */ diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt index 4fb3496..2129ec2 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ClientOptions.kt @@ -66,6 +66,9 @@ private constructor( /** * Whether to call `validate` on every response before returning it. * + * Setting this to `true` is _not_ forwards compatible with new types from the API for existing + * fields. + * * Defaults to false, which means the shape of the response will not be validated upfront. * Instead, validation will only occur for the parts of the response that are accessed. */ @@ -230,6 +233,9 @@ private constructor( /** * Whether to call `validate` on every response before returning it. * + * Setting this to `true` is _not_ forwards compatible with new types from the API for + * existing fields. + * * Defaults to false, which means the shape of the response will not be validated upfront. * Instead, validation will only occur for the parts of the response that are accessed. */ diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/RequestOptions.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/RequestOptions.kt index 0232e87..b873e13 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/RequestOptions.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/RequestOptions.kt @@ -33,6 +33,15 @@ class RequestOptions private constructor(val responseValidation: Boolean?, val t private var responseValidation: Boolean? = null private var timeout: Timeout? = null + /** + * Whether to call `validate` on the response before returning it. + * + * Setting this to `true` is _not_ forwards compatible with new types from the API for + * existing fields. + * + * Defaults to false, which means the shape of the response will not be validated upfront. + * Instead, validation will only occur for the parts of the response that are accessed. + */ fun responseValidation(responseValidation: Boolean) = apply { this.responseValidation = responseValidation } diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateParams.kt index 93daf86..d8e5a20 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateParams.kt @@ -350,6 +350,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateResponse.kt index a23d37b..00a9e51 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/accesstoken/AccessTokenCreateResponse.kt @@ -186,6 +186,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): AccessTokenCreateResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/CamsKfintechParseParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/CamsKfintechParseParams.kt index 2b503a6..20c4db0 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/CamsKfintechParseParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/CamsKfintechParseParams.kt @@ -444,6 +444,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/LinkedHolder.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/LinkedHolder.kt index 9aa025d..4ccd215 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/LinkedHolder.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/LinkedHolder.kt @@ -142,6 +142,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): LinkedHolder = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/Transaction.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/Transaction.kt index 64c2700..94bec94 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/Transaction.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/Transaction.kt @@ -433,6 +433,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Transaction = apply { if (validated) { return@apply @@ -799,6 +807,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -1051,6 +1068,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Type = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/UnifiedResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/UnifiedResponse.kt index 6a27c6f..cceadd0 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/UnifiedResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/camskfintech/UnifiedResponse.kt @@ -342,6 +342,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): UnifiedResponse = apply { if (validated) { return@apply @@ -784,6 +792,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): DematAccount = apply { if (validated) { return@apply @@ -1200,6 +1217,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -1372,6 +1399,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): DematType = apply { if (validated) { return@apply @@ -1733,6 +1770,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): Holdings = apply { if (validated) { return@apply @@ -2076,6 +2123,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Aif = apply { if (validated) { return@apply @@ -2295,6 +2352,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected + * types recursively. + * + * This method is _not_ forwards compatible with new types from the API for + * existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object + * doesn't match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -2687,6 +2754,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): CorporateBond = apply { if (validated) { return@apply @@ -2906,6 +2983,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected + * types recursively. + * + * This method is _not_ forwards compatible with new types from the API for + * existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object + * doesn't match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -3298,6 +3385,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): DematMutualFund = apply { if (validated) { return@apply @@ -3517,6 +3614,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected + * types recursively. + * + * This method is _not_ forwards compatible with new types from the API for + * existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object + * doesn't match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -3907,6 +4014,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Equity = apply { if (validated) { return@apply @@ -4126,6 +4243,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected + * types recursively. + * + * This method is _not_ forwards compatible with new types from the API for + * existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object + * doesn't match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -4520,6 +4647,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): GovernmentSecurity = apply { if (validated) { return@apply @@ -4739,6 +4876,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected + * types recursively. + * + * This method is _not_ forwards compatible with new types from the API for + * existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object + * doesn't match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -5013,6 +5160,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Insurance = apply { if (validated) { return@apply @@ -5456,6 +5612,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): LifeInsurancePolicy = apply { if (validated) { return@apply @@ -5850,6 +6016,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Investor = apply { if (validated) { return@apply @@ -6090,6 +6265,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Meta = apply { if (validated) { return@apply @@ -6220,6 +6404,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): CasType = apply { if (validated) { return@apply @@ -6391,6 +6585,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): StatementPeriod = apply { if (validated) { return@apply @@ -6814,6 +7018,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): MutualFund = apply { if (validated) { return@apply @@ -7018,6 +7231,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -7552,6 +7775,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): Scheme = apply { if (validated) { return@apply @@ -7881,6 +8114,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -8092,6 +8335,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Gain = apply { if (validated) { return@apply @@ -8247,6 +8500,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Type = apply { if (validated) { return@apply @@ -8649,6 +8912,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Np = apply { if (validated) { return@apply @@ -8958,6 +9230,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): Fund = apply { if (validated) { return@apply @@ -9138,6 +9420,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): AdditionalInfo = apply { if (validated) { return@apply @@ -9258,6 +9550,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected + * types recursively. + * + * This method is _not_ forwards compatible with new types from the API for + * existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object + * doesn't match its expected type. + */ fun validate(): Tier = apply { if (validated) { return@apply @@ -9509,6 +9811,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Summary = apply { if (validated) { return@apply @@ -9741,6 +10052,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): Accounts = apply { if (validated) { return@apply @@ -9917,6 +10238,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Demat = apply { if (validated) { return@apply @@ -10110,6 +10441,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Insurance = apply { if (validated) { return@apply @@ -10303,6 +10644,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): MutualFunds = apply { if (validated) { return@apply @@ -10495,6 +10846,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): Nps = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/CdslParsePdfParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/CdslParsePdfParams.kt index e9440f6..81df339 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/CdslParsePdfParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/CdslParsePdfParams.kt @@ -443,6 +443,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpParams.kt index 34b641d..e1509fd 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpParams.kt @@ -492,6 +492,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpResponse.kt index cf0cf74..12de1bb 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchRequestOtpResponse.kt @@ -168,6 +168,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): FetchRequestOtpResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpParams.kt index 854f921..0a81238 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpParams.kt @@ -438,6 +438,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpResponse.kt index 2e72418..49d6bdf 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/cdsl/fetch/FetchVerifyOtpResponse.kt @@ -185,6 +185,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): FetchVerifyOtpResponse = apply { if (validated) { return@apply @@ -343,6 +351,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): File = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseParams.kt index 6c6ee9e..eee36e7 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseParams.kt @@ -539,6 +539,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply @@ -686,6 +695,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): BrokerType = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseResponse.kt index 370d8b0..9f81c80 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/contractnote/ContractNoteParseResponse.kt @@ -171,6 +171,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): ContractNoteParseResponse = apply { if (validated) { return@apply @@ -592,6 +600,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Data = apply { if (validated) { return@apply @@ -817,6 +834,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): BrokerInfo = apply { if (validated) { return@apply @@ -961,6 +988,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't + * match its expected type. + */ fun validate(): BrokerType = apply { if (validated) { return@apply @@ -1488,6 +1525,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): ChargesSummary = apply { if (validated) { return@apply @@ -1856,6 +1903,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): ClientInfo = apply { if (validated) { return@apply @@ -2167,6 +2224,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): ContractNoteInfo = apply { if (validated) { return@apply @@ -2586,6 +2653,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): DerivativesTransaction = apply { if (validated) { return@apply @@ -3232,6 +3309,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): DetailedTrade = apply { if (validated) { return@apply @@ -3792,6 +3879,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): EquityTransaction = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/credits/CreditCheckResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/credits/CreditCheckResponse.kt index 6a3f1a3..c5f263b 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/credits/CreditCheckResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/credits/CreditCheckResponse.kt @@ -317,6 +317,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): CreditCheckResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateParams.kt index 54b1e1c..d042ab7 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateParams.kt @@ -694,6 +694,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply @@ -865,6 +874,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): AllowedSource = apply { if (validated) { return@apply @@ -965,6 +983,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Metadata = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt index c3bf786..9ef158d 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailCreateResponse.kt @@ -435,6 +435,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboundEmailCreateResponse = apply { if (validated) { return@apply @@ -582,6 +590,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): AllowedSource = apply { if (validated) { return@apply @@ -679,6 +696,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Metadata = apply { if (validated) { return@apply @@ -810,6 +836,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Status = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponse.kt index 332967a..a5ed525 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailDeleteResponse.kt @@ -139,6 +139,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboundEmailDeleteResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt index aadb63b..8b77162 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListParams.kt @@ -322,6 +322,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Status = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt index 17b898d..e6f0048 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailListResponse.kt @@ -253,6 +253,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboundEmailListResponse = apply { if (validated) { return@apply @@ -715,6 +723,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboundEmail = apply { if (validated) { return@apply @@ -863,6 +880,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): AllowedSource = apply { if (validated) { return@apply @@ -963,6 +990,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): Metadata = apply { if (validated) { return@apply @@ -1096,6 +1133,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): Status = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt index 9b4c99a..3bbfbd9 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inboundemail/InboundEmailRetrieveResponse.kt @@ -435,6 +435,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboundEmailRetrieveResponse = apply { if (validated) { return@apply @@ -582,6 +590,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): AllowedSource = apply { if (validated) { return@apply @@ -679,6 +696,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Metadata = apply { if (validated) { return@apply @@ -810,6 +836,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Status = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxCheckConnectionStatusResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxCheckConnectionStatusResponse.kt index dad4ab0..585828e 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxCheckConnectionStatusResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxCheckConnectionStatusResponse.kt @@ -209,6 +209,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboxCheckConnectionStatusResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailParams.kt index dc2c277..12bb059 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailParams.kt @@ -440,6 +440,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailResponse.kt index 4511a59..968248e 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxConnectEmailResponse.kt @@ -177,6 +177,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboxConnectEmailResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxDisconnectEmailResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxDisconnectEmailResponse.kt index 0214edc..48cb354 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxDisconnectEmailResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxDisconnectEmailResponse.kt @@ -139,6 +139,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboxDisconnectEmailResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesParams.kt index b3c976d..aa23aae 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesParams.kt @@ -543,6 +543,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply @@ -697,6 +706,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): CasType = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt index 7ef110a..2240910 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/inbox/InboxListCasFilesResponse.kt @@ -192,6 +192,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): InboxListCasFilesResponse = apply { if (validated) { return@apply @@ -632,6 +640,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): File = apply { if (validated) { return@apply @@ -780,6 +797,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): CasType = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasParams.kt index 87b8b15..b8a20e9 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasParams.kt @@ -616,6 +616,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasResponse.kt index 40e0359..e1d5883 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/kfintech/KfintechGenerateCasResponse.kt @@ -139,6 +139,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): KfintechGenerateCasResponse = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateParams.kt index b5db085..fbd9946 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateParams.kt @@ -459,6 +459,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateResponse.kt index b77a776..e545f51 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogCreateResponse.kt @@ -185,6 +185,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): LogCreateResponse = apply { if (validated) { return@apply @@ -487,6 +495,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Log = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryParams.kt index 28648da..b645d12 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryParams.kt @@ -404,6 +404,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryResponse.kt index a78d1ba..892fb73 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/logs/LogGetSummaryResponse.kt @@ -140,6 +140,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): LogGetSummaryResponse = apply { if (validated) { return@apply @@ -366,6 +374,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Summary = apply { if (validated) { return@apply @@ -568,6 +585,16 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing + * fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match + * its expected type. + */ fun validate(): ByFeature = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/nsdl/NsdlParseParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/nsdl/NsdlParseParams.kt index 240f71c..96eb267 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/nsdl/NsdlParseParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/nsdl/NsdlParseParams.kt @@ -439,6 +439,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/smart/SmartParseCasPdfParams.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/smart/SmartParseCasPdfParams.kt index cbfbeb1..730a047 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/smart/SmartParseCasPdfParams.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/smart/SmartParseCasPdfParams.kt @@ -444,6 +444,15 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types + * recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): Body = apply { if (validated) { return@apply diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/verifytoken/VerifyTokenVerifyResponse.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/verifytoken/VerifyTokenVerifyResponse.kt index b8859a0..f34e4bd 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/verifytoken/VerifyTokenVerifyResponse.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/models/verifytoken/VerifyTokenVerifyResponse.kt @@ -187,6 +187,14 @@ private constructor( private var validated: Boolean = false + /** + * Validates that the types of all values in this object match their expected types recursively. + * + * This method is _not_ forwards compatible with new types from the API for existing fields. + * + * @throws CasParserInvalidDataException if any value type in this object doesn't match its + * expected type. + */ fun validate(): VerifyTokenVerifyResponse = apply { if (validated) { return@apply From 98e6ec79767f1c16a0cfff5262ae29dad9600873 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 5 May 2026 03:56:05 +0000 Subject: [PATCH 08/11] feat(client): more robust error parsing --- .../com/cas_parser/api/errors/BadRequestException.kt | 6 +++++- .../com/cas_parser/api/errors/InternalServerException.kt | 7 ++++++- .../kotlin/com/cas_parser/api/errors/NotFoundException.kt | 6 +++++- .../com/cas_parser/api/errors/PermissionDeniedException.kt | 6 +++++- .../kotlin/com/cas_parser/api/errors/RateLimitException.kt | 6 +++++- .../com/cas_parser/api/errors/UnauthorizedException.kt | 6 +++++- .../cas_parser/api/errors/UnexpectedStatusCodeException.kt | 7 ++++++- .../cas_parser/api/errors/UnprocessableEntityException.kt | 6 +++++- 8 files changed, 42 insertions(+), 8 deletions(-) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/BadRequestException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/BadRequestException.kt index a0737dc..074ca61 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/BadRequestException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/BadRequestException.kt @@ -5,12 +5,16 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull class BadRequestException private constructor(private val headers: Headers, private val body: JsonValue, cause: Throwable?) : - CasParserServiceException("400: $body", cause) { + CasParserServiceException( + "400: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = 400 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/InternalServerException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/InternalServerException.kt index ec2af8e..75987e6 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/InternalServerException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/InternalServerException.kt @@ -5,6 +5,7 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull @@ -14,7 +15,11 @@ private constructor( private val headers: Headers, private val body: JsonValue, cause: Throwable?, -) : CasParserServiceException("$statusCode: $body", cause) { +) : + CasParserServiceException( + "$statusCode: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = statusCode diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/NotFoundException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/NotFoundException.kt index c01b9dd..6856cd6 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/NotFoundException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/NotFoundException.kt @@ -5,12 +5,16 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull class NotFoundException private constructor(private val headers: Headers, private val body: JsonValue, cause: Throwable?) : - CasParserServiceException("404: $body", cause) { + CasParserServiceException( + "404: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = 404 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/PermissionDeniedException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/PermissionDeniedException.kt index 520a46f..bb97c2e 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/PermissionDeniedException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/PermissionDeniedException.kt @@ -5,12 +5,16 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull class PermissionDeniedException private constructor(private val headers: Headers, private val body: JsonValue, cause: Throwable?) : - CasParserServiceException("403: $body", cause) { + CasParserServiceException( + "403: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = 403 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/RateLimitException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/RateLimitException.kt index 10c79f3..c14384b 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/RateLimitException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/RateLimitException.kt @@ -5,12 +5,16 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull class RateLimitException private constructor(private val headers: Headers, private val body: JsonValue, cause: Throwable?) : - CasParserServiceException("429: $body", cause) { + CasParserServiceException( + "429: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = 429 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnauthorizedException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnauthorizedException.kt index 290a3e7..3d9e25a 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnauthorizedException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnauthorizedException.kt @@ -5,12 +5,16 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull class UnauthorizedException private constructor(private val headers: Headers, private val body: JsonValue, cause: Throwable?) : - CasParserServiceException("401: $body", cause) { + CasParserServiceException( + "401: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = 401 diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnexpectedStatusCodeException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnexpectedStatusCodeException.kt index 55a37fe..2ea9523 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnexpectedStatusCodeException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnexpectedStatusCodeException.kt @@ -5,6 +5,7 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull @@ -14,7 +15,11 @@ private constructor( private val headers: Headers, private val body: JsonValue, cause: Throwable?, -) : CasParserServiceException("$statusCode: $body", cause) { +) : + CasParserServiceException( + "$statusCode: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = statusCode diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnprocessableEntityException.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnprocessableEntityException.kt index 678980c..a6a9f9a 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnprocessableEntityException.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/errors/UnprocessableEntityException.kt @@ -5,12 +5,16 @@ package com.cas_parser.api.errors import com.cas_parser.api.core.JsonValue import com.cas_parser.api.core.checkRequired import com.cas_parser.api.core.http.Headers +import com.cas_parser.api.core.jsonMapper import java.util.Optional import kotlin.jvm.optionals.getOrNull class UnprocessableEntityException private constructor(private val headers: Headers, private val body: JsonValue, cause: Throwable?) : - CasParserServiceException("422: $body", cause) { + CasParserServiceException( + "422: ${if (body.isMissing()) "Unknown" else jsonMapper().writeValueAsString(body)}", + cause, + ) { override fun statusCode(): Int = 422 From 226519252d2ec845c0ca05a13902c3574e0d33e2 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 5 May 2026 04:00:17 +0000 Subject: [PATCH 09/11] chore: remove duplicated dokka setup --- build.gradle.kts | 1 - 1 file changed, 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 8f7d82f..794ef23 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -22,7 +22,6 @@ subprojects { group = "Verification" description = "Verifies all source files are formatted." } - apply(plugin = "org.jetbrains.dokka") } subprojects { From 720bb86a8c014e99d8e3a3adbd14b5b9ee4d337a Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 5 May 2026 04:02:46 +0000 Subject: [PATCH 10/11] perf(client): create one json mapper --- .../src/main/kotlin/com/cas_parser/api/core/ObjectMappers.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ObjectMappers.kt b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ObjectMappers.kt index e067f70..0c4aadd 100644 --- a/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ObjectMappers.kt +++ b/cas-parser-java-core/src/main/kotlin/com/cas_parser/api/core/ObjectMappers.kt @@ -29,7 +29,9 @@ import java.time.ZoneId import java.time.format.DateTimeFormatter import java.time.temporal.ChronoField -fun jsonMapper(): JsonMapper = +fun jsonMapper(): JsonMapper = JSON_MAPPER + +private val JSON_MAPPER: JsonMapper = JsonMapper.builder() .addModule(kotlinModule()) .addModule(Jdk8Module()) From 21f5403c5c2889188bf28c2508bdfdfcb84a5f5e Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 5 May 2026 04:03:09 +0000 Subject: [PATCH 11/11] release: 0.7.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 26 ++++++++++++++++++++++++++ README.md | 10 +++++----- build.gradle.kts | 2 +- 4 files changed, 33 insertions(+), 7 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 4208b5c..1b77f50 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.6.0" + ".": "0.7.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 62fd0e2..cc12231 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,31 @@ # Changelog +## 0.7.0 (2026-05-05) + +Full Changelog: [v0.6.0...v0.7.0](https://github.com/CASParser/cas-parser-java/compare/v0.6.0...v0.7.0) + +### Features + +* **api:** api update ([298bc41](https://github.com/CASParser/cas-parser-java/commit/298bc41836f9daa2d97dd46cb1cff7a2f8116117)) +* **api:** api update ([2744bf4](https://github.com/CASParser/cas-parser-java/commit/2744bf455786d58b2ccb12e2a7e8f125586b71b1)) +* **client:** more robust error parsing ([98e6ec7](https://github.com/CASParser/cas-parser-java/commit/98e6ec79767f1c16a0cfff5262ae29dad9600873)) +* support setting headers via env ([ee0b90d](https://github.com/CASParser/cas-parser-java/commit/ee0b90db7cf144c61c23891ff8d026b0b6c358da)) + + +### Performance Improvements + +* **client:** create one json mapper ([720bb86](https://github.com/CASParser/cas-parser-java/commit/720bb86a8c014e99d8e3a3adbd14b5b9ee4d337a)) + + +### Chores + +* remove duplicated dokka setup ([2265192](https://github.com/CASParser/cas-parser-java/commit/226519252d2ec845c0ca05a13902c3574e0d33e2)) + + +### Documentation + +* clarify forwards compat behavior ([1181b47](https://github.com/CASParser/cas-parser-java/commit/1181b475ff522b2753786939e5b36e783ab78690)) + ## 0.6.0 (2026-04-19) Full Changelog: [v0.5.4...v0.6.0](https://github.com/CASParser/cas-parser-java/compare/v0.5.4...v0.6.0) diff --git a/README.md b/README.md index 6665e07..5598b41 100644 --- a/README.md +++ b/README.md @@ -2,8 +2,8 @@ -[![Maven Central](https://img.shields.io/maven-central/v/com.cas_parser.api/cas-parser-java)](https://central.sonatype.com/artifact/com.cas_parser.api/cas-parser-java/0.6.0) -[![javadoc](https://javadoc.io/badge2/com.cas_parser.api/cas-parser-java/0.6.0/javadoc.svg)](https://javadoc.io/doc/com.cas_parser.api/cas-parser-java/0.6.0) +[![Maven Central](https://img.shields.io/maven-central/v/com.cas_parser.api/cas-parser-java)](https://central.sonatype.com/artifact/com.cas_parser.api/cas-parser-java/0.7.0) +[![javadoc](https://javadoc.io/badge2/com.cas_parser.api/cas-parser-java/0.7.0/javadoc.svg)](https://javadoc.io/doc/com.cas_parser.api/cas-parser-java/0.7.0) @@ -22,7 +22,7 @@ Use the Cas Parser MCP Server to enable AI assistants to interact with this API, -The REST API documentation can be found on [casparser.in](https://casparser.in/docs). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.cas_parser.api/cas-parser-java/0.6.0). +The REST API documentation can be found on [casparser.in](https://casparser.in/docs). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.cas_parser.api/cas-parser-java/0.7.0). @@ -33,7 +33,7 @@ The REST API documentation can be found on [casparser.in](https://casparser.in/d ### Gradle ```kotlin -implementation("com.cas_parser.api:cas-parser-java:0.6.0") +implementation("com.cas_parser.api:cas-parser-java:0.7.0") ``` ### Maven @@ -42,7 +42,7 @@ implementation("com.cas_parser.api:cas-parser-java:0.6.0") com.cas_parser.api cas-parser-java - 0.6.0 + 0.7.0 ``` diff --git a/build.gradle.kts b/build.gradle.kts index 794ef23..d0f1e15 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -9,7 +9,7 @@ repositories { allprojects { group = "com.cas_parser.api" - version = "0.6.0" // x-release-please-version + version = "0.7.0" // x-release-please-version } subprojects {