Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2025-06-25 17:36:54.437854",
"spec_repo_commit": "51c17453"
"regenerated": "2025-06-25 21:28:41.643700",
"spec_repo_commit": "31044eb9"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2025-06-25 17:36:54.453686",
"spec_repo_commit": "51c17453"
"regenerated": "2025-06-25 21:28:41.660214",
"spec_repo_commit": "31044eb9"
}
}
}
8 changes: 8 additions & 0 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17419,6 +17419,10 @@ components:
items:
$ref: '#/components/schemas/IncidentTimelineCellCreateAttributes'
type: array
is_test:
description: A flag indicating whether the incident is a test incident.
example: false
type: boolean
notification_handles:
description: Notification handles that will be notified of the incident
at creation.
Expand Down Expand Up @@ -17824,6 +17828,10 @@ components:
description: A unique identifier that represents an incident type.
example: 00000000-0000-0000-0000-000000000000
type: string
is_test:
description: A flag indicating whether the incident is a test incident.
example: false
type: boolean
modified:
description: Timestamp when the incident was last modified.
format: date-time
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
IncidentCreateAttributes.JSON_PROPERTY_FIELDS,
IncidentCreateAttributes.JSON_PROPERTY_INCIDENT_TYPE_UUID,
IncidentCreateAttributes.JSON_PROPERTY_INITIAL_CELLS,
IncidentCreateAttributes.JSON_PROPERTY_IS_TEST,
IncidentCreateAttributes.JSON_PROPERTY_NOTIFICATION_HANDLES,
IncidentCreateAttributes.JSON_PROPERTY_TITLE
})
Expand All @@ -48,6 +49,9 @@ public class IncidentCreateAttributes {
public static final String JSON_PROPERTY_INITIAL_CELLS = "initial_cells";
private List<IncidentTimelineCellCreateAttributes> initialCells = null;

public static final String JSON_PROPERTY_IS_TEST = "is_test";
private Boolean isTest;

public static final String JSON_PROPERTY_NOTIFICATION_HANDLES = "notification_handles";
private List<IncidentNotificationHandle> notificationHandles = null;

Expand Down Expand Up @@ -193,6 +197,27 @@ public void setInitialCells(List<IncidentTimelineCellCreateAttributes> initialCe
this.initialCells = initialCells;
}

public IncidentCreateAttributes isTest(Boolean isTest) {
this.isTest = isTest;
return this;
}

/**
* A flag indicating whether the incident is a test incident.
*
* @return isTest
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_IS_TEST)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Boolean getIsTest() {
return isTest;
}

public void setIsTest(Boolean isTest) {
this.isTest = isTest;
}

public IncidentCreateAttributes notificationHandles(
List<IncidentNotificationHandle> notificationHandles) {
this.notificationHandles = notificationHandles;
Expand Down Expand Up @@ -309,6 +334,7 @@ public boolean equals(Object o) {
&& Objects.equals(this.fields, incidentCreateAttributes.fields)
&& Objects.equals(this.incidentTypeUuid, incidentCreateAttributes.incidentTypeUuid)
&& Objects.equals(this.initialCells, incidentCreateAttributes.initialCells)
&& Objects.equals(this.isTest, incidentCreateAttributes.isTest)
&& Objects.equals(this.notificationHandles, incidentCreateAttributes.notificationHandles)
&& Objects.equals(this.title, incidentCreateAttributes.title)
&& Objects.equals(this.additionalProperties, incidentCreateAttributes.additionalProperties);
Expand All @@ -322,6 +348,7 @@ public int hashCode() {
fields,
incidentTypeUuid,
initialCells,
isTest,
notificationHandles,
title,
additionalProperties);
Expand All @@ -338,6 +365,7 @@ public String toString() {
sb.append(" fields: ").append(toIndentedString(fields)).append("\n");
sb.append(" incidentTypeUuid: ").append(toIndentedString(incidentTypeUuid)).append("\n");
sb.append(" initialCells: ").append(toIndentedString(initialCells)).append("\n");
sb.append(" isTest: ").append(toIndentedString(isTest)).append("\n");
sb.append(" notificationHandles: ")
.append(toIndentedString(notificationHandles))
.append("\n");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
IncidentResponseAttributes.JSON_PROPERTY_DETECTED,
IncidentResponseAttributes.JSON_PROPERTY_FIELDS,
IncidentResponseAttributes.JSON_PROPERTY_INCIDENT_TYPE_UUID,
IncidentResponseAttributes.JSON_PROPERTY_IS_TEST,
IncidentResponseAttributes.JSON_PROPERTY_MODIFIED,
IncidentResponseAttributes.JSON_PROPERTY_NON_DATADOG_CREATOR,
IncidentResponseAttributes.JSON_PROPERTY_NOTIFICATION_HANDLES,
Expand Down Expand Up @@ -86,6 +87,9 @@ public class IncidentResponseAttributes {
public static final String JSON_PROPERTY_INCIDENT_TYPE_UUID = "incident_type_uuid";
private String incidentTypeUuid;

public static final String JSON_PROPERTY_IS_TEST = "is_test";
private Boolean isTest;

public static final String JSON_PROPERTY_MODIFIED = "modified";
private OffsetDateTime modified;

Expand Down Expand Up @@ -413,6 +417,27 @@ public void setIncidentTypeUuid(String incidentTypeUuid) {
this.incidentTypeUuid = incidentTypeUuid;
}

public IncidentResponseAttributes isTest(Boolean isTest) {
this.isTest = isTest;
return this;
}

/**
* A flag indicating whether the incident is a test incident.
*
* @return isTest
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_IS_TEST)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Boolean getIsTest() {
return isTest;
}

public void setIsTest(Boolean isTest) {
this.isTest = isTest;
}

/**
* Timestamp when the incident was last modified.
*
Expand Down Expand Up @@ -786,6 +811,7 @@ public boolean equals(Object o) {
&& Objects.equals(this.detected, incidentResponseAttributes.detected)
&& Objects.equals(this.fields, incidentResponseAttributes.fields)
&& Objects.equals(this.incidentTypeUuid, incidentResponseAttributes.incidentTypeUuid)
&& Objects.equals(this.isTest, incidentResponseAttributes.isTest)
&& Objects.equals(this.modified, incidentResponseAttributes.modified)
&& Objects.equals(this.nonDatadogCreator, incidentResponseAttributes.nonDatadogCreator)
&& Objects.equals(this.notificationHandles, incidentResponseAttributes.notificationHandles)
Expand Down Expand Up @@ -818,6 +844,7 @@ public int hashCode() {
detected,
fields,
incidentTypeUuid,
isTest,
modified,
nonDatadogCreator,
notificationHandles,
Expand Down Expand Up @@ -855,6 +882,7 @@ public String toString() {
sb.append(" detected: ").append(toIndentedString(detected)).append("\n");
sb.append(" fields: ").append(toIndentedString(fields)).append("\n");
sb.append(" incidentTypeUuid: ").append(toIndentedString(incidentTypeUuid)).append("\n");
sb.append(" isTest: ").append(toIndentedString(isTest)).append("\n");
sb.append(" modified: ").append(toIndentedString(modified)).append("\n");
sb.append(" nonDatadogCreator: ").append(toIndentedString(nonDatadogCreator)).append("\n");
sb.append(" notificationHandles: ")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ Feature: Incidents
Scenario: Create an incident returns "Bad Request" response
Given operation "CreateIncident" enabled
And new "CreateIncident" request
And body with value {"data": {"attributes": {"customer_impact_scope": "Example customer impact scope", "customer_impacted": false, "fields": {"severity": {"type": "dropdown", "value": "SEV-5"}}, "incident_type_uuid": "00000000-0000-0000-0000-000000000000", "initial_cells": [{"cell_type": "markdown", "content": {"content": "An example timeline cell message."}, "important": false}], "notification_handles": [{"display_name": "Jane Doe", "handle": "@user@email.com"}, {"display_name": "Slack Channel", "handle": "@slack-channel"}, {"display_name": "Incident Workflow", "handle": "@workflow-from-incident"}], "title": "A test incident title"}, "relationships": {"commander_user": {"data": {"id": "00000000-0000-0000-0000-000000000000", "type": "users"}}}, "type": "incidents"}}
And body with value {"data": {"attributes": {"customer_impact_scope": "Example customer impact scope", "customer_impacted": false, "fields": {"severity": {"type": "dropdown", "value": "SEV-5"}}, "incident_type_uuid": "00000000-0000-0000-0000-000000000000", "initial_cells": [{"cell_type": "markdown", "content": {"content": "An example timeline cell message."}, "important": false}], "is_test": false, "notification_handles": [{"display_name": "Jane Doe", "handle": "@user@email.com"}, {"display_name": "Slack Channel", "handle": "@slack-channel"}, {"display_name": "Incident Workflow", "handle": "@workflow-from-incident"}], "title": "A test incident title"}, "relationships": {"commander_user": {"data": {"id": "00000000-0000-0000-0000-000000000000", "type": "users"}}}, "type": "incidents"}}
When the request is sent
Then the response status is 400 Bad Request

Expand All @@ -89,7 +89,7 @@ Feature: Incidents
Scenario: Create an incident returns "Not Found" response
Given operation "CreateIncident" enabled
And new "CreateIncident" request
And body with value {"data": {"attributes": {"customer_impact_scope": "Example customer impact scope", "customer_impacted": false, "fields": {"severity": {"type": "dropdown", "value": "SEV-5"}}, "incident_type_uuid": "00000000-0000-0000-0000-000000000000", "initial_cells": [{"cell_type": "markdown", "content": {"content": "An example timeline cell message."}, "important": false}], "notification_handles": [{"display_name": "Jane Doe", "handle": "@user@email.com"}, {"display_name": "Slack Channel", "handle": "@slack-channel"}, {"display_name": "Incident Workflow", "handle": "@workflow-from-incident"}], "title": "A test incident title"}, "relationships": {"commander_user": {"data": {"id": "00000000-0000-0000-0000-000000000000", "type": "users"}}}, "type": "incidents"}}
And body with value {"data": {"attributes": {"customer_impact_scope": "Example customer impact scope", "customer_impacted": false, "fields": {"severity": {"type": "dropdown", "value": "SEV-5"}}, "incident_type_uuid": "00000000-0000-0000-0000-000000000000", "initial_cells": [{"cell_type": "markdown", "content": {"content": "An example timeline cell message."}, "important": false}], "is_test": false, "notification_handles": [{"display_name": "Jane Doe", "handle": "@user@email.com"}, {"display_name": "Slack Channel", "handle": "@slack-channel"}, {"display_name": "Incident Workflow", "handle": "@workflow-from-incident"}], "title": "A test incident title"}, "relationships": {"commander_user": {"data": {"id": "00000000-0000-0000-0000-000000000000", "type": "users"}}}, "type": "incidents"}}
When the request is sent
Then the response status is 404 Not Found

Expand Down