Skip to content

Commit ee5350a

Browse files
committed
fix required status for ScheduledAlertRuleCommonProperties and Page<T> models
1 parent 7c5a495 commit ee5350a

3 files changed

Lines changed: 155 additions & 66 deletions

File tree

specification/securityinsights/resource-manager/Microsoft.SecurityInsights/SecurityInsights/models.tsp

Lines changed: 75 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4042,7 +4042,19 @@ model ClientInfo {
40424042
}
40434043

40444044
#suppress "@azure-tools/typespec-azure-core/documentation-required" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
4045-
model AutomationRulesList is Azure.Core.Page<AutomationRule>;
4045+
model AutomationRulesList {
4046+
/**
4047+
* List of automation rules.
4048+
*/
4049+
@pageItems
4050+
value?: AutomationRule[];
4051+
4052+
/**
4053+
* The link to the next page of items
4054+
*/
4055+
@nextLink
4056+
nextLink?: string;
4057+
}
40464058

40474059
/**
40484060
* Describes the request body for triggering a playbook on an entity.
@@ -4963,8 +4975,19 @@ model TemplateAdditionalProperties {
49634975
/**
49644976
* Encapsulate the data connector definition object
49654977
*/
4966-
model DataConnectorDefinitionArmCollectionWrapper
4967-
is Azure.Core.Page<DataConnectorDefinition>;
4978+
model DataConnectorDefinitionArmCollectionWrapper {
4979+
/**
4980+
* List of data connector definitions.
4981+
*/
4982+
@pageItems
4983+
value?: DataConnectorDefinition[];
4984+
4985+
/**
4986+
* The link to the next page of items
4987+
*/
4988+
@nextLink
4989+
nextLink?: string;
4990+
}
49684991

49694992
/**
49704993
* List all the data connectors.
@@ -6737,7 +6760,19 @@ model IncidentEntitiesResultsMetadata {
67376760
/**
67386761
* List of incident tasks
67396762
*/
6740-
model IncidentTaskList is Azure.Core.Page<IncidentTask>;
6763+
model IncidentTaskList {
6764+
/**
6765+
* List of incident tasks.
6766+
*/
6767+
@pageItems
6768+
value?: IncidentTask[];
6769+
6770+
/**
6771+
* The link to the next page of items
6772+
*/
6773+
@nextLink
6774+
nextLink?: string;
6775+
}
67416776

67426777
/**
67436778
* Describes the properties of an incident task
@@ -9720,6 +9755,36 @@ model MicrosoftSecurityIncidentCreationAlertRuleTemplateProperties
97209755
*/
97219756
#suppress "@azure-tools/typespec-azure-core/composition-over-inheritance" "FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
97229757
model ScheduledAlertRuleProperties extends ScheduledAlertRuleCommonProperties {
9758+
/**
9759+
* The query that creates alerts for this rule.
9760+
*/
9761+
query: string;
9762+
9763+
/**
9764+
* The frequency (in ISO 8601 duration format) for this alert rule to run.
9765+
*/
9766+
queryFrequency: duration;
9767+
9768+
/**
9769+
* The period (in ISO 8601 duration format) that this alert rule looks at.
9770+
*/
9771+
queryPeriod: duration;
9772+
9773+
/**
9774+
* The severity for alerts created by this alert rule.
9775+
*/
9776+
severity: AlertSeverity;
9777+
9778+
/**
9779+
* The operation against the threshold that triggers alert rule.
9780+
*/
9781+
triggerOperator: TriggerOperator;
9782+
9783+
/**
9784+
* The threshold triggers this alert rule.
9785+
*/
9786+
triggerThreshold: int32;
9787+
97239788
/**
97249789
* The Name of the alert rule template used to create this rule.
97259790
*/
@@ -9846,32 +9911,32 @@ model ScheduledAlertRuleCommonProperties {
98469911
/**
98479912
* The query that creates alerts for this rule.
98489913
*/
9849-
query: string;
9914+
query?: string;
98509915

98519916
/**
98529917
* The frequency (in ISO 8601 duration format) for this alert rule to run.
98539918
*/
9854-
queryFrequency: duration;
9919+
queryFrequency?: duration;
98559920

98569921
/**
98579922
* The period (in ISO 8601 duration format) that this alert rule looks at.
98589923
*/
9859-
queryPeriod: duration;
9924+
queryPeriod?: duration;
98609925

98619926
/**
98629927
* The severity for alerts created by this alert rule.
98639928
*/
9864-
severity: AlertSeverity;
9929+
severity?: AlertSeverity;
98659930

98669931
/**
98679932
* The operation against the threshold that triggers alert rule.
98689933
*/
9869-
triggerOperator: TriggerOperator;
9934+
triggerOperator?: TriggerOperator;
98709935

98719936
/**
98729937
* The threshold triggers this alert rule.
98739938
*/
9874-
triggerThreshold: int32;
9939+
triggerThreshold?: int32;
98759940

98769941
/**
98779942
* The event grouping settings.

specification/securityinsights/resource-manager/Microsoft.SecurityInsights/SecurityInsights/preview/2025-10-01-preview/openapi.json

Lines changed: 40 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -14119,24 +14119,19 @@
1411914119
},
1412014120
"AutomationRulesList": {
1412114121
"type": "object",
14122-
"description": "Paged collection of AutomationRule items",
1412314122
"properties": {
1412414123
"value": {
1412514124
"type": "array",
14126-
"description": "The AutomationRule items on this page",
14125+
"description": "List of automation rules.",
1412714126
"items": {
1412814127
"$ref": "#/definitions/AutomationRule"
1412914128
}
1413014129
},
1413114130
"nextLink": {
1413214131
"type": "string",
14133-
"format": "uri",
1413414132
"description": "The link to the next page of items"
1413514133
}
14136-
},
14137-
"required": [
14138-
"value"
14139-
]
14134+
}
1414014135
},
1414114136
"Availability": {
1414214137
"type": "object",
@@ -16249,20 +16244,16 @@
1624916244
"properties": {
1625016245
"value": {
1625116246
"type": "array",
16252-
"description": "The DataConnectorDefinition items on this page",
16247+
"description": "List of data connector definitions.",
1625316248
"items": {
1625416249
"$ref": "#/definitions/DataConnectorDefinition"
1625516250
}
1625616251
},
1625716252
"nextLink": {
1625816253
"type": "string",
16259-
"format": "uri",
1626016254
"description": "The link to the next page of items"
1626116255
}
16262-
},
16263-
"required": [
16264-
"value"
16265-
]
16256+
}
1626616257
},
1626716258
"DataConnectorDefinitionKind": {
1626816259
"type": "string",
@@ -21042,20 +21033,16 @@
2104221033
"properties": {
2104321034
"value": {
2104421035
"type": "array",
21045-
"description": "The IncidentTask items on this page",
21036+
"description": "List of incident tasks.",
2104621037
"items": {
2104721038
"$ref": "#/definitions/IncidentTask"
2104821039
}
2104921040
},
2105021041
"nextLink": {
2105121042
"type": "string",
21052-
"format": "uri",
2105321043
"description": "The link to the next page of items"
2105421044
}
21055-
},
21056-
"required": [
21057-
"value"
21058-
]
21045+
}
2105921046
},
2106021047
"IncidentTaskProperties": {
2106121048
"type": "object",
@@ -26629,20 +26616,39 @@
2662926616
"$ref": "#/definitions/SentinelEntityMapping"
2663026617
}
2663126618
}
26632-
},
26633-
"required": [
26634-
"query",
26635-
"queryFrequency",
26636-
"queryPeriod",
26637-
"severity",
26638-
"triggerOperator",
26639-
"triggerThreshold"
26640-
]
26619+
}
2664126620
},
2664226621
"ScheduledAlertRuleProperties": {
2664326622
"type": "object",
2664426623
"description": "Scheduled alert rule base property bag.",
2664526624
"properties": {
26625+
"query": {
26626+
"type": "string",
26627+
"description": "The query that creates alerts for this rule."
26628+
},
26629+
"queryFrequency": {
26630+
"type": "string",
26631+
"format": "duration",
26632+
"description": "The frequency (in ISO 8601 duration format) for this alert rule to run."
26633+
},
26634+
"queryPeriod": {
26635+
"type": "string",
26636+
"format": "duration",
26637+
"description": "The period (in ISO 8601 duration format) that this alert rule looks at."
26638+
},
26639+
"severity": {
26640+
"$ref": "#/definitions/AlertSeverity",
26641+
"description": "The severity for alerts created by this alert rule."
26642+
},
26643+
"triggerOperator": {
26644+
"$ref": "#/definitions/TriggerOperator",
26645+
"description": "The operation against the threshold that triggers alert rule."
26646+
},
26647+
"triggerThreshold": {
26648+
"type": "integer",
26649+
"format": "int32",
26650+
"description": "The threshold triggers this alert rule."
26651+
},
2664626652
"alertRuleTemplateName": {
2664726653
"type": "string",
2664826654
"description": "The Name of the alert rule template used to create this rule."
@@ -26705,6 +26711,12 @@
2670526711
}
2670626712
},
2670726713
"required": [
26714+
"query",
26715+
"queryFrequency",
26716+
"queryPeriod",
26717+
"severity",
26718+
"triggerOperator",
26719+
"triggerThreshold",
2670826720
"displayName",
2670926721
"enabled",
2671026722
"suppressionDuration",

0 commit comments

Comments
 (0)