Skip to content

Commit c24b2ca

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 18ca12a of spec repo
1 parent faf6b7d commit c24b2ca

File tree

133 files changed

+1184
-2511
lines changed

Some content is hidden

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

133 files changed

+1184
-2511
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 50 additions & 176 deletions
Large diffs are not rendered by default.

examples/v2/incidents/CreateIncidentAttachment.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ public static void main(String[] args) {
1717
defaultClient.setUnstableOperationEnabled("v2.createIncidentAttachment", true);
1818
IncidentsApi apiInstance = new IncidentsApi(defaultClient);
1919

20+
// there is a valid "incident" in the system
21+
String INCIDENT_DATA_ID = System.getenv("INCIDENT_DATA_ID");
22+
2023
CreateAttachmentRequest body =
2124
new CreateAttachmentRequest()
2225
.data(
@@ -26,14 +29,13 @@ public static void main(String[] args) {
2629
.attachment(
2730
new CreateAttachmentRequestDataAttributesAttachment()
2831
.documentUrl(
29-
"https://app.datadoghq.com/notebook/123/Postmortem-IR-123")
30-
.title("Postmortem-IR-123"))
32+
"https://app.datadoghq.com/notebook/ExampleIncident/Example-Incident")
33+
.title("Example-Incident"))
3134
.attachmentType(AttachmentDataAttributesAttachmentType.POSTMORTEM))
32-
.id("00000000-0000-0000-0000-000000000000")
3335
.type(IncidentAttachmentType.INCIDENT_ATTACHMENTS));
3436

3537
try {
36-
Attachment result = apiInstance.createIncidentAttachment("incident_id", body);
38+
Attachment result = apiInstance.createIncidentAttachment(INCIDENT_DATA_ID, body);
3739
System.out.println(result);
3840
} catch (ApiException e) {
3941
System.err.println("Exception when calling IncidentsApi#createIncidentAttachment");

examples/v2/incidents/DeleteIncidentAttachment.java

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,14 @@ public static void main(String[] args) {
1010
defaultClient.setUnstableOperationEnabled("v2.deleteIncidentAttachment", true);
1111
IncidentsApi apiInstance = new IncidentsApi(defaultClient);
1212

13+
// there is a valid "incident" in the system
14+
String INCIDENT_DATA_ID = System.getenv("INCIDENT_DATA_ID");
15+
16+
// there is a valid "incident_attachment" in the system
17+
String INCIDENT_ATTACHMENT_DATA_ID = System.getenv("INCIDENT_ATTACHMENT_DATA_ID");
18+
1319
try {
14-
apiInstance.deleteIncidentAttachment("incident_id", "00000000-0000-0000-0000-000000000002");
20+
apiInstance.deleteIncidentAttachment(INCIDENT_DATA_ID, INCIDENT_ATTACHMENT_DATA_ID);
1521
} catch (ApiException e) {
1622
System.err.println("Exception when calling IncidentsApi#deleteIncidentAttachment");
1723
System.err.println("Status code: " + e.getCode());

examples/v2/incidents/ListIncidentAttachments.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ public static void main(String[] args) {
1111
defaultClient.setUnstableOperationEnabled("v2.listIncidentAttachments", true);
1212
IncidentsApi apiInstance = new IncidentsApi(defaultClient);
1313

14+
// there is a valid "incident" in the system
15+
String INCIDENT_DATA_ID = System.getenv("INCIDENT_DATA_ID");
16+
1417
try {
15-
AttachmentArray result = apiInstance.listIncidentAttachments("incident_id");
18+
AttachmentArray result = apiInstance.listIncidentAttachments(INCIDENT_DATA_ID);
1619
System.out.println(result);
1720
} catch (ApiException e) {
1821
System.err.println("Exception when calling IncidentsApi#listIncidentAttachments");

examples/v2/incidents/UpdateIncidentAttachment.java

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@ public static void main(String[] args) {
1616
defaultClient.setUnstableOperationEnabled("v2.updateIncidentAttachment", true);
1717
IncidentsApi apiInstance = new IncidentsApi(defaultClient);
1818

19+
// there is a valid "incident" in the system
20+
String INCIDENT_DATA_ID = System.getenv("INCIDENT_DATA_ID");
21+
22+
// there is a valid "incident_attachment" in the system
23+
String INCIDENT_ATTACHMENT_DATA_ID = System.getenv("INCIDENT_ATTACHMENT_DATA_ID");
24+
1925
PatchAttachmentRequest body =
2026
new PatchAttachmentRequest()
2127
.data(
@@ -25,14 +31,14 @@ public static void main(String[] args) {
2531
.attachment(
2632
new PatchAttachmentRequestDataAttributesAttachment()
2733
.documentUrl(
28-
"https://app.datadoghq.com/notebook/124/Postmortem-IR-124")
29-
.title("Postmortem-IR-124")))
34+
"https://app.datadoghq.com/notebook/124/Example-Incident")
35+
.title("Example-Incident")))
36+
.id(INCIDENT_ATTACHMENT_DATA_ID)
3037
.type(IncidentAttachmentType.INCIDENT_ATTACHMENTS));
3138

3239
try {
3340
Attachment result =
34-
apiInstance.updateIncidentAttachment(
35-
"incident_id", "00000000-0000-0000-0000-000000000002", body);
41+
apiInstance.updateIncidentAttachment(INCIDENT_DATA_ID, INCIDENT_ATTACHMENT_DATA_ID, body);
3642
System.out.println(result);
3743
} catch (ApiException e) {
3844
System.err.println("Exception when calling IncidentsApi#updateIncidentAttachment");

examples/v2/security-monitoring/ListSecurityMonitoringSuppressions.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
import com.datadog.api.client.ApiClient;
44
import com.datadog.api.client.ApiException;
55
import com.datadog.api.client.v2.api.SecurityMonitoringApi;
6-
import com.datadog.api.client.v2.model.SecurityMonitoringPaginatedSuppressionsResponse;
6+
import com.datadog.api.client.v2.model.SecurityMonitoringSuppressionsResponse;
77

88
public class Example {
99
public static void main(String[] args) {
1010
ApiClient defaultClient = ApiClient.getDefaultApiClient();
1111
SecurityMonitoringApi apiInstance = new SecurityMonitoringApi(defaultClient);
1212

1313
try {
14-
SecurityMonitoringPaginatedSuppressionsResponse result =
14+
SecurityMonitoringSuppressionsResponse result =
1515
apiInstance.listSecurityMonitoringSuppressions();
1616
System.out.println(result);
1717
} catch (ApiException e) {

examples/v2/security-monitoring/ListSecurityMonitoringSuppressions_1315707136.java

Lines changed: 0 additions & 37 deletions
This file was deleted.

examples/v2/security-monitoring/ListSecurityMonitoringSuppressions_1741429096.java

Lines changed: 0 additions & 37 deletions
This file was deleted.

examples/v2/security-monitoring/ListSecurityMonitoringSuppressions_3985905558.java

Lines changed: 0 additions & 37 deletions
This file was deleted.

src/main/java/com/datadog/api/client/v2/api/IncidentsApi.java

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1893,7 +1893,7 @@ public CompletableFuture<ApiResponse<Void>> deleteIncidentWithHttpInfoAsync(Stri
18931893
* @param attachmentId The ID of the attachment. (required)
18941894
* @throws ApiException if fails to make API call
18951895
*/
1896-
public void deleteIncidentAttachment(String incidentId, Object attachmentId) throws ApiException {
1896+
public void deleteIncidentAttachment(String incidentId, String attachmentId) throws ApiException {
18971897
deleteIncidentAttachmentWithHttpInfo(incidentId, attachmentId);
18981898
}
18991899

@@ -1907,7 +1907,7 @@ public void deleteIncidentAttachment(String incidentId, Object attachmentId) thr
19071907
* @return CompletableFuture
19081908
*/
19091909
public CompletableFuture<Void> deleteIncidentAttachmentAsync(
1910-
String incidentId, Object attachmentId) {
1910+
String incidentId, String attachmentId) {
19111911
return deleteIncidentAttachmentWithHttpInfoAsync(incidentId, attachmentId)
19121912
.thenApply(
19131913
response -> {
@@ -1932,7 +1932,7 @@ public CompletableFuture<Void> deleteIncidentAttachmentAsync(
19321932
* </table>
19331933
*/
19341934
public ApiResponse<Void> deleteIncidentAttachmentWithHttpInfo(
1935-
String incidentId, Object attachmentId) throws ApiException {
1935+
String incidentId, String attachmentId) throws ApiException {
19361936
// Check if unstable operation is enabled
19371937
String operationId = "deleteIncidentAttachment";
19381938
if (apiClient.isUnstableOperationEnabled("v2." + operationId)) {
@@ -1994,7 +1994,7 @@ public ApiResponse<Void> deleteIncidentAttachmentWithHttpInfo(
19941994
* @return CompletableFuture&lt;ApiResponse&lt;Void&gt;&gt;
19951995
*/
19961996
public CompletableFuture<ApiResponse<Void>> deleteIncidentAttachmentWithHttpInfoAsync(
1997-
String incidentId, Object attachmentId) {
1997+
String incidentId, String attachmentId) {
19981998
// Check if unstable operation is enabled
19991999
String operationId = "deleteIncidentAttachment";
20002000
if (apiClient.isUnstableOperationEnabled("v2." + operationId)) {
@@ -6619,7 +6619,7 @@ public UpdateIncidentAttachmentOptionalParameters include(String include) {
66196619
* @throws ApiException if fails to make API call
66206620
*/
66216621
public Attachment updateIncidentAttachment(
6622-
String incidentId, Object attachmentId, PatchAttachmentRequest body) throws ApiException {
6622+
String incidentId, String attachmentId, PatchAttachmentRequest body) throws ApiException {
66236623
return updateIncidentAttachmentWithHttpInfo(
66246624
incidentId, attachmentId, body, new UpdateIncidentAttachmentOptionalParameters())
66256625
.getData();
@@ -6636,7 +6636,7 @@ incidentId, attachmentId, body, new UpdateIncidentAttachmentOptionalParameters()
66366636
* @return CompletableFuture&lt;Attachment&gt;
66376637
*/
66386638
public CompletableFuture<Attachment> updateIncidentAttachmentAsync(
6639-
String incidentId, Object attachmentId, PatchAttachmentRequest body) {
6639+
String incidentId, String attachmentId, PatchAttachmentRequest body) {
66406640
return updateIncidentAttachmentWithHttpInfoAsync(
66416641
incidentId, attachmentId, body, new UpdateIncidentAttachmentOptionalParameters())
66426642
.thenApply(
@@ -6659,7 +6659,7 @@ incidentId, attachmentId, body, new UpdateIncidentAttachmentOptionalParameters()
66596659
*/
66606660
public Attachment updateIncidentAttachment(
66616661
String incidentId,
6662-
Object attachmentId,
6662+
String attachmentId,
66636663
PatchAttachmentRequest body,
66646664
UpdateIncidentAttachmentOptionalParameters parameters)
66656665
throws ApiException {
@@ -6680,7 +6680,7 @@ public Attachment updateIncidentAttachment(
66806680
*/
66816681
public CompletableFuture<Attachment> updateIncidentAttachmentAsync(
66826682
String incidentId,
6683-
Object attachmentId,
6683+
String attachmentId,
66846684
PatchAttachmentRequest body,
66856685
UpdateIncidentAttachmentOptionalParameters parameters) {
66866686
return updateIncidentAttachmentWithHttpInfoAsync(incidentId, attachmentId, body, parameters)
@@ -6710,7 +6710,7 @@ public CompletableFuture<Attachment> updateIncidentAttachmentAsync(
67106710
*/
67116711
public ApiResponse<Attachment> updateIncidentAttachmentWithHttpInfo(
67126712
String incidentId,
6713-
Object attachmentId,
6713+
String attachmentId,
67146714
PatchAttachmentRequest body,
67156715
UpdateIncidentAttachmentOptionalParameters parameters)
67166716
throws ApiException {
@@ -6788,7 +6788,7 @@ public ApiResponse<Attachment> updateIncidentAttachmentWithHttpInfo(
67886788
*/
67896789
public CompletableFuture<ApiResponse<Attachment>> updateIncidentAttachmentWithHttpInfoAsync(
67906790
String incidentId,
6791-
Object attachmentId,
6791+
String attachmentId,
67926792
PatchAttachmentRequest body,
67936793
UpdateIncidentAttachmentOptionalParameters parameters) {
67946794
// Check if unstable operation is enabled

0 commit comments

Comments
 (0)