Skip to content

Commit 3e2ea36

Browse files
github-actions[bot]speakeasybotspeakeasy-github[bot]
authored
chore: 🐝 Update SDK - Generate 0.3.0 (#11)
> [!IMPORTANT] > Linting report available at: <https://app.speakeasy.com/org/vanta/vanta/linting-report/3e8f9bd9fb3d3cd5d5ee445c9799ed50> # SDK update Based on: - OpenAPI Doc - Speakeasy CLI 1.583.0 (2.658.3) https://github.com/speakeasy-api/speakeasy ## Versioning Version Bump Type: [minor] - 🤖 (automated) ## JAVA CHANGELOG ## core: 3.44.0 - 2025-07-08 ### 🐝 New Features - separate logging section from installation in Java v2 SDK README *(commit by [@AshGodfrey](https://github.com/AshGodfrey))* ## core: 3.43.0 - 2025-07-05 ### 🐝 New Features - support null friendly parameters in methods and builders *(commit by [@vishalg0wda](https://github.com/vishalg0wda))* ## core: 3.42.3 - 2025-07-03 ### 🐛 Bug Fixes - avoid relying on gradle java toolchains *(commit by [@vishalg0wda](https://github.com/vishalg0wda))* ## core: 3.42.2 - 2025-07-02 ### 🐛 Bug Fixes - handle NPE cases when no globals are defined in the spec *(commit by [@vishalg0wda](https://github.com/vishalg0wda))* ## core: 3.42.1 - 2025-07-01 ### 🐛 Bug Fixes - java toolchain language version in build.gradle *(commit by [@davidmoten](https://github.com/davidmoten))* ## core: 3.42.0 - 2025-07-01 ### 🐝 New Features - java - enhance equals/hashCode to support mathematical equivalence *(commit by [@davidmoten](https://github.com/davidmoten))* ## core: 3.41.0 - 2025-06-27 ### 🐝 New Features - set java language version *(commit by [@walker-tx](https://github.com/walker-tx))* ## core: 3.40.1 - 2025-06-27 ### 🐛 Bug Fixes - revert java version setting *(commit by [@walker-tx](https://github.com/walker-tx))* ## core: 3.40.0 - 2025-06-26 ### 🐝 New Features - select java language version *(commit by [@walker-tx](https://github.com/walker-tx))* ## core: 3.39.1 - 2025-06-23 ### 🔧 Chores - introduce standalone Operation classes for encapsulating operation logic *(commit by [@vishalg0wda](https://github.com/vishalg0wda))* ## core: 3.39.0 - 2025-06-12 ### 🐝 New Features - use singleton http client *(commit by [@vishalg0wda](https://github.com/vishalg0wda))* ## core: 3.38.0 - 2025-06-10 ### 🐝 New Features - support custom code regions *(commit by [@vishalg0wda](https://github.com/vishalg0wda))* ## core: 3.37.5 - 2025-06-06 ### 🐛 Bug Fixes - add support for arrays of files in multipart forms *(commit by [@TristanSpeakEasy](https://github.com/tristanspeakeasy))* ## core: 3.37.4 - 2025-05-30 ### 🐛 Bug Fixes - include packageName in config metadata definitions, fix javadoc warnings *(commit by [@davidmoten](https://github.com/davidmoten))* ## core: 3.37.3 - 2025-05-07 ### 🐛 Bug Fixes - fixed stability of generated examples using operation and field seeds, including fixes to union examples *(commit by [@TristanSpeakEasy](https://github.com/tristanspeakeasy))* ## core: 3.37.2 - 2025-04-30 ### 🐛 Bug Fixes - java - generate snippets for compilation test after parallel jobs run *(commit by [@davidmoten](https://github.com/davidmoten))* ## globalSecurity: 2.83.0 - 2025-06-25 ### 🐝 New Features - use environment variables for API keys/secrets in usage snippets *(commit by [@sheldonvaughn](https://github.com/sheldonvaughn))* ## globalServerURLs: 2.82.2 - 2025-05-09 ### 🐛 Bug Fixes - fixed issue with cached templated server url *(commit by [@TristanSpeakEasy](https://github.com/tristanspeakeasy))* ## sdkHooks: 1.1.0 - 2025-05-12 ### 🐝 New Features - add support for accessing sdk configuration in hooks *(commit by [@TristanSpeakEasy](https://github.com/tristanspeakeasy))* --------- Co-authored-by: speakeasybot <[email protected]> Co-authored-by: speakeasy-github[bot] <128539517+speakeasy-github[bot]@users.noreply.github.com>
1 parent 4e9c097 commit 3e2ea36

File tree

116 files changed

+4504
-2864
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+4504
-2864
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
**/.speakeasy/temp/
2+
**/.speakeasy/logs/
13
# Ignore Gradle project-specific cache directory
24
.gradle
35
# Ignore Gradle build output directory

.speakeasy/gen.lock

Lines changed: 31 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
11
lockVersion: 2.0.0
22
id: f42d74f5-5725-46fa-b13c-649b7ef895c3
33
management:
4-
docChecksum: 1a2b10b336197dc97b4e05876d814f28
4+
docChecksum: 32687d9ba29da014326cc097fdfff59d
55
docVersion: 1.0.0
6-
speakeasyVersion: 1.533.0
7-
generationVersion: 2.578.0
8-
releaseVersion: 0.2.0
9-
configChecksum: 23d16b94689a0480c660cd212b26e69c
6+
speakeasyVersion: 1.583.0
7+
generationVersion: 2.658.3
8+
releaseVersion: 0.3.0
9+
configChecksum: 04772eab57280291f66f591afacc7c70
1010
repoURL: https://github.com/VantaInc/vanta-auditor-api-sdk-java.git
1111
published: true
1212
features:
1313
java:
1414
additionalDependencies: 0.1.0
1515
constsAndDefaults: 0.1.1
16-
core: 3.37.1
16+
core: 3.44.0
1717
flattening: 2.81.1
18-
globalSecurity: 2.82.8
18+
globalSecurity: 2.83.0
1919
globalSecurityCallbacks: 0.1.0
2020
globalSecurityFlattening: 0.1.0
21-
globalServerURLs: 2.82.1
21+
globalServerURLs: 2.82.2
2222
nameOverrides: 2.81.3
2323
nullables: 0.1.0
24-
sdkHooks: 1.0.0
24+
sdkHooks: 1.1.0
2525
unions: 0.0.6
2626
generatedFiles:
2727
- .gitattributes
@@ -33,6 +33,7 @@ generatedFiles:
3333
- docs/models/components/AuditEvidenceState.md
3434
- docs/models/components/AuditEvidenceType.md
3535
- docs/models/components/AuditEvidenceUpdateInput.md
36+
- docs/models/components/AuditFocus.md
3637
- docs/models/components/Auditor.md
3738
- docs/models/components/AuditorControl.md
3839
- docs/models/components/AuditorEnabledStateTransition.md
@@ -108,6 +109,7 @@ generatedFiles:
108109
- src/main/java/com/vanta/vanta_auditor_api/models/components/AuditEvidenceState.java
109110
- src/main/java/com/vanta/vanta_auditor_api/models/components/AuditEvidenceType.java
110111
- src/main/java/com/vanta/vanta_auditor_api/models/components/AuditEvidenceUpdateInput.java
112+
- src/main/java/com/vanta/vanta_auditor_api/models/components/AuditFocus.java
111113
- src/main/java/com/vanta/vanta_auditor_api/models/components/Auditor.java
112114
- src/main/java/com/vanta/vanta_auditor_api/models/components/AuditorControl.java
113115
- src/main/java/com/vanta/vanta_auditor_api/models/components/AuditorEnabledStateTransition.java
@@ -172,20 +174,33 @@ generatedFiles:
172174
- src/main/java/com/vanta/vanta_auditor_api/models/operations/ListAuditsRequest.java
173175
- src/main/java/com/vanta/vanta_auditor_api/models/operations/ListAuditsRequestBuilder.java
174176
- src/main/java/com/vanta/vanta_auditor_api/models/operations/ListAuditsResponse.java
175-
- src/main/java/com/vanta/vanta_auditor_api/models/operations/SDKMethodInterfaces.java
176177
- src/main/java/com/vanta/vanta_auditor_api/models/operations/UpdateAuditEvidenceRequest.java
177178
- src/main/java/com/vanta/vanta_auditor_api/models/operations/UpdateAuditEvidenceRequestBuilder.java
178179
- src/main/java/com/vanta/vanta_auditor_api/models/operations/UpdateAuditEvidenceResponse.java
180+
- src/main/java/com/vanta/vanta_auditor_api/operations/CreateAuditorOperation.java
181+
- src/main/java/com/vanta/vanta_auditor_api/operations/CreateCommentForAuditEvidenceOperation.java
182+
- src/main/java/com/vanta/vanta_auditor_api/operations/CreateCustomControlOperation.java
183+
- src/main/java/com/vanta/vanta_auditor_api/operations/CreateCustomEvidenceRequestOperation.java
184+
- src/main/java/com/vanta/vanta_auditor_api/operations/ListAuditCommentsOperation.java
185+
- src/main/java/com/vanta/vanta_auditor_api/operations/ListAuditControlsOperation.java
186+
- src/main/java/com/vanta/vanta_auditor_api/operations/ListAuditEvidenceOperation.java
187+
- src/main/java/com/vanta/vanta_auditor_api/operations/ListAuditEvidenceUrlsOperation.java
188+
- src/main/java/com/vanta/vanta_auditor_api/operations/ListAuditsOperation.java
189+
- src/main/java/com/vanta/vanta_auditor_api/operations/Operations.java
190+
- src/main/java/com/vanta/vanta_auditor_api/operations/UpdateAuditEvidenceOperation.java
179191
- src/main/java/com/vanta/vanta_auditor_api/utils/BackoffStrategy.java
180192
- src/main/java/com/vanta/vanta_auditor_api/utils/BigDecimalString.java
181193
- src/main/java/com/vanta/vanta_auditor_api/utils/BigIntegerString.java
182194
- src/main/java/com/vanta/vanta_auditor_api/utils/Constants.java
195+
- src/main/java/com/vanta/vanta_auditor_api/utils/CopiableInputStream.java
183196
- src/main/java/com/vanta/vanta_auditor_api/utils/Deserializers.java
184197
- src/main/java/com/vanta/vanta_auditor_api/utils/EventStream.java
185198
- src/main/java/com/vanta/vanta_auditor_api/utils/EventStreamLineReader.java
186199
- src/main/java/com/vanta/vanta_auditor_api/utils/EventStreamMessage.java
187200
- src/main/java/com/vanta/vanta_auditor_api/utils/EventStreamReader.java
201+
- src/main/java/com/vanta/vanta_auditor_api/utils/Exceptions.java
188202
- src/main/java/com/vanta/vanta_auditor_api/utils/FormMetadata.java
203+
- src/main/java/com/vanta/vanta_auditor_api/utils/Globals.java
189204
- src/main/java/com/vanta/vanta_auditor_api/utils/HTTPClient.java
190205
- src/main/java/com/vanta/vanta_auditor_api/utils/HTTPRequest.java
191206
- src/main/java/com/vanta/vanta_auditor_api/utils/HasSecurity.java
@@ -230,7 +245,7 @@ examples:
230245
pageSize: 10
231246
responses:
232247
"200":
233-
application/json: {"results": {"data": [{"id": "65fc81a3359c8508c9af880f", "customerOrganizationName": "corporation.com", "customerDisplayName": "Corporation Company", "customerOrganizationId": "65fc81a3359c8508c9af880f", "auditStartDate": "2024-03-07T21:25:56Z", "auditEndDate": "2024-03-14T21:25:56Z", "earlyAccessStartsDate": "2024-03-07T21:25:56Z", "framework": "SOC 2 Type II", "allowAuditorEmails": ["[email protected]"], "allowAllAuditors": true, "deletionDate": "2024-03-07T21:25:56Z", "creationDate": "2024-03-07T21:25:56Z", "modificationDate": "2024-03-07T21:25:56Z", "completionDate": "2024-03-07T21:25:56Z"}], "pageInfo": {"endCursor": "YXJyYXljb25uZWN0aW9uOjE=", "hasNextPage": false, "hasPreviousPage": false, "startCursor": "YXJyYXljb25uZWN0aW9uOjA="}}}
248+
application/json: {"results": {"data": [{"id": "65fc81a3359c8508c9af880f", "customerOrganizationName": "corporation.com", "customerDisplayName": "Corporation Company", "customerOrganizationId": "65fc81a3359c8508c9af880f", "auditStartDate": "2024-03-07T21:25:56Z", "auditEndDate": "2024-03-14T21:25:56Z", "earlyAccessStartsAt": "2024-03-07T21:25:56Z", "framework": "SOC 2 Type II", "allowAuditorEmails": ["[email protected]"], "allowAllAuditors": true, "deletionDate": "2024-03-07T21:25:56Z", "creationDate": "2024-03-07T21:25:56Z", "modificationDate": "2024-03-07T21:25:56Z", "completionDate": "2024-03-07T21:25:56Z", "auditFocus": "EXTERNAL"}], "pageInfo": {"endCursor": "YXJyYXljb25uZWN0aW9uOjE=", "hasNextPage": false, "hasPreviousPage": false, "startCursor": "YXJyYXljb25uZWN0aW9uOjA="}}}
234249
ListAuditEvidenceUrls:
235250
Example 1:
236251
parameters:
@@ -279,7 +294,7 @@ examples:
279294
auditId: "<id>"
280295
auditEvidenceId: "<id>"
281296
requestBody:
282-
application/json: {"text": "<value>", "email": "Alexis74@hotmail.com", "creationDate": "2024-08-13T11:18:40.035Z"}
297+
application/json: {"text": "<value>", "email": "Carmen.Bogan@yahoo.com", "creationDate": "2024-05-28T11:04:29.369Z"}
283298
responses:
284299
"200":
285300
application/json: {"id": "65fc81a3359c8508c9af880f", "auditEvidenceId": "65fc81a3359c8508c9af880f", "text": "Some comment", "creationDate": "2024-03-07T21:25:56Z", "modificationDate": "2024-03-07T21:25:56Z", "deletionDate": "2024-03-07T21:25:56Z", "email": "[email protected]"}
@@ -300,7 +315,7 @@ examples:
300315
path:
301316
auditId: "<id>"
302317
requestBody:
303-
application/json: {"controlIds": ["<value>"], "title": "<value>", "description": "now whoa while", "cadence": "P3M", "reminderWindow": "P0D", "isRestricted": true, "auditorEmail": "<value>"}
318+
application/json: {"controlIds": ["<value 1>", "<value 2>"], "title": "<value>", "description": "pure bludgeon deliberately question although", "cadence": "P1D", "reminderWindow": "P0D", "isRestricted": false, "auditorEmail": "<value>"}
304319
responses:
305320
"200":
306321
application/json: {"id": "65fc81a3359c8508c9af880f", "controlIds": ["1.1.2.a"], "title": "Access Control Policy", "description": "Description for Access Control Policy", "cadence": "P6M", "reminderWindow": "P6M", "isRestricted": true}
@@ -310,16 +325,16 @@ examples:
310325
path:
311326
auditId: "<id>"
312327
requestBody:
313-
application/json: {"externalId": "<id>", "name": "<value>", "description": "even keenly afore mmm yearningly ouch tough yearly intent", "effectiveDate": "2024-07-08T11:52:30.590Z", "category": "THREAT_MANAGEMENT"}
328+
application/json: {"externalId": "<id>", "name": null, "description": "yet plus utter queasily what juvenile wound", "effectiveDate": "2024-11-10T13:58:54.564Z", "category": "CLOUD_SECURITY"}
314329
responses:
315330
"201":
316331
application/json: {"id": "a2f7e1b9d0c3f4e5a6c7b8d9", "externalId": "CRY-104", "name": "Data encryption utilized", "description": "Access reviews are performed to ensure that access is appropriate for the user's role and responsibilities.", "source": "Vanta", "domains": ["CRYPTOGRAPHIC_PROTECTIONS"], "owner": {"id": "65e1efde08e8478f143a8ff9", "displayName": "Example Owner", "emailAddress": "[email protected]"}, "role": "CONTROLLER", "customFields": [{"label": "Additional context", "value": "This control is critical for GDPR compliance"}]}
317332
CreateAuditor:
318333
Example 1:
319334
requestBody:
320-
application/json: {"email": "Loyal79@yahoo.com", "givenName": "<value>", "familyName": "<value>"}
335+
application/json: {"email": "Genesis_Kunze87@yahoo.com", "givenName": "<value>", "familyName": "<value>"}
321336
responses:
322337
"200":
323338
application/json: {"id": "65fc81a3359c8508c9af880f", "organizationId": "8c9af880f1a335965fc850c8", "email": "[email protected]", "givenName": "Sam", "familyName": "Auditor"}
324-
examplesVersion: 1.0.1
339+
examplesVersion: 1.0.2
325340
generatedTests: {}

.speakeasy/gen.yaml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,26 +4,35 @@ generation:
44
maintainOpenAPIOrder: true
55
usageSnippets:
66
optionalPropertyRendering: withExample
7+
sdkInitStyle: constructor
78
useClassNamesForArrayFields: true
89
fixes:
910
nameResolutionDec2023: true
1011
nameResolutionFeb2025: false
1112
parameterOrderingFeb2024: true
1213
requestResponseComponentNamesFeb2024: true
1314
securityFeb2025: false
15+
sharedErrorComponentsApr2025: false
1416
auth:
1517
oAuth2ClientCredentialsEnabled: true
1618
oAuth2PasswordEnabled: true
19+
tests:
20+
generateTests: true
21+
generateNewTests: false
22+
skipResponseBodyAssertions: false
1723
java:
18-
version: 0.2.0
24+
version: 0.3.0
1925
additionalDependencies: []
2026
additionalPlugins: []
2127
artifactID: vanta-auditor-api
28+
baseErrorName: VantaError
2229
clientServerStatusCodesAsErrors: true
2330
companyEmail: [email protected]
2431
companyName: Vanta
2532
companyURL: www.vanta.com
2633
defaultErrorName: APIException
34+
enableAsync: false
35+
enableCustomCodeRegions: false
2736
flattenGlobalSecurity: true
2837
githubURL: github.com/VantaInc/vanta-auditor-api-sdk-java
2938
groupID: com.vanta
@@ -36,11 +45,13 @@ java:
3645
shared: models/components
3746
webhooks: models/webhooks
3847
inputModelSuffix: input
48+
languageVersion: 11
3949
license:
4050
name: The MIT License (MIT)
4151
shortName: MIT
4252
url: https://mit-license.org/
4353
maxMethodParams: 4
54+
nullFriendlyParameters: false
4455
outputModelSuffix: output
4556
projectName: openapi
4657
templateVersion: v2

.speakeasy/workflow.lock

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
speakeasyVersion: 1.533.0
1+
speakeasyVersion: 1.583.0
22
sources:
33
Conduct an audit:
44
sourceNamespace: conduct-an-audit
5-
sourceRevisionDigest: sha256:fa49ac1c79f171ea6a2d1c947afc689d53fdcfacc6d0c758607d67082c43f3f7
6-
sourceBlobDigest: sha256:bbe79169dea0b06f442a5b981fda5eb09f04b5ea369ef9832e48e6feabdccc08
5+
sourceRevisionDigest: sha256:234b914b23cf5d74d33cd7077560a45c8cba13a211f3bd8344041648d8733c2d
6+
sourceBlobDigest: sha256:8fefc2fa168b537a6f137983f6366a1d8abe9ea0a01bc6d108c601431b922a5b
77
tags:
88
- latest
9-
- speakeasy-sdk-regen-1744825786
9+
- speakeasy-sdk-regen-1752711959
1010
- 1.0.0
1111
targets:
1212
vanta:
1313
source: Conduct an audit
1414
sourceNamespace: conduct-an-audit
15-
sourceRevisionDigest: sha256:fa49ac1c79f171ea6a2d1c947afc689d53fdcfacc6d0c758607d67082c43f3f7
16-
sourceBlobDigest: sha256:bbe79169dea0b06f442a5b981fda5eb09f04b5ea369ef9832e48e6feabdccc08
15+
sourceRevisionDigest: sha256:234b914b23cf5d74d33cd7077560a45c8cba13a211f3bd8344041648d8733c2d
16+
sourceBlobDigest: sha256:8fefc2fa168b537a6f137983f6366a1d8abe9ea0a01bc6d108c601431b922a5b
1717
codeSamplesNamespace: conduct-an-audit-java-code-samples
18-
codeSamplesRevisionDigest: sha256:3438586112f5de4156d99fa595eb77066b0fe12b05f8e0be4b0d1a1d8fe2618e
18+
codeSamplesRevisionDigest: sha256:c37b408b3f4e67573812e3180585ed44685609283ecc89a119faafece26cadcc
1919
workflow:
2020
workflowVersion: 1.0.0
2121
speakeasyVersion: latest

README.md

Lines changed: 45 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ Conduct an audit: The Auditor API lets audit firms conduct audits from a tool ou
2525
* [Available Resources and Operations](#available-resources-and-operations)
2626
* [Error Handling](#error-handling)
2727
* [Server Selection](#server-selection)
28+
* [Debugging](#debugging)
2829
* [Development](#development)
2930
* [Maturity](#maturity)
3031
* [Contributions](#contributions)
@@ -43,15 +44,15 @@ The samples below show how a published SDK artifact is used:
4344

4445
Gradle:
4546
```groovy
46-
implementation 'com.vanta:vanta-auditor-api:0.2.0'
47+
implementation 'com.vanta:vanta-auditor-api:0.3.0'
4748
```
4849

4950
Maven:
5051
```xml
5152
<dependency>
5253
<groupId>com.vanta</groupId>
5354
<artifactId>vanta-auditor-api</artifactId>
54-
<version>0.2.0</version>
55+
<version>0.3.0</version>
5556
</dependency>
5657
```
5758

@@ -68,29 +69,6 @@ On Windows:
6869
```bash
6970
gradlew.bat publishToMavenLocal -Pskip.signing
7071
```
71-
72-
### Logging
73-
A logging framework/facade has not yet been adopted but is under consideration.
74-
75-
For request and response logging (especially json bodies) use:
76-
```java
77-
SpeakeasyHTTPClient.setDebugLogging(true); // experimental API only (may change without warning)
78-
```
79-
Example output:
80-
```
81-
Sending request: http://localhost:35123/bearer#global GET
82-
Request headers: {Accept=[application/json], Authorization=[******], Client-Level-Header=[added by client], Idempotency-Key=[some-key], x-speakeasy-user-agent=[speakeasy-sdk/java 0.0.1 internal 0.1.0 org.openapis.openapi]}
83-
Received response: (GET http://localhost:35123/bearer#global) 200
84-
Response headers: {access-control-allow-credentials=[true], access-control-allow-origin=[*], connection=[keep-alive], content-length=[50], content-type=[application/json], date=[Wed, 09 Apr 2025 01:43:29 GMT], server=[gunicorn/19.9.0]}
85-
Response body:
86-
{
87-
"authenticated": true,
88-
"token": "global"
89-
}
90-
```
91-
WARNING: This should only used for temporary debugging purposes. Leaving this option on in a production system could expose credentials/secrets in logs. <i>Authorization</i> headers are redacted by default and there is the ability to specify redacted header names via `SpeakeasyHTTPClient.setRedactedHeaders`.
92-
93-
Another option is to set the System property `-Djdk.httpclient.HttpClient.log=all`. However, this second option does not log bodies.
9472
<!-- End SDK Installation [installation] -->
9573

9674
<!-- Start SDK Example Usage [usage] -->
@@ -110,10 +88,11 @@ public class Application {
11088
public static void main(String[] args) throws Exception {
11189

11290
Vanta sdk = Vanta.builder()
113-
.bearerAuth("<YOUR_BEARER_TOKEN_HERE>")
91+
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
11492
.build();
11593

11694
ListAuditsResponse res = sdk.audits().list()
95+
.pageSize(10)
11796
.call();
11897

11998
if (res.paginatedResponseAudit().isPresent()) {
@@ -148,10 +127,11 @@ public class Application {
148127
public static void main(String[] args) throws Exception {
149128

150129
Vanta sdk = Vanta.builder()
151-
.bearerAuth("<YOUR_BEARER_TOKEN_HERE>")
130+
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
152131
.build();
153132

154133
ListAuditsResponse res = sdk.audits().list()
134+
.pageSize(10)
155135
.call();
156136

157137
if (res.paginatedResponseAudit().isPresent()) {
@@ -213,10 +193,11 @@ public class Application {
213193
public static void main(String[] args) throws Exception {
214194

215195
Vanta sdk = Vanta.builder()
216-
.bearerAuth("<YOUR_BEARER_TOKEN_HERE>")
196+
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
217197
.build();
218198

219199
ListAuditsResponse res = sdk.audits().list()
200+
.pageSize(10)
220201
.call();
221202

222203
if (res.paginatedResponseAudit().isPresent()) {
@@ -255,10 +236,11 @@ public class Application {
255236

256237
Vanta sdk = Vanta.builder()
257238
.serverIndex(2)
258-
.bearerAuth("<YOUR_BEARER_TOKEN_HERE>")
239+
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
259240
.build();
260241

261242
ListAuditsResponse res = sdk.audits().list()
243+
.pageSize(10)
262244
.call();
263245

264246
if (res.paginatedResponseAudit().isPresent()) {
@@ -283,11 +265,12 @@ public class Application {
283265
public static void main(String[] args) throws Exception {
284266

285267
Vanta sdk = Vanta.builder()
286-
.serverURL("https://api.vanta.com/v1")
287-
.bearerAuth("<YOUR_BEARER_TOKEN_HERE>")
268+
.serverURL("https://api.aus.vanta.com/v1")
269+
.bearerAuth(System.getenv().getOrDefault("BEARER_AUTH", ""))
288270
.build();
289271

290272
ListAuditsResponse res = sdk.audits().list()
273+
.pageSize(10)
291274
.call();
292275

293276
if (res.paginatedResponseAudit().isPresent()) {
@@ -298,6 +281,37 @@ public class Application {
298281
```
299282
<!-- End Server Selection [server] -->
300283

284+
<!-- Start Debugging [debug] -->
285+
## Debugging
286+
287+
### Debug
288+
You can setup your SDK to emit debug logs for SDK requests and responses.
289+
290+
For request and response logging (especially json bodies), call `enableHTTPDebugLogging(boolean)` on the SDK builder like so:
291+
```java
292+
SDK.builder()
293+
.enableHTTPDebugLogging(true)
294+
.build();
295+
```
296+
Example output:
297+
```
298+
Sending request: http://localhost:35123/bearer#global GET
299+
Request headers: {Accept=[application/json], Authorization=[******], Client-Level-Header=[added by client], Idempotency-Key=[some-key], x-speakeasy-user-agent=[speakeasy-sdk/java 0.0.1 internal 0.1.0 org.openapis.openapi]}
300+
Received response: (GET http://localhost:35123/bearer#global) 200
301+
Response headers: {access-control-allow-credentials=[true], access-control-allow-origin=[*], connection=[keep-alive], content-length=[50], content-type=[application/json], date=[Wed, 09 Apr 2025 01:43:29 GMT], server=[gunicorn/19.9.0]}
302+
Response body:
303+
{
304+
"authenticated": true,
305+
"token": "global"
306+
}
307+
```
308+
__WARNING__: This should only used for temporary debugging purposes. Leaving this option on in a production system could expose credentials/secrets in logs. <i>Authorization</i> headers are redacted by default and there is the ability to specify redacted header names via `SpeakeasyHTTPClient.setRedactedHeaders`.
309+
310+
__NOTE__: This is a convenience method that calls `HTTPClient.enableDebugLogging()`. The `SpeakeasyHTTPClient` honors this setting. If you are using a custom HTTP client, it is up to the custom client to honor this setting.
311+
312+
Another option is to set the System property `-Djdk.httpclient.HttpClient.log=all`. However, this second option does not log bodies.
313+
<!-- End Debugging [debug] -->
314+
301315
<!-- Placeholder for Future Speakeasy SDK Sections -->
302316

303317
# Development

RELEASES.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,14 @@ Based on:
88
### Generated
99
- [java v0.2.0] .
1010
### Releases
11-
- [Maven Central v0.2.0] https://central.sonatype.com/artifact/com.vanta/vanta-auditor-api/0.2.0 - .
11+
- [Maven Central v0.2.0] https://central.sonatype.com/artifact/com.vanta/vanta-auditor-api/0.2.0 - .
12+
13+
## 2025-07-21 00:27:31
14+
### Changes
15+
Based on:
16+
- OpenAPI Doc
17+
- Speakeasy CLI 1.583.0 (2.658.3) https://github.com/speakeasy-api/speakeasy
18+
### Generated
19+
- [java v0.3.0] .
20+
### Releases
21+
- [Maven Central v0.3.0] https://central.sonatype.com/artifact/com.vanta/vanta-auditor-api/0.3.0 - .

0 commit comments

Comments
 (0)