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
31 changes: 26 additions & 5 deletions docs/openapi/monitoring-api.json
Original file line number Diff line number Diff line change
Expand Up @@ -25631,24 +25631,24 @@
},
"triggeringCheckId": {
"type": "string",
"description": "Scheduler-minted check execution ID whose result confirmed this incident; joins to check_results, rule_evaluations, and incident_state_transitions",
"description": "Scheduler-minted check execution ID whose result confirmed this incident; joins to check_results, rule_evaluations, and incident_state_transitions. Omitted from JSON (undefined to SDKs) when null, treat missing as null.",
"format": "uuid",
"nullable": true
},
"triggeredByRuleSnapshotHashHex": {
"type": "string",
"description": "Hex SHA-256 of the canonical policy snapshot that fired; combined with triggeredByRuleIndex points to the exact TriggerRule",
"description": "Hex SHA-256 of the canonical policy snapshot that fired; combined with triggeredByRuleIndex points to the exact TriggerRule. Omitted from JSON when null, treat missing as null.",
"nullable": true
},
"triggeredByRuleIndex": {
"type": "integer",
"description": "Index of the fired rule inside the policy's trigger_rules array",
"description": "Index of the fired rule inside the policy's trigger_rules array. Omitted from JSON when null, treat missing as null.",
"format": "int32",
"nullable": true
},
"engineVersion": {
"type": "string",
"description": "Detection engine semver that evaluated the rule",
"description": "Detection engine semver that evaluated the rule. Omitted from JSON when null, treat missing as null.",
"nullable": true
}
},
Expand Down Expand Up @@ -25864,6 +25864,7 @@
"required": [
"affectedRegions",
"checkId",
"details",
"engineVersion",
"fromStatus",
"id",
Expand Down Expand Up @@ -25910,7 +25911,7 @@
"reason": {
"minLength": 1,
"type": "string",
"description": "Why the transition fired (rule_matched | confirmation_met | auto_cleared_by_timeout | recovery_met | reopened | manually_resolved | policy_changed)"
"description": "Why the transition fired (trigger | confirm | resolve | auto_clear | reopen)"
},
"triggeringEvaluationIds": {
"type": "array",
Expand Down Expand Up @@ -25943,6 +25944,9 @@
"type": "string",
"description": "Scheduler-minted check execution ID (V92) of the triggering result",
"format": "uuid"
},
"details": {
"$ref": "#/components/schemas/StateTransitionDetails"
}
},
"description": "State-machine transitions this check caused (may be empty if nothing fired)"
Expand Down Expand Up @@ -30579,6 +30583,23 @@
"minDaysRemaining"
]
},
"StateTransitionDetails": {
"required": [
"source"
],
"type": "object",
"properties": {
"source": {
"type": "string",
"description": "Actor that produced this transition (pipeline | public-api)",
"enum": [
"pipeline",
"public-api"
]
}
},
"description": "Typed metadata about this transition (currently: actor source)"
},
"StatusCodeAssertion": {
"required": [
"type",
Expand Down
5 changes: 5 additions & 0 deletions src/lib/api-zod.generated.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1644,6 +1644,9 @@ const RuleEvaluationDto = z
triggeringTransitionId: z.string().uuid().nullish(),
})
.strict();
const StateTransitionDetails = z
.object({ source: z.enum(["pipeline", "public-api"]) })
.strict();
const IncidentStateTransitionDto = z
.object({
id: z.string().uuid(),
Expand All @@ -1658,6 +1661,7 @@ const IncidentStateTransitionDto = z
policySnapshotHashHex: z.string().min(1),
engineVersion: z.string().min(1),
checkId: z.string().uuid(),
details: StateTransitionDetails,
})
.strict();
const PolicySnapshotDto = z
Expand Down Expand Up @@ -3479,6 +3483,7 @@ export const schemas = {
CheckResultDetailsDto,
CheckResultDto,
RuleEvaluationDto,
StateTransitionDetails,
IncidentStateTransitionDto,
PolicySnapshotDto,
CheckTraceDto,
Expand Down
19 changes: 14 additions & 5 deletions src/lib/api.generated.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4245,17 +4245,17 @@ export interface components {
resourceGroupName?: string | null;
/**
* Format: uuid
* @description Scheduler-minted check execution ID whose result confirmed this incident; joins to check_results, rule_evaluations, and incident_state_transitions
* @description Scheduler-minted check execution ID whose result confirmed this incident; joins to check_results, rule_evaluations, and incident_state_transitions. Omitted from JSON (undefined to SDKs) when null, treat missing as null.
*/
triggeringCheckId?: string | null;
/** @description Hex SHA-256 of the canonical policy snapshot that fired; combined with triggeredByRuleIndex points to the exact TriggerRule */
/** @description Hex SHA-256 of the canonical policy snapshot that fired; combined with triggeredByRuleIndex points to the exact TriggerRule. Omitted from JSON when null, treat missing as null. */
triggeredByRuleSnapshotHashHex?: string | null;
/**
* Format: int32
* @description Index of the fired rule inside the policy's trigger_rules array
* @description Index of the fired rule inside the policy's trigger_rules array. Omitted from JSON when null, treat missing as null.
*/
triggeredByRuleIndex?: number | null;
/** @description Detection engine semver that evaluated the rule */
/** @description Detection engine semver that evaluated the rule. Omitted from JSON when null, treat missing as null. */
engineVersion?: string | null;
};
IncidentFilterParams: {
Expand Down Expand Up @@ -4406,7 +4406,7 @@ export interface components {
fromStatus: string;
/** @description New status (WATCHING | TRIGGERED | CONFIRMED | RESOLVED) */
toStatus: string;
/** @description Why the transition fired (rule_matched | confirmation_met | auto_cleared_by_timeout | recovery_met | reopened | manually_resolved | policy_changed) */
/** @description Why the transition fired (trigger | confirm | resolve | auto_clear | reopen) */
reason: string;
/** @description rule_evaluation ids that caused this transition (may be empty for timeout-driven edges) */
triggeringEvaluationIds: string[];
Expand All @@ -4421,6 +4421,7 @@ export interface components {
* @description Scheduler-minted check execution ID (V92) of the triggering result
*/
checkId: string;
details: components["schemas"]["StateTransitionDetails"];
};
IncidentTimelineDto: {
/** @description State-machine transitions in chronological order */
Expand Down Expand Up @@ -6308,6 +6309,14 @@ export interface components {
*/
minDaysRemaining: number;
};
/** @description Typed metadata about this transition (currently: actor source) */
StateTransitionDetails: {
/**
* @description Actor that produced this transition (pipeline | public-api)
* @enum {string}
*/
source: "pipeline" | "public-api";
};
StatusCodeAssertion: {
/** @enum {string} */
type: "status_code";
Expand Down
Loading