From f792101f7ad2cdd4ec4ed626270d5e553d90a430 Mon Sep 17 00:00:00 2001 From: cloudpdf-sdk-bot Date: Sun, 23 Aug 2026 21:40:03 +0000 Subject: [PATCH] chore: generate CloudPDF Java SDK 3.0.0-alpha.7 --- .fern/metadata.json | 4 +- build.gradle | 4 +- cloudpdf-generation.json | 8 +-- reference.md | 12 ++-- src/main/java/api/core/ClientOptions.java | 2 +- .../requests/DocumentsImportFromRequest.java | 62 +++++++++++++++++++ .../requests/DocumentsInitRequest.java | 13 ++++ .../DocumentsImportFromRequestExpected.java | 12 ++++ ...entsImportFromRequestSourceConnection.java | 33 ++++++++++ .../DocumentsImportFromRequestSourceUrl.java | 10 +++ 10 files changed, 145 insertions(+), 15 deletions(-) diff --git a/.fern/metadata.json b/.fern/metadata.json index fe05088..db8011b 100644 --- a/.fern/metadata.json +++ b/.fern/metadata.json @@ -10,9 +10,9 @@ "base-exception-class-name": "CloudPDFException", "base-api-exception-class-name": "CloudPDFApiException" }, - "originGitCommit": "32635f40577b214f6a6b3189a2271425c3a574fd", + "originGitCommit": "1345fb7a45ee660a352774d29decce25cb54b8ea", "originGitCommitIsDirty": false, "invokedBy": "ci", - "requestedVersion": "3.0.0-alpha.6", + "requestedVersion": "3.0.0-alpha.7", "ciProvider": "github" } \ No newline at end of file diff --git a/build.gradle b/build.gradle index 9f4d9c5..918fdb9 100644 --- a/build.gradle +++ b/build.gradle @@ -46,7 +46,7 @@ java { group = 'com.cloudpdf' -version = '3.0.0-alpha.6' +version = '3.0.0-alpha.7' jar { dependsOn(":generatePomFileForMavenPublication") @@ -73,7 +73,7 @@ publishing { maven(MavenPublication) { groupId = 'com.cloudpdf' artifactId = 'sdk' - version = '3.0.0-alpha.6' + version = '3.0.0-alpha.7' from components.java pom { name = 'CloudPDF' diff --git a/cloudpdf-generation.json b/cloudpdf-generation.json index 9ce216f..fd3152d 100644 --- a/cloudpdf-generation.json +++ b/cloudpdf-generation.json @@ -1,12 +1,12 @@ { "language": "java", - "canonicalVersion": "3.0.0-next.6", - "sdkVersion": "3.0.0-alpha.6", + "canonicalVersion": "3.0.0-next.7", + "sdkVersion": "3.0.0-alpha.7", "source": { "repository": "embedpdf/embed-pdf-viewer", "openapi": "cloudpdf/contract/openapi.json", - "openapiSha256": "b3e236a932673e27e05825352e1bc3675369d7505040bf7d7760e542aae8d38d", - "gitCommit": "32635f40577b214f6a6b3189a2271425c3a574fd", + "openapiSha256": "f6fc610bfd193f278a7e8ec063d9e96b8fef86bdec7ade5e7bc4b19879673147", + "gitCommit": "1345fb7a45ee660a352774d29decce25cb54b8ea", "gitCommitIsDirty": false }, "fern": { diff --git a/reference.md b/reference.md index 4026764..028f79c 100644 --- a/reference.md +++ b/reference.md @@ -1695,7 +1695,7 @@ client.documents().importFrom(
-**source:** `DocumentsImportFromRequestSource` +**source:** `DocumentsImportFromRequestSource` — Where CloudPDF pulls the bytes from. The two shapes differ in WHO supplies the authority to read, not in which storage vendor holds the file.
@@ -1703,7 +1703,7 @@ client.documents().importFrom(
-**expected:** `Optional` +**expected:** `Optional` — Integrity pins, enforced when present. When absent, the server-observed values become authoritative.
@@ -1719,7 +1719,7 @@ client.documents().importFrom(
-**idempotencyKey:** `Optional` +**idempotencyKey:** `Optional` — Retrying with the same key resumes the same document rather than importing a second copy — including after a 502.
@@ -1727,7 +1727,7 @@ client.documents().importFrom(
-**dedupMode:** `Optional` +**dedupMode:** `Optional` — always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.
@@ -1743,7 +1743,7 @@ client.documents().importFrom(
-**mode:** `Optional` +**mode:** `Optional` — sync (default) holds the response open for the whole transfer. async answers 202 with the document pending and transfers in the background; it requires a connection source, and filesystem connections additionally require expected.sha256.
@@ -1830,7 +1830,7 @@ client.documents().init(
-**dedupMode:** `Optional` +**dedupMode:** `Optional` — always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.
diff --git a/src/main/java/api/core/ClientOptions.java b/src/main/java/api/core/ClientOptions.java index 271062f..336704a 100644 --- a/src/main/java/api/core/ClientOptions.java +++ b/src/main/java/api/core/ClientOptions.java @@ -49,7 +49,7 @@ private ClientOptions( { put("X-Fern-Language", "JAVA"); put("X-Fern-SDK-Name", "com.cloudpdf:sdk"); - put("X-Fern-SDK-Version", "3.0.0-alpha.6"); + put("X-Fern-SDK-Version", "3.0.0-alpha.7"); } }); this.headerSuppliers = headerSuppliers; diff --git a/src/main/java/api/resources/documents/requests/DocumentsImportFromRequest.java b/src/main/java/api/resources/documents/requests/DocumentsImportFromRequest.java index a190cdf..521ad7b 100644 --- a/src/main/java/api/resources/documents/requests/DocumentsImportFromRequest.java +++ b/src/main/java/api/resources/documents/requests/DocumentsImportFromRequest.java @@ -60,11 +60,17 @@ private DocumentsImportFromRequest( this.additionalProperties = additionalProperties; } + /** + * @return Where CloudPDF pulls the bytes from. The two shapes differ in WHO supplies the authority to read, not in which storage vendor holds the file. + */ @JsonProperty("source") public DocumentsImportFromRequestSource getSource() { return source; } + /** + * @return Integrity pins, enforced when present. When absent, the server-observed values become authoritative. + */ @JsonProperty("expected") public Optional getExpected() { return expected; @@ -75,11 +81,17 @@ public Optional> getMetadata() { return metadata; } + /** + * @return Retrying with the same key resumes the same document rather than importing a second copy — including after a 502. + */ @JsonProperty("idempotencyKey") public Optional getIdempotencyKey() { return idempotencyKey; } + /** + * @return always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice. + */ @JsonProperty("dedupMode") public Optional getDedupMode() { return dedupMode; @@ -90,6 +102,9 @@ public Optional getDocId() { return docId; } + /** + * @return sync (default) holds the response open for the whole transfer. async answers 202 with the document pending and transfers in the background; it requires a connection source, and filesystem connections additionally require expected.sha256. + */ @JsonProperty("mode") public Optional getMode() { return mode; @@ -132,6 +147,9 @@ public static SourceStage builder() { } public interface SourceStage { + /** + *

Where CloudPDF pulls the bytes from. The two shapes differ in WHO supplies the authority to read, not in which storage vendor holds the file.

+ */ _FinalStage source(@NotNull DocumentsImportFromRequestSource source); Builder from(DocumentsImportFromRequest other); @@ -144,6 +162,9 @@ public interface _FinalStage { _FinalStage additionalProperties(Map additionalProperties); + /** + *

Integrity pins, enforced when present. When absent, the server-observed values become authoritative.

+ */ _FinalStage expected(Optional expected); _FinalStage expected(DocumentsImportFromRequestExpected expected); @@ -152,10 +173,16 @@ public interface _FinalStage { _FinalStage metadata(Map metadata); + /** + *

Retrying with the same key resumes the same document rather than importing a second copy — including after a 502.

+ */ _FinalStage idempotencyKey(Optional idempotencyKey); _FinalStage idempotencyKey(String idempotencyKey); + /** + *

always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

+ */ _FinalStage dedupMode(Optional dedupMode); _FinalStage dedupMode(DocumentsImportFromRequestDedupMode dedupMode); @@ -164,6 +191,9 @@ public interface _FinalStage { _FinalStage docId(String docId); + /** + *

sync (default) holds the response open for the whole transfer. async answers 202 with the document pending and transfers in the background; it requires a connection source, and filesystem connections additionally require expected.sha256.

+ */ _FinalStage mode(Optional mode); _FinalStage mode(DocumentsImportFromRequestMode mode); @@ -202,6 +232,10 @@ public Builder from(DocumentsImportFromRequest other) { return this; } + /** + *

Where CloudPDF pulls the bytes from. The two shapes differ in WHO supplies the authority to read, not in which storage vendor holds the file.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override @JsonSetter("source") public _FinalStage source(@NotNull DocumentsImportFromRequestSource source) { @@ -209,12 +243,19 @@ public _FinalStage source(@NotNull DocumentsImportFromRequestSource source) { return this; } + /** + *

sync (default) holds the response open for the whole transfer. async answers 202 with the document pending and transfers in the background; it requires a connection source, and filesystem connections additionally require expected.sha256.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override public _FinalStage mode(DocumentsImportFromRequestMode mode) { this.mode = Optional.ofNullable(mode); return this; } + /** + *

sync (default) holds the response open for the whole transfer. async answers 202 with the document pending and transfers in the background; it requires a connection source, and filesystem connections additionally require expected.sha256.

+ */ @java.lang.Override @JsonSetter(value = "mode", nulls = Nulls.SKIP) public _FinalStage mode(Optional mode) { @@ -235,12 +276,19 @@ public _FinalStage docId(Optional docId) { return this; } + /** + *

always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override public _FinalStage dedupMode(DocumentsImportFromRequestDedupMode dedupMode) { this.dedupMode = Optional.ofNullable(dedupMode); return this; } + /** + *

always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

+ */ @java.lang.Override @JsonSetter(value = "dedupMode", nulls = Nulls.SKIP) public _FinalStage dedupMode(Optional dedupMode) { @@ -248,12 +296,19 @@ public _FinalStage dedupMode(Optional dedup return this; } + /** + *

Retrying with the same key resumes the same document rather than importing a second copy — including after a 502.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override public _FinalStage idempotencyKey(String idempotencyKey) { this.idempotencyKey = Optional.ofNullable(idempotencyKey); return this; } + /** + *

Retrying with the same key resumes the same document rather than importing a second copy — including after a 502.

+ */ @java.lang.Override @JsonSetter(value = "idempotencyKey", nulls = Nulls.SKIP) public _FinalStage idempotencyKey(Optional idempotencyKey) { @@ -274,12 +329,19 @@ public _FinalStage metadata(Optional> metadata) { return this; } + /** + *

Integrity pins, enforced when present. When absent, the server-observed values become authoritative.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override public _FinalStage expected(DocumentsImportFromRequestExpected expected) { this.expected = Optional.ofNullable(expected); return this; } + /** + *

Integrity pins, enforced when present. When absent, the server-observed values become authoritative.

+ */ @java.lang.Override @JsonSetter(value = "expected", nulls = Nulls.SKIP) public _FinalStage expected(Optional expected) { diff --git a/src/main/java/api/resources/documents/requests/DocumentsInitRequest.java b/src/main/java/api/resources/documents/requests/DocumentsInitRequest.java index 260b3ce..2b6e23b 100644 --- a/src/main/java/api/resources/documents/requests/DocumentsInitRequest.java +++ b/src/main/java/api/resources/documents/requests/DocumentsInitRequest.java @@ -82,6 +82,9 @@ public Optional getIdempotencyKey() { return idempotencyKey; } + /** + * @return always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice. + */ @JsonProperty("dedupMode") public Optional getDedupMode() { return dedupMode; @@ -171,6 +174,9 @@ public interface _FinalStage { _FinalStage idempotencyKey(String idempotencyKey); + /** + *

always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

+ */ _FinalStage dedupMode(Optional dedupMode); _FinalStage dedupMode(DocumentsInitRequestDedupMode dedupMode); @@ -277,12 +283,19 @@ public _FinalStage docId(Optional docId) { return this; } + /** + *

always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override public _FinalStage dedupMode(DocumentsInitRequestDedupMode dedupMode) { this.dedupMode = Optional.ofNullable(dedupMode); return this; } + /** + *

always-create (default) creates a new document every time. reuse-existing returns a document that already holds the same content instead of storing it twice.

+ */ @java.lang.Override @JsonSetter(value = "dedupMode", nulls = Nulls.SKIP) public _FinalStage dedupMode(Optional dedupMode) { diff --git a/src/main/java/api/resources/documents/types/DocumentsImportFromRequestExpected.java b/src/main/java/api/resources/documents/types/DocumentsImportFromRequestExpected.java index 510bafc..32fe788 100644 --- a/src/main/java/api/resources/documents/types/DocumentsImportFromRequestExpected.java +++ b/src/main/java/api/resources/documents/types/DocumentsImportFromRequestExpected.java @@ -33,11 +33,17 @@ private DocumentsImportFromRequestExpected( this.additionalProperties = additionalProperties; } + /** + * @return Checked against the source's declared Content-Length before the transfer. + */ @JsonProperty("sizeBytes") public Optional getSizeBytes() { return sizeBytes; } + /** + * @return Checked against the server-observed digest after the transfer. Required when dedupMode is reuse-existing. + */ @JsonProperty("sha256") public Optional getSha256() { return sha256; @@ -90,6 +96,9 @@ public Builder from(DocumentsImportFromRequestExpected other) { return this; } + /** + *

Checked against the source's declared Content-Length before the transfer.

+ */ @JsonSetter(value = "sizeBytes", nulls = Nulls.SKIP) public Builder sizeBytes(Optional sizeBytes) { this.sizeBytes = sizeBytes; @@ -101,6 +110,9 @@ public Builder sizeBytes(Integer sizeBytes) { return this; } + /** + *

Checked against the server-observed digest after the transfer. Required when dedupMode is reuse-existing.

+ */ @JsonSetter(value = "sha256", nulls = Nulls.SKIP) public Builder sha256(Optional sha256) { this.sha256 = sha256; diff --git a/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceConnection.java b/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceConnection.java index 5b3432e..8151a49 100644 --- a/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceConnection.java +++ b/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceConnection.java @@ -37,16 +37,25 @@ private DocumentsImportFromRequestSourceConnection( this.additionalProperties = additionalProperties; } + /** + * @return The operator-registered storage connection to read from. + */ @JsonProperty("connectionId") public String getConnectionId() { return connectionId; } + /** + * @return The object key to read, inside the connection's configured scope. At most 1024 UTF-8 bytes. + */ @JsonProperty("key") public String getKey() { return key; } + /** + * @return Pins a specific version of the object. Provider-interpreted (S3 VersionId, GCS generation, Azure version id); providers without versioning reject it. + */ @JsonProperty("revision") public Optional getRevision() { return revision; @@ -83,12 +92,18 @@ public static ConnectionIdStage builder() { } public interface ConnectionIdStage { + /** + *

The operator-registered storage connection to read from.

+ */ KeyStage connectionId(@NotNull String connectionId); Builder from(DocumentsImportFromRequestSourceConnection other); } public interface KeyStage { + /** + *

The object key to read, inside the connection's configured scope. At most 1024 UTF-8 bytes.

+ */ _FinalStage key(@NotNull String key); } @@ -99,6 +114,9 @@ public interface _FinalStage { _FinalStage additionalProperties(Map additionalProperties); + /** + *

Pins a specific version of the object. Provider-interpreted (S3 VersionId, GCS generation, Azure version id); providers without versioning reject it.

+ */ _FinalStage revision(Optional revision); _FinalStage revision(String revision); @@ -125,6 +143,10 @@ public Builder from(DocumentsImportFromRequestSourceConnection other) { return this; } + /** + *

The operator-registered storage connection to read from.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override @JsonSetter("connectionId") public KeyStage connectionId(@NotNull String connectionId) { @@ -132,6 +154,10 @@ public KeyStage connectionId(@NotNull String connectionId) { return this; } + /** + *

The object key to read, inside the connection's configured scope. At most 1024 UTF-8 bytes.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override @JsonSetter("key") public _FinalStage key(@NotNull String key) { @@ -139,12 +165,19 @@ public _FinalStage key(@NotNull String key) { return this; } + /** + *

Pins a specific version of the object. Provider-interpreted (S3 VersionId, GCS generation, Azure version id); providers without versioning reject it.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override public _FinalStage revision(String revision) { this.revision = Optional.ofNullable(revision); return this; } + /** + *

Pins a specific version of the object. Provider-interpreted (S3 VersionId, GCS generation, Azure version id); providers without versioning reject it.

+ */ @java.lang.Override @JsonSetter(value = "revision", nulls = Nulls.SKIP) public _FinalStage revision(Optional revision) { diff --git a/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceUrl.java b/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceUrl.java index ee06df2..4dd556a 100644 --- a/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceUrl.java +++ b/src/main/java/api/resources/documents/types/DocumentsImportFromRequestSourceUrl.java @@ -28,6 +28,9 @@ private DocumentsImportFromRequestSourceUrl(String url, Map addi this.additionalProperties = additionalProperties; } + /** + * @return The URL to fetch. Must be allowed by the deployment import policy (scheme, network range, size) and must declare a length. + */ @JsonProperty("url") public String getUrl() { return url; @@ -64,6 +67,9 @@ public static UrlStage builder() { } public interface UrlStage { + /** + *

The URL to fetch. Must be allowed by the deployment import policy (scheme, network range, size) and must declare a length.

+ */ _FinalStage url(@NotNull String url); Builder from(DocumentsImportFromRequestSourceUrl other); @@ -92,6 +98,10 @@ public Builder from(DocumentsImportFromRequestSourceUrl other) { return this; } + /** + *

The URL to fetch. Must be allowed by the deployment import policy (scheme, network range, size) and must declare a length.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ @java.lang.Override @JsonSetter("url") public _FinalStage url(@NotNull String url) {