Skip to content

Commit c17636d

Browse files
committed
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.468.9
1 parent 8f1a11d commit c17636d

File tree

16 files changed

+293
-60
lines changed

16 files changed

+293
-60
lines changed

.speakeasy/gen.lock

Lines changed: 63 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
lockVersion: 2.0.0
22
id: 66f99777-b2f2-4e45-9581-501d199e5c0c
33
management:
4-
docChecksum: 53c59e9888ffa48d7fef9b0017efc602
4+
docChecksum: 37a13cf25882217bb6883efc4407294c
55
docVersion: 0.4.0
6-
speakeasyVersion: 1.468.6
7-
generationVersion: 2.493.13
8-
releaseVersion: 7.23.3
9-
configChecksum: 45a4c11a1f20830d4335c2eda694383f
6+
speakeasyVersion: 1.468.9
7+
generationVersion: 2.493.21
8+
releaseVersion: 7.23.4
9+
configChecksum: b3d006d07d722b89a2a5bb3377a19d5f
1010
repoURL: https://github.com/speakeasy-api/speakeasy-client-sdk-java.git
1111
repoSubDirectory: .
1212
published: true
1313
features:
1414
java:
1515
acceptHeaders: 2.81.2
1616
additionalDependencies: 0.1.0
17-
core: 3.33.4
17+
core: 3.33.5
1818
deprecations: 2.81.1
1919
downloadStreams: 0.1.1
2020
globalSecurity: 2.82.7
@@ -1632,6 +1632,8 @@ examples:
16321632
"200":
16331633
application/json: "x-file: example.file"
16341634
application/x-yaml: "x-file: example.file"
1635+
5XX:
1636+
application/json: {"message": "<value>", "status_code": 569513}
16351637
generateCodeSamplePreviewAsync:
16361638
speakeasy-default-generate-code-sample-preview-async:
16371639
requestBody:
@@ -1641,6 +1643,8 @@ examples:
16411643
application/json: {"job_id": "<id>", "status": "pending"}
16421644
4XX:
16431645
application/json: {"message": "<value>", "status_code": 394086}
1646+
5XX:
1647+
application/json: {"message": "<value>", "status_code": 933708}
16441648
getCodeSamplePreviewAsync:
16451649
speakeasy-default-get-code-sample-preview-async:
16461650
parameters:
@@ -1654,6 +1658,8 @@ examples:
16541658
"200":
16551659
application/json: "x-file: example.file"
16561660
application/x-yaml: "x-file: example.file"
1661+
5XX:
1662+
application/json: {"message": "<value>", "status_code": 91014}
16571663
getGithubSetupState:
16581664
speakeasy-default-get-github-setup-state:
16591665
parameters:
@@ -1702,6 +1708,57 @@ examples:
17021708
application/json: {"snippets": [{"code": "<value>", "language": "<value>", "operationId": "<id>"}, {"code": "<value>", "language": "<value>", "operationId": "<id>"}, {"code": "<value>", "language": "<value>", "operationId": "<id>"}]}
17031709
4XX:
17041710
application/json: {"message": "<value>", "status_code": 458049}
1711+
"":
1712+
parameters:
1713+
query:
1714+
registry_url: "https://spec.speakeasy.com/my-org/my-workspace/my-source"
1715+
operation_ids: ["getPetById"]
1716+
responses:
1717+
2XX:
1718+
application/json: {"snippets": [{"code": "<value>", "language": "<value>", "operationId": "<id>"}, {"code": "<value>", "language": "<value>", "operationId": "<id>"}]}
1719+
4XX:
1720+
application/json: {"message": "<value>", "status_code": 558834}
1721+
python:
1722+
parameters:
1723+
query:
1724+
registry_url: "https://spec.speakeasy.com/my-org/my-workspace/my-source"
1725+
operation_ids: ["getPetById"]
1726+
languages: ["python"]
1727+
responses:
1728+
2XX:
1729+
application/json: {"snippets": [{"code": "<value>", "language": "<value>", "operationId": "<id>"}, {"code": "<value>", "language": "<value>", "operationId": "<id>"}]}
1730+
4XX:
1731+
application/json: {"message": "<value>", "status_code": 521235}
1732+
typescript:
1733+
parameters:
1734+
query:
1735+
registry_url: "https://spec.speakeasy.com/my-org/my-workspace/my-source"
1736+
operation_ids: ["getPetById"]
1737+
languages: ["typescript"]
1738+
responses:
1739+
2XX:
1740+
application/json: {"snippets": [{"code": "<value>", "language": "<value>", "operationId": "<id>"}, {"code": "<value>", "language": "<value>", "operationId": "<id>"}, {"code": "<value>", "language": "<value>", "operationId": "<id>"}]}
1741+
4XX:
1742+
application/json: {"message": "<value>", "status_code": 458049}
1743+
java:
1744+
parameters:
1745+
query:
1746+
registry_url: "https://spec.speakeasy.com/my-org/my-workspace/my-source"
1747+
operation_ids: ["getPetById"]
1748+
languages: ["java"]
1749+
responses:
1750+
2XX:
1751+
application/json: {"snippets": [{"code": "<value>", "language": "<value>", "operationId": "<id>"}]}
1752+
4XX:
1753+
application/json: {"message": "<value>", "status_code": 262795}
1754+
default:
1755+
parameters:
1756+
query:
1757+
registry_url: "https://spec.speakeasy.com/my-org/my-workspace/my-source"
1758+
operation_ids: ["getPetById"]
1759+
responses:
1760+
2XX:
1761+
application/json: {"snippets": [{"code": "import { Petstore } from \"petstore-sdk\";\n\nconst petstore = new Petstore({\n apiKey: \"<YOUR_API_KEY_HERE>\",\n});\n\nasync function run() {\n const result = await petstore.pet.getById({\n id: 137396,\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();", "language": "typescript", "operationId": "getPetById"}]}
17051762
setWorkspaceFeatureFlags:
17061763
speakeasy-default-set-workspace-feature-flags:
17071764
requestBody:

.speakeasy/workflow.lock

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
1-
speakeasyVersion: 1.468.6
1+
speakeasyVersion: 1.468.9
22
sources:
33
first-source: {}
44
my-source:
55
sourceNamespace: my-source-new
6-
sourceRevisionDigest: sha256:45b720c63ea36ca3ab4ec93047748acd68162f7a6843be7637f39baa6e34cf66
7-
sourceBlobDigest: sha256:c4bc148bd2df6e1b53fee2228938cbb11d43111425e73c01ba58df9ba77bd4a0
6+
sourceRevisionDigest: sha256:988388772e5593e64ec3340e617c2043909570fcd91c0cfab9bf188f2fef5b92
7+
sourceBlobDigest: sha256:8f42a23c071ea4583fdaac6d8f79bd01e9162d8ac53fe951400456d9773591a3
88
tags:
99
- latest
10-
- speakeasy-sdk-regen-1736890098
10+
- speakeasy-sdk-regen-1737072154
1111
- 0.4.0
1212
targets:
1313
java-target:
1414
source: my-source
1515
sourceNamespace: my-source-new
16-
sourceRevisionDigest: sha256:45b720c63ea36ca3ab4ec93047748acd68162f7a6843be7637f39baa6e34cf66
17-
sourceBlobDigest: sha256:c4bc148bd2df6e1b53fee2228938cbb11d43111425e73c01ba58df9ba77bd4a0
16+
sourceRevisionDigest: sha256:988388772e5593e64ec3340e617c2043909570fcd91c0cfab9bf188f2fef5b92
17+
sourceBlobDigest: sha256:8f42a23c071ea4583fdaac6d8f79bd01e9162d8ac53fe951400456d9773591a3
1818
codeSamplesNamespace: my-source-java-code-samples
19-
codeSamplesRevisionDigest: sha256:6b137ec14eab445e880ccf6da83cad8aa3c3883a845b386533a3a9c644e639ea
19+
codeSamplesRevisionDigest: sha256:b2d983b1828c0e83ab61e279aac0180f588bb8ccd8f5885240e1d086c9242498
2020
py:
2121
source: first-source
2222
ts:

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,15 @@ The samples below show how a published SDK artifact is used:
3434

3535
Gradle:
3636
```groovy
37-
implementation 'dev.speakeasyapi:javaclientsdk:7.23.3'
37+
implementation 'dev.speakeasyapi:javaclientsdk:7.23.4'
3838
```
3939

4040
Maven:
4141
```xml
4242
<dependency>
4343
<groupId>dev.speakeasyapi</groupId>
4444
<artifactId>javaclientsdk</artifactId>
45-
<version>7.23.3</version>
45+
<version>7.23.4</version>
4646
</dependency>
4747
```
4848

@@ -138,7 +138,7 @@ public class Application {
138138

139139
* [generateCodeSamplePreview](docs/sdks/codesamples/README.md#generatecodesamplepreview) - Generate Code Sample previews from a file and configuration parameters.
140140
* [generateCodeSamplePreviewAsync](docs/sdks/codesamples/README.md#generatecodesamplepreviewasync) - Initiate asynchronous Code Sample preview generation from a file and configuration parameters, receiving an async JobID response for polling.
141-
* [get](docs/sdks/codesamples/README.md#get) - Retrieve usage snippets from document stored in the registry
141+
* [get](docs/sdks/codesamples/README.md#get) - Retrieve usage snippets
142142
* [getCodeSamplePreviewAsync](docs/sdks/codesamples/README.md#getcodesamplepreviewasync) - Poll for the result of an asynchronous Code Sample preview generation.
143143

144144
### [events()](docs/sdks/events/README.md)

RELEASES.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2066,4 +2066,14 @@ Based on:
20662066
### Generated
20672067
- [java v7.23.3] .
20682068
### Releases
2069-
- [Maven Central v7.23.3] https://central.sonatype.com/artifact/dev.speakeasyapi/javaclientsdk/7.23.3 - .
2069+
- [Maven Central v7.23.3] https://central.sonatype.com/artifact/dev.speakeasyapi/javaclientsdk/7.23.3 - .
2070+
2071+
## 2025-01-17 00:02:16
2072+
### Changes
2073+
Based on:
2074+
- OpenAPI Doc
2075+
- Speakeasy CLI 1.468.9 (2.493.21) https://github.com/speakeasy-api/speakeasy
2076+
### Generated
2077+
- [java v7.23.4] .
2078+
### Releases
2079+
- [Maven Central v7.23.4] https://central.sonatype.com/artifact/dev.speakeasyapi/javaclientsdk/7.23.4 - .

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ tasks.withType(Javadoc) {
6161
}
6262

6363
group = "dev.speakeasyapi"
64-
version = "7.23.3"
64+
version = "7.23.4"
6565

6666
sourcesJar {
6767
archiveBaseName = "javaclientsdk"
@@ -88,7 +88,7 @@ publishing {
8888
maven(MavenPublication) {
8989
groupId = 'dev.speakeasyapi'
9090
artifactId = 'javaclientsdk'
91-
version = '7.23.3'
91+
version = '7.23.4'
9292

9393
from components.java
9494

codeSamples.yaml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,7 @@ actions:
383383
import dev.speakeasyapi.javaclientsdk.models.operations.GetCodeSamplesResponse;
384384
import dev.speakeasyapi.javaclientsdk.models.shared.Security;
385385
import java.lang.Exception;
386+
import java.util.List;
386387
387388
public class Application {
388389
@@ -395,7 +396,11 @@ actions:
395396
.build();
396397
397398
GetCodeSamplesRequest req = GetCodeSamplesRequest.builder()
398-
.registryUrl("https://normal-making.name")
399+
.registryUrl("https://spec.speakeasy.com/my-org/my-workspace/my-source")
400+
.operationIds(List.of(
401+
"getPetById"))
402+
.languages(List.of(
403+
"python"))
399404
.build();
400405
401406
GetCodeSamplesResponse res = sdk.codeSamples().get()
@@ -427,7 +432,7 @@ actions:
427432
428433
public class Application {
429434
430-
public static void main(String[] args) throws Error, Exception {
435+
public static void main(String[] args) throws Error, Error, Exception {
431436
432437
RyanTest sdk = RyanTest.builder()
433438
.security(Security.builder()
@@ -474,7 +479,7 @@ actions:
474479
475480
public class Application {
476481
477-
public static void main(String[] args) throws Error, Exception {
482+
public static void main(String[] args) throws Error, Error, Exception {
478483
479484
RyanTest sdk = RyanTest.builder()
480485
.security(Security.builder()
@@ -519,7 +524,7 @@ actions:
519524
520525
public class Application {
521526
522-
public static void main(String[] args) throws Error, Exception {
527+
public static void main(String[] args) throws Error, Error, Exception {
523528
524529
RyanTest sdk = RyanTest.builder()
525530
.security(Security.builder()

docs/models/operations/GetCodeSamplesRequest.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33

44
## Fields
55

6-
| Field | Type | Required | Description |
7-
| ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ |
8-
| `languages` | List\<*String*> | :heavy_minus_sign: | N/A |
9-
| `operationIds` | List\<*String*> | :heavy_minus_sign: | N/A |
10-
| `registryUrl` | *String* | :heavy_check_mark: | The registry URL from which to retrieve the snippets. E.g. https://spec.speakeasy.com/org/ws/my-source |
6+
| Field | Type | Required | Description | Example |
7+
| -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- |
8+
| `languages` | List\<*String*> | :heavy_minus_sign: | The languages to retrieve snippets for. | |
9+
| `operationIds` | List\<*String*> | :heavy_minus_sign: | The operation IDs to retrieve snippets for. | getPetById |
10+
| `registryUrl` | *String* | :heavy_check_mark: | The registry URL from which to retrieve the snippets. | https://spec.speakeasy.com/my-org/my-workspace/my-source |

docs/sdks/codesamples/README.md

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ REST APIs for retrieving Code Samples
99

1010
* [generateCodeSamplePreview](#generatecodesamplepreview) - Generate Code Sample previews from a file and configuration parameters.
1111
* [generateCodeSamplePreviewAsync](#generatecodesamplepreviewasync) - Initiate asynchronous Code Sample preview generation from a file and configuration parameters, receiving an async JobID response for polling.
12-
* [get](#get) - Retrieve usage snippets from document stored in the registry
12+
* [get](#get) - Retrieve usage snippets
1313
* [getCodeSamplePreviewAsync](#getcodesamplepreviewasync) - Poll for the result of an asynchronous Code Sample preview generation.
1414

1515
## generateCodeSamplePreview
@@ -33,7 +33,7 @@ import java.util.List;
3333

3434
public class Application {
3535

36-
public static void main(String[] args) throws Error, Exception {
36+
public static void main(String[] args) throws Error, Error, Exception {
3737

3838
RyanTest sdk = RyanTest.builder()
3939
.security(Security.builder()
@@ -76,7 +76,8 @@ public class Application {
7676

7777
| Error Type | Status Code | Content Type |
7878
| ------------------- | ------------------- | ------------------- |
79-
| models/errors/Error | 4XX, 5XX | application/json |
79+
| models/errors/Error | 4XX | application/json |
80+
| models/errors/Error | 5XX | application/json |
8081

8182
## generateCodeSamplePreviewAsync
8283

@@ -99,7 +100,7 @@ import java.util.List;
99100

100101
public class Application {
101102

102-
public static void main(String[] args) throws Error, Exception {
103+
public static void main(String[] args) throws Error, Error, Exception {
103104

104105
RyanTest sdk = RyanTest.builder()
105106
.security(Security.builder()
@@ -143,11 +144,13 @@ public class Application {
143144

144145
| Error Type | Status Code | Content Type |
145146
| ------------------- | ------------------- | ------------------- |
146-
| models/errors/Error | 4XX, 5XX | application/json |
147+
| models/errors/Error | 4XX | application/json |
148+
| models/errors/Error | 5XX | application/json |
147149

148150
## get
149151

150-
Retrieve usage snippets from document stored in the registry. Supports filtering by language and operation ID.
152+
Retrieve usage snippets from an OpenAPI document stored in the registry. Supports filtering by language and operation ID.
153+
151154

152155
### Example Usage
153156

@@ -160,6 +163,7 @@ import dev.speakeasyapi.javaclientsdk.models.operations.GetCodeSamplesRequest;
160163
import dev.speakeasyapi.javaclientsdk.models.operations.GetCodeSamplesResponse;
161164
import dev.speakeasyapi.javaclientsdk.models.shared.Security;
162165
import java.lang.Exception;
166+
import java.util.List;
163167

164168
public class Application {
165169

@@ -172,7 +176,11 @@ public class Application {
172176
.build();
173177

174178
GetCodeSamplesRequest req = GetCodeSamplesRequest.builder()
175-
.registryUrl("https://normal-making.name")
179+
.registryUrl("https://spec.speakeasy.com/my-org/my-workspace/my-source")
180+
.languages(List.of(
181+
"python"))
182+
.operationIds(List.of(
183+
"getPetById"))
176184
.build();
177185

178186
GetCodeSamplesResponse res = sdk.codeSamples().get()
@@ -221,7 +229,7 @@ import java.lang.Exception;
221229

222230
public class Application {
223231

224-
public static void main(String[] args) throws Error, Exception {
232+
public static void main(String[] args) throws Error, Error, Exception {
225233

226234
RyanTest sdk = RyanTest.builder()
227235
.security(Security.builder()
@@ -258,4 +266,5 @@ public class Application {
258266

259267
| Error Type | Status Code | Content Type |
260268
| ------------------- | ------------------- | ------------------- |
261-
| models/errors/Error | 4XX, 5XX | application/json |
269+
| models/errors/Error | 4XX | application/json |
270+
| models/errors/Error | 5XX | application/json |

gen.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ generation:
1111
oAuth2ClientCredentialsEnabled: false
1212
oAuth2PasswordEnabled: false
1313
java:
14-
version: 7.23.3
14+
version: 7.23.4
1515
additionalDependencies: []
1616
additionalPlugins: []
1717
artifactID: javaclientsdk

src/main/java/dev/speakeasyapi/javaclientsdk/Auth.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,15 @@ public GetWorkspaceAccessResponse getAccess(
202202
Utils.extractByteArrayFromBody(_httpRes));
203203
}
204204
}
205-
if (Utils.statusCodeMatches(_httpRes.statusCode(), "4XX", "5XX")) {
205+
if (Utils.statusCodeMatches(_httpRes.statusCode(), "4XX")) {
206+
// no content
207+
throw new SDKError(
208+
_httpRes,
209+
_httpRes.statusCode(),
210+
"API error occurred",
211+
Utils.extractByteArrayFromBody(_httpRes));
212+
}
213+
if (Utils.statusCodeMatches(_httpRes.statusCode(), "5XX")) {
206214
// no content
207215
throw new SDKError(
208216
_httpRes,

0 commit comments

Comments
 (0)