Skip to content
Open
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
40 changes: 40 additions & 0 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28684,6 +28684,19 @@ components:
type: string
x-enum-varnames:
- INCIDENT_ATTACHMENTS
IncidentCondition:
description: A condition evaluated against incident tags.
properties:
tags:
description: Tags that must match for the condition to pass.
example:
- ''
items:
type: string
type: array
required:
- tags
type: object
IncidentCreateAttributes:
description: The incident's attributes for a create request.
properties:
Expand Down Expand Up @@ -30203,6 +30216,32 @@ components:
user_defined_fields:
$ref: '#/components/schemas/RelationshipToIncidentUserDefinedFields'
type: object
IncidentScheduleTrigger:
description: Trigger a workflow from an Incident Schedule. The workflow must
be published.
properties:
incidentType:
description: Incident type filter for the schedule.
type: string
rrule:
description: Recurrence rule expression for scheduling.
example: ''
type: string
tagCondition:
$ref: '#/components/schemas/IncidentCondition'
required:
- rrule
type: object
IncidentScheduleTriggerWrapper:
description: Schema for an Incident Schedule-based trigger.
properties:
incidentScheduleTrigger:
$ref: '#/components/schemas/IncidentScheduleTrigger'
startStepNames:
$ref: '#/components/schemas/StartStepNames'
required:
- incidentScheduleTrigger
type: object
IncidentSearchResponse:
description: Response with incidents and facets.
properties:
Expand Down Expand Up @@ -65465,6 +65504,7 @@ components:
- $ref: '#/components/schemas/DashboardTriggerWrapper'
- $ref: '#/components/schemas/GithubWebhookTriggerWrapper'
- $ref: '#/components/schemas/IncidentTriggerWrapper'
- $ref: '#/components/schemas/IncidentScheduleTriggerWrapper'
- $ref: '#/components/schemas/MonitorTriggerWrapper'
- $ref: '#/components/schemas/NotebookTriggerWrapper'
- $ref: '#/components/schemas/OnCallTriggerWrapper'
Expand Down
3 changes: 3 additions & 0 deletions packages/datadog-api-client-v2/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2879,6 +2879,7 @@ export { HTTPTokenAuthType } from "./models/HTTPTokenAuthType";
export { HTTPTokenAuthUpdate } from "./models/HTTPTokenAuthUpdate";
export { HTTPTokenUpdate } from "./models/HTTPTokenUpdate";
export { IncidentAttachmentType } from "./models/IncidentAttachmentType";
export { IncidentCondition } from "./models/IncidentCondition";
export { IncidentCreateAttributes } from "./models/IncidentCreateAttributes";
export { IncidentCreateData } from "./models/IncidentCreateData";
export { IncidentCreateRelationships } from "./models/IncidentCreateRelationships";
Expand Down Expand Up @@ -2970,6 +2971,8 @@ export { IncidentResponseIncludedItem } from "./models/IncidentResponseIncludedI
export { IncidentResponseMeta } from "./models/IncidentResponseMeta";
export { IncidentResponseMetaPagination } from "./models/IncidentResponseMetaPagination";
export { IncidentResponseRelationships } from "./models/IncidentResponseRelationships";
export { IncidentScheduleTrigger } from "./models/IncidentScheduleTrigger";
export { IncidentScheduleTriggerWrapper } from "./models/IncidentScheduleTriggerWrapper";
export { IncidentSearchResponse } from "./models/IncidentSearchResponse";
export { IncidentSearchResponseAttributes } from "./models/IncidentSearchResponseAttributes";
export { IncidentSearchResponseData } from "./models/IncidentSearchResponseData";
Expand Down
53 changes: 53 additions & 0 deletions packages/datadog-api-client-v2/models/IncidentCondition.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/**
* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
* This product includes software developed at Datadog (https://www.datadoghq.com/).
* Copyright 2020-Present Datadog, Inc.
*/

import { AttributeTypeMap } from "../../datadog-api-client-common/util";

/**
* A condition evaluated against incident tags.
*/
export class IncidentCondition {
/**
* Tags that must match for the condition to pass.
*/
"tags": Array<string>;

/**
* A container for additional, undeclared properties.
* This is a holder for any undeclared properties as specified with
* the 'additionalProperties' keyword in the OAS document.
*/
"additionalProperties"?: { [key: string]: any };

/**
* @ignore
*/
"_unparsed"?: boolean;

/**
* @ignore
*/
static readonly attributeTypeMap: AttributeTypeMap = {
tags: {
baseName: "tags",
type: "Array<string>",
required: true,
},
additionalProperties: {
baseName: "additionalProperties",
type: "{ [key: string]: any; }",
},
};

/**
* @ignore
*/
static getAttributeTypeMap(): AttributeTypeMap {
return IncidentCondition.attributeTypeMap;
}

public constructor() {}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
/**
* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
* This product includes software developed at Datadog (https://www.datadoghq.com/).
* Copyright 2020-Present Datadog, Inc.
*/
import { IncidentCondition } from "./IncidentCondition";

import { AttributeTypeMap } from "../../datadog-api-client-common/util";

/**
* Trigger a workflow from an Incident Schedule. The workflow must be published.
*/
export class IncidentScheduleTrigger {
/**
* Incident type filter for the schedule.
*/
"incidentType"?: string;
/**
* Recurrence rule expression for scheduling.
*/
"rrule": string;
/**
* A condition evaluated against incident tags.
*/
"tagCondition"?: IncidentCondition;

/**
* A container for additional, undeclared properties.
* This is a holder for any undeclared properties as specified with
* the 'additionalProperties' keyword in the OAS document.
*/
"additionalProperties"?: { [key: string]: any };

/**
* @ignore
*/
"_unparsed"?: boolean;

/**
* @ignore
*/
static readonly attributeTypeMap: AttributeTypeMap = {
incidentType: {
baseName: "incidentType",
type: "string",
},
rrule: {
baseName: "rrule",
type: "string",
required: true,
},
tagCondition: {
baseName: "tagCondition",
type: "IncidentCondition",
},
additionalProperties: {
baseName: "additionalProperties",
type: "{ [key: string]: any; }",
},
};

/**
* @ignore
*/
static getAttributeTypeMap(): AttributeTypeMap {
return IncidentScheduleTrigger.attributeTypeMap;
}

public constructor() {}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
/**
* Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
* This product includes software developed at Datadog (https://www.datadoghq.com/).
* Copyright 2020-Present Datadog, Inc.
*/
import { IncidentScheduleTrigger } from "./IncidentScheduleTrigger";

import { AttributeTypeMap } from "../../datadog-api-client-common/util";

/**
* Schema for an Incident Schedule-based trigger.
*/
export class IncidentScheduleTriggerWrapper {
/**
* Trigger a workflow from an Incident Schedule. The workflow must be published.
*/
"incidentScheduleTrigger": IncidentScheduleTrigger;
/**
* A list of steps that run first after a trigger fires.
*/
"startStepNames"?: Array<string>;

/**
* A container for additional, undeclared properties.
* This is a holder for any undeclared properties as specified with
* the 'additionalProperties' keyword in the OAS document.
*/
"additionalProperties"?: { [key: string]: any };

/**
* @ignore
*/
"_unparsed"?: boolean;

/**
* @ignore
*/
static readonly attributeTypeMap: AttributeTypeMap = {
incidentScheduleTrigger: {
baseName: "incidentScheduleTrigger",
type: "IncidentScheduleTrigger",
required: true,
},
startStepNames: {
baseName: "startStepNames",
type: "Array<string>",
},
additionalProperties: {
baseName: "additionalProperties",
type: "{ [key: string]: any; }",
},
};

/**
* @ignore
*/
static getAttributeTypeMap(): AttributeTypeMap {
return IncidentScheduleTriggerWrapper.attributeTypeMap;
}

public constructor() {}
}
7 changes: 7 additions & 0 deletions packages/datadog-api-client-v2/models/ObjectSerializer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1332,6 +1332,7 @@ import { IPAllowlistEntryAttributes } from "./IPAllowlistEntryAttributes";
import { IPAllowlistEntryData } from "./IPAllowlistEntryData";
import { IPAllowlistResponse } from "./IPAllowlistResponse";
import { IPAllowlistUpdateRequest } from "./IPAllowlistUpdateRequest";
import { IncidentCondition } from "./IncidentCondition";
import { IncidentCreateAttributes } from "./IncidentCreateAttributes";
import { IncidentCreateData } from "./IncidentCreateData";
import { IncidentCreateRelationships } from "./IncidentCreateRelationships";
Expand Down Expand Up @@ -1401,6 +1402,8 @@ import { IncidentResponseData } from "./IncidentResponseData";
import { IncidentResponseMeta } from "./IncidentResponseMeta";
import { IncidentResponseMetaPagination } from "./IncidentResponseMetaPagination";
import { IncidentResponseRelationships } from "./IncidentResponseRelationships";
import { IncidentScheduleTrigger } from "./IncidentScheduleTrigger";
import { IncidentScheduleTriggerWrapper } from "./IncidentScheduleTriggerWrapper";
import { IncidentSearchResponse } from "./IncidentSearchResponse";
import { IncidentSearchResponseAttributes } from "./IncidentSearchResponseAttributes";
import { IncidentSearchResponseData } from "./IncidentSearchResponseData";
Expand Down Expand Up @@ -6795,6 +6798,7 @@ const typeMap: { [index: string]: any } = {
IPAllowlistEntryData: IPAllowlistEntryData,
IPAllowlistResponse: IPAllowlistResponse,
IPAllowlistUpdateRequest: IPAllowlistUpdateRequest,
IncidentCondition: IncidentCondition,
IncidentCreateAttributes: IncidentCreateAttributes,
IncidentCreateData: IncidentCreateData,
IncidentCreateRelationships: IncidentCreateRelationships,
Expand Down Expand Up @@ -6880,6 +6884,8 @@ const typeMap: { [index: string]: any } = {
IncidentResponseMeta: IncidentResponseMeta,
IncidentResponseMetaPagination: IncidentResponseMetaPagination,
IncidentResponseRelationships: IncidentResponseRelationships,
IncidentScheduleTrigger: IncidentScheduleTrigger,
IncidentScheduleTriggerWrapper: IncidentScheduleTriggerWrapper,
IncidentSearchResponse: IncidentSearchResponse,
IncidentSearchResponseAttributes: IncidentSearchResponseAttributes,
IncidentSearchResponseData: IncidentSearchResponseData,
Expand Down Expand Up @@ -9682,6 +9688,7 @@ const oneOfMap: { [index: string]: string[] } = {
"DashboardTriggerWrapper",
"GithubWebhookTriggerWrapper",
"IncidentTriggerWrapper",
"IncidentScheduleTriggerWrapper",
"MonitorTriggerWrapper",
"NotebookTriggerWrapper",
"OnCallTriggerWrapper",
Expand Down
2 changes: 2 additions & 0 deletions packages/datadog-api-client-v2/models/Trigger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { DashboardTriggerWrapper } from "./DashboardTriggerWrapper";
import { DatabaseMonitoringTriggerWrapper } from "./DatabaseMonitoringTriggerWrapper";
import { DatastoreTriggerWrapper } from "./DatastoreTriggerWrapper";
import { GithubWebhookTriggerWrapper } from "./GithubWebhookTriggerWrapper";
import { IncidentScheduleTriggerWrapper } from "./IncidentScheduleTriggerWrapper";
import { IncidentTriggerWrapper } from "./IncidentTriggerWrapper";
import { MonitorTriggerWrapper } from "./MonitorTriggerWrapper";
import { NotebookTriggerWrapper } from "./NotebookTriggerWrapper";
Expand Down Expand Up @@ -38,6 +39,7 @@ export type Trigger =
| DashboardTriggerWrapper
| GithubWebhookTriggerWrapper
| IncidentTriggerWrapper
| IncidentScheduleTriggerWrapper
| MonitorTriggerWrapper
| NotebookTriggerWrapper
| OnCallTriggerWrapper
Expand Down
Loading