diff --git a/sdk/security/arm-security/src/models/adaptiveNetworkHardeningsMappers.ts b/sdk/security/arm-security/src/models/adaptiveNetworkHardeningsMappers.ts index 46541e70b995..8ff97a56e434 100644 --- a/sdk/security/arm-security/src/models/adaptiveNetworkHardeningsMappers.ts +++ b/sdk/security/arm-security/src/models/adaptiveNetworkHardeningsMappers.ts @@ -58,6 +58,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/advancedThreatProtectionMappers.ts b/sdk/security/arm-security/src/models/advancedThreatProtectionMappers.ts index 57b62d85cd0f..ca03e5513848 100644 --- a/sdk/security/arm-security/src/models/advancedThreatProtectionMappers.ts +++ b/sdk/security/arm-security/src/models/advancedThreatProtectionMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/alertsMappers.ts b/sdk/security/arm-security/src/models/alertsMappers.ts index e208182bbc0e..3af0127cd00a 100644 --- a/sdk/security/arm-security/src/models/alertsMappers.ts +++ b/sdk/security/arm-security/src/models/alertsMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/alertsSuppressionRulesMappers.ts b/sdk/security/arm-security/src/models/alertsSuppressionRulesMappers.ts index 63ed49f6e6ca..47fe0e0bf7ce 100644 --- a/sdk/security/arm-security/src/models/alertsSuppressionRulesMappers.ts +++ b/sdk/security/arm-security/src/models/alertsSuppressionRulesMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/assessmentsMappers.ts b/sdk/security/arm-security/src/models/assessmentsMappers.ts index 5315f3c6ed6c..80c5f7491828 100644 --- a/sdk/security/arm-security/src/models/assessmentsMappers.ts +++ b/sdk/security/arm-security/src/models/assessmentsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/assessmentsMetadataMappers.ts b/sdk/security/arm-security/src/models/assessmentsMetadataMappers.ts index 4cef417b5ca2..80aab627947a 100644 --- a/sdk/security/arm-security/src/models/assessmentsMetadataMappers.ts +++ b/sdk/security/arm-security/src/models/assessmentsMetadataMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/autoProvisioningSettingsMappers.ts b/sdk/security/arm-security/src/models/autoProvisioningSettingsMappers.ts index 960c9ec0da7b..9192777b18f0 100644 --- a/sdk/security/arm-security/src/models/autoProvisioningSettingsMappers.ts +++ b/sdk/security/arm-security/src/models/autoProvisioningSettingsMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/complianceResultsMappers.ts b/sdk/security/arm-security/src/models/complianceResultsMappers.ts index 5c64a192424f..fdfa5229de8c 100644 --- a/sdk/security/arm-security/src/models/complianceResultsMappers.ts +++ b/sdk/security/arm-security/src/models/complianceResultsMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/compliancesMappers.ts b/sdk/security/arm-security/src/models/compliancesMappers.ts index 8465c66398c2..e68314ab0282 100644 --- a/sdk/security/arm-security/src/models/compliancesMappers.ts +++ b/sdk/security/arm-security/src/models/compliancesMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/connectorsMappers.ts b/sdk/security/arm-security/src/models/connectorsMappers.ts index cc276f3a59bf..b269efb362dd 100644 --- a/sdk/security/arm-security/src/models/connectorsMappers.ts +++ b/sdk/security/arm-security/src/models/connectorsMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/deviceSecurityGroupsMappers.ts b/sdk/security/arm-security/src/models/deviceSecurityGroupsMappers.ts index 450a6b58c2dc..86af1b3b23a3 100644 --- a/sdk/security/arm-security/src/models/deviceSecurityGroupsMappers.ts +++ b/sdk/security/arm-security/src/models/deviceSecurityGroupsMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/index.ts b/sdk/security/arm-security/src/models/index.ts index 78496174c4a7..0dd81c8f9966 100644 --- a/sdk/security/arm-security/src/models/index.ts +++ b/sdk/security/arm-security/src/models/index.ts @@ -1793,6 +1793,16 @@ export interface IotAlertType extends Resource { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly providerName?: string; + /** + * The name of the product which published this alert + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly productName?: string; + /** + * The name of a component inside the product which generated the alert + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly productComponentName?: string; /** * The name of the vendor that raise the alert * **NOTE: This property will not be serialized. It can only be populated by the server.** @@ -1865,6 +1875,93 @@ export interface IotAlert { extendedProperties?: any; } +/** + * IoT recommendation type. + */ +export interface IotRecommendationType extends Resource { + /** + * The display name of the recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly recommendationDisplayName?: string; + /** + * The severity of the recommendation. Possible values include: 'Unknown', 'NotApplicable', + * 'Healthy', 'OffByPolicy', 'Low', 'Medium', 'High' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly severity?: RecommendationSeverity; + /** + * Description of the suspected vulnerability and meaning. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly description?: string; + /** + * The name of the product which published this recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly productName?: string; + /** + * The name of a component inside the product which generated the recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly productComponentName?: string; + /** + * The name of the vendor that raised the recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly vendorName?: string; + /** + * The name of the recommendation's control category + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly control?: string; + /** + * Manual action items to take to resolve the recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly remediationSteps?: string[]; + /** + * The alert's data source + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly dataSource?: string; +} + +/** + * List of recommendation types + */ +export interface IotRecommendationTypeList { + /** + * List data + */ + value?: IotRecommendationType[]; +} + +/** + * IoT recommendation + */ +export interface IotRecommendation extends Resource { + /** + * Identifier of the device being reported on + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deviceId?: string; + /** + * The type name of the recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly recommendationType?: string; + /** + * The discovery time of the recommendation + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly discoveredTimeUtc?: string; + /** + * A bag of fields which extends the recommendation information + */ + recommendationAdditionalData?: any; +} + /** * Security operation display */ @@ -4540,6 +4637,24 @@ export interface IotAlertsListOptionalParams extends msRest.RequestOptionsBase { skipToken?: string; } +/** + * Optional Parameters. + */ +export interface IotRecommendationsListOptionalParams extends msRest.RequestOptionsBase { + /** + * Filter by recommendation type + */ + recommendationType?: string; + /** + * Limit the number of items returned in a single page + */ + limit?: number; + /** + * Skip token used for pagination + */ + skipToken?: string; +} + /** * Optional Parameters. */ @@ -4770,6 +4885,25 @@ export interface IotAlertList extends Array { readonly totalCount?: number; } +/** + * @interface + * List of IoT recommendations + * @extends Array + */ +export interface IotRecommendationList extends Array { + /** + * When available, follow the URI to get the next page of data + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; + /** + * Total count of recommendations that conforms with the given filter options (not affected by + * page size) + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalCount?: number; +} + /** * @interface * List of locations where ASC saves your data @@ -5224,6 +5358,15 @@ export type AlertSeverity = 'Informational' | 'Low' | 'Medium' | 'High'; */ export type AlertIntent = 'Unknown' | 'PreAttack' | 'InitialAccess' | 'Persistence' | 'PrivilegeEscalation' | 'DefenseEvasion' | 'CredentialAccess' | 'Discovery' | 'LateralMovement' | 'Execution' | 'Collection' | 'Exfiltration' | 'CommandAndControl' | 'Impact' | 'Probing' | 'Exploitation'; +/** + * Defines values for RecommendationSeverity. + * Possible values include: 'Unknown', 'NotApplicable', 'Healthy', 'OffByPolicy', 'Low', 'Medium', + * 'High' + * @readonly + * @enum {string} + */ +export type RecommendationSeverity = 'Unknown' | 'NotApplicable' | 'Healthy' | 'OffByPolicy' | 'Low' | 'Medium' | 'High'; + /** * Defines values for AutoProvision. * Possible values include: 'On', 'Off' @@ -6608,6 +6751,106 @@ export type IotAlertsListNextResponse = IotAlertList & { }; }; +/** + * Contains response data for the list operation. + */ +export type IotRecommendationTypesListResponse = IotRecommendationTypeList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: IotRecommendationTypeList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type IotRecommendationTypesGetResponse = IotRecommendationType & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: IotRecommendationType; + }; +}; + +/** + * Contains response data for the list operation. + */ +export type IotRecommendationsListResponse = IotRecommendationList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: IotRecommendationList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type IotRecommendationsGetResponse = IotRecommendation & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: IotRecommendation; + }; +}; + +/** + * Contains response data for the listNext operation. + */ +export type IotRecommendationsListNextResponse = IotRecommendationList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: IotRecommendationList; + }; +}; + /** * Contains response data for the list operation. */ diff --git a/sdk/security/arm-security/src/models/informationProtectionPoliciesMappers.ts b/sdk/security/arm-security/src/models/informationProtectionPoliciesMappers.ts index ffeaf738a674..2900f4fcd0c5 100644 --- a/sdk/security/arm-security/src/models/informationProtectionPoliciesMappers.ts +++ b/sdk/security/arm-security/src/models/informationProtectionPoliciesMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicyList, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/iotAlertTypesMappers.ts b/sdk/security/arm-security/src/models/iotAlertTypesMappers.ts index abb77a2825c0..50abc6b408db 100644 --- a/sdk/security/arm-security/src/models/iotAlertTypesMappers.ts +++ b/sdk/security/arm-security/src/models/iotAlertTypesMappers.ts @@ -57,6 +57,8 @@ export { InformationType, IotAlertType, IotAlertTypeList, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/iotRecommendationTypesMappers.ts b/sdk/security/arm-security/src/models/iotRecommendationTypesMappers.ts new file mode 100644 index 000000000000..163c66584cac --- /dev/null +++ b/sdk/security/arm-security/src/models/iotRecommendationTypesMappers.ts @@ -0,0 +1,113 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + ActiveConnectionsNotInAllowedRange, + AdaptiveNetworkHardening, + AdditionalData, + AdvancedThreatProtectionSetting, + Alert, + AlertConfidenceReason, + AlertEntity, + AlertsSuppressionRule, + AllowlistCustomAlertRule, + AmqpC2DMessagesNotInAllowedRange, + AmqpC2DRejectedMessagesNotInAllowedRange, + AmqpD2CMessagesNotInAllowedRange, + AscLocation, + AssessmentLinks, + AssessmentStatus, + AuthenticationDetailsProperties, + AutoProvisioningSetting, + AwAssumeRoleAuthenticationDetailsProperties, + AwsCredsAuthenticationDetailsProperties, + AzureResourceDetails, + AzureResourceLink, + BaseResource, + CloudError, + Compliance, + ComplianceResult, + ComplianceSegment, + ConnectionToIpNotAllowed, + ConnectorSetting, + ContainerRegistryVulnerabilityProperties, + CustomAlertRule, + CVE, + CVSS, + DataExportSettings, + DenylistCustomAlertRule, + DeviceSecurityGroup, + DirectMethodInvokesNotInAllowedRange, + EffectiveNetworkSecurityGroups, + FailedLocalLoginsNotInAllowedRange, + FileUploadsNotInAllowedRange, + GcpCredentialsDetailsProperties, + HttpC2DMessagesNotInAllowedRange, + HttpC2DRejectedMessagesNotInAllowedRange, + HttpD2CMessagesNotInAllowedRange, + HybridComputeSettingsProperties, + InformationProtectionKeyword, + InformationProtectionPolicy, + InformationType, + IotAlertType, + IotRecommendation, + IotRecommendationType, + IotRecommendationTypeList, + IoTSecurityAlertedDevice, + IoTSecurityDeviceAlert, + IoTSecurityDeviceRecommendation, + IoTSecuritySolutionAnalyticsModel, + IoTSecuritySolutionAnalyticsModelPropertiesDevicesMetricsItem, + IoTSeverityMetrics, + ListCustomAlertRule, + LocalUserNotAllowed, + MqttC2DMessagesNotInAllowedRange, + MqttC2DRejectedMessagesNotInAllowedRange, + MqttD2CMessagesNotInAllowedRange, + OnPremiseResourceDetails, + Pricing, + ProcessNotAllowed, + ProxyServerProperties, + QueuePurgesNotInAllowedRange, + RegulatoryComplianceAssessment, + RegulatoryComplianceControl, + RegulatoryComplianceStandard, + Resource, + ResourceDetails, + Rule, + ScopeElement, + SecureScoreControlDefinitionItem, + SecureScoreControlDefinitionSource, + SecureScoreControlDetails, + SecureScoreItem, + SecurityAssessment, + SecurityAssessmentMetadata, + SecurityAssessmentMetadataPartnerData, + SecurityAssessmentMetadataProperties, + SecurityAssessmentPartnerData, + SecurityContact, + SecuritySubAssessment, + SecurityTask, + SecurityTaskParameters, + SensitivityLabel, + ServerVulnerabilityAssessment, + ServerVulnerabilityProperties, + ServicePrincipalProperties, + Setting, + SettingResource, + SqlServerVulnerabilityProperties, + SubAssessmentStatus, + SuppressionAlertsScope, + ThresholdCustomAlertRule, + TimeWindowCustomAlertRule, + TwinUpdatesNotInAllowedRange, + UnauthorizedOperationsNotInAllowedRange, + VendorReference, + WorkspaceSetting +} from "../models/mappers"; diff --git a/sdk/security/arm-security/src/models/iotRecommendationsMappers.ts b/sdk/security/arm-security/src/models/iotRecommendationsMappers.ts new file mode 100644 index 000000000000..e5aad44094fe --- /dev/null +++ b/sdk/security/arm-security/src/models/iotRecommendationsMappers.ts @@ -0,0 +1,113 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + ActiveConnectionsNotInAllowedRange, + AdaptiveNetworkHardening, + AdditionalData, + AdvancedThreatProtectionSetting, + Alert, + AlertConfidenceReason, + AlertEntity, + AlertsSuppressionRule, + AllowlistCustomAlertRule, + AmqpC2DMessagesNotInAllowedRange, + AmqpC2DRejectedMessagesNotInAllowedRange, + AmqpD2CMessagesNotInAllowedRange, + AscLocation, + AssessmentLinks, + AssessmentStatus, + AuthenticationDetailsProperties, + AutoProvisioningSetting, + AwAssumeRoleAuthenticationDetailsProperties, + AwsCredsAuthenticationDetailsProperties, + AzureResourceDetails, + AzureResourceLink, + BaseResource, + CloudError, + Compliance, + ComplianceResult, + ComplianceSegment, + ConnectionToIpNotAllowed, + ConnectorSetting, + ContainerRegistryVulnerabilityProperties, + CustomAlertRule, + CVE, + CVSS, + DataExportSettings, + DenylistCustomAlertRule, + DeviceSecurityGroup, + DirectMethodInvokesNotInAllowedRange, + EffectiveNetworkSecurityGroups, + FailedLocalLoginsNotInAllowedRange, + FileUploadsNotInAllowedRange, + GcpCredentialsDetailsProperties, + HttpC2DMessagesNotInAllowedRange, + HttpC2DRejectedMessagesNotInAllowedRange, + HttpD2CMessagesNotInAllowedRange, + HybridComputeSettingsProperties, + InformationProtectionKeyword, + InformationProtectionPolicy, + InformationType, + IotAlertType, + IotRecommendation, + IotRecommendationList, + IotRecommendationType, + IoTSecurityAlertedDevice, + IoTSecurityDeviceAlert, + IoTSecurityDeviceRecommendation, + IoTSecuritySolutionAnalyticsModel, + IoTSecuritySolutionAnalyticsModelPropertiesDevicesMetricsItem, + IoTSeverityMetrics, + ListCustomAlertRule, + LocalUserNotAllowed, + MqttC2DMessagesNotInAllowedRange, + MqttC2DRejectedMessagesNotInAllowedRange, + MqttD2CMessagesNotInAllowedRange, + OnPremiseResourceDetails, + Pricing, + ProcessNotAllowed, + ProxyServerProperties, + QueuePurgesNotInAllowedRange, + RegulatoryComplianceAssessment, + RegulatoryComplianceControl, + RegulatoryComplianceStandard, + Resource, + ResourceDetails, + Rule, + ScopeElement, + SecureScoreControlDefinitionItem, + SecureScoreControlDefinitionSource, + SecureScoreControlDetails, + SecureScoreItem, + SecurityAssessment, + SecurityAssessmentMetadata, + SecurityAssessmentMetadataPartnerData, + SecurityAssessmentMetadataProperties, + SecurityAssessmentPartnerData, + SecurityContact, + SecuritySubAssessment, + SecurityTask, + SecurityTaskParameters, + SensitivityLabel, + ServerVulnerabilityAssessment, + ServerVulnerabilityProperties, + ServicePrincipalProperties, + Setting, + SettingResource, + SqlServerVulnerabilityProperties, + SubAssessmentStatus, + SuppressionAlertsScope, + ThresholdCustomAlertRule, + TimeWindowCustomAlertRule, + TwinUpdatesNotInAllowedRange, + UnauthorizedOperationsNotInAllowedRange, + VendorReference, + WorkspaceSetting +} from "../models/mappers"; diff --git a/sdk/security/arm-security/src/models/iotSecuritySolutionAnalyticsMappers.ts b/sdk/security/arm-security/src/models/iotSecuritySolutionAnalyticsMappers.ts index acf16f70939c..e303590a9561 100644 --- a/sdk/security/arm-security/src/models/iotSecuritySolutionAnalyticsMappers.ts +++ b/sdk/security/arm-security/src/models/iotSecuritySolutionAnalyticsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/locationsMappers.ts b/sdk/security/arm-security/src/models/locationsMappers.ts index 99a303ae6587..0a7de859901c 100644 --- a/sdk/security/arm-security/src/models/locationsMappers.ts +++ b/sdk/security/arm-security/src/models/locationsMappers.ts @@ -57,6 +57,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/mappers.ts b/sdk/security/arm-security/src/models/mappers.ts index 199bf08825b0..2db0992d75cf 100644 --- a/sdk/security/arm-security/src/models/mappers.ts +++ b/sdk/security/arm-security/src/models/mappers.ts @@ -1849,6 +1849,20 @@ export const IotAlertType: msRest.CompositeMapper = { name: "String" } }, + productName: { + readOnly: true, + serializedName: "properties.productName", + type: { + name: "String" + } + }, + productComponentName: { + readOnly: true, + serializedName: "properties.productComponentName", + type: { + name: "String" + } + }, vendorName: { readOnly: true, serializedName: "properties.vendorName", @@ -1963,6 +1977,145 @@ export const IotAlert: msRest.CompositeMapper = { } }; +export const IotRecommendationType: msRest.CompositeMapper = { + serializedName: "IotRecommendationType", + type: { + name: "Composite", + className: "IotRecommendationType", + modelProperties: { + ...Resource.type.modelProperties, + recommendationDisplayName: { + readOnly: true, + serializedName: "properties.recommendationDisplayName", + type: { + name: "String" + } + }, + severity: { + readOnly: true, + serializedName: "properties.severity", + type: { + name: "String" + } + }, + description: { + readOnly: true, + serializedName: "properties.description", + type: { + name: "String" + } + }, + productName: { + readOnly: true, + serializedName: "properties.productName", + type: { + name: "String" + } + }, + productComponentName: { + readOnly: true, + serializedName: "properties.productComponentName", + type: { + name: "String" + } + }, + vendorName: { + readOnly: true, + serializedName: "properties.vendorName", + type: { + name: "String" + } + }, + control: { + readOnly: true, + serializedName: "properties.control", + type: { + name: "String" + } + }, + remediationSteps: { + readOnly: true, + serializedName: "properties.remediationSteps", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + dataSource: { + readOnly: true, + serializedName: "properties.dataSource", + type: { + name: "String" + } + } + } + } +}; + +export const IotRecommendationTypeList: msRest.CompositeMapper = { + serializedName: "IotRecommendationTypeList", + type: { + name: "Composite", + className: "IotRecommendationTypeList", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IotRecommendationType" + } + } + } + } + } + } +}; + +export const IotRecommendation: msRest.CompositeMapper = { + serializedName: "IotRecommendation", + type: { + name: "Composite", + className: "IotRecommendation", + modelProperties: { + ...Resource.type.modelProperties, + deviceId: { + readOnly: true, + serializedName: "properties.deviceId", + type: { + name: "String" + } + }, + recommendationType: { + readOnly: true, + serializedName: "properties.recommendationType", + type: { + name: "String" + } + }, + discoveredTimeUtc: { + readOnly: true, + serializedName: "properties.discoveredTimeUtc", + type: { + name: "String" + } + }, + recommendationAdditionalData: { + serializedName: "properties.recommendationAdditionalData", + type: { + name: "Object" + } + } + } + } +}; + export const OperationDisplay: msRest.CompositeMapper = { serializedName: "OperationDisplay", type: { @@ -6373,6 +6526,43 @@ export const IotAlertList: msRest.CompositeMapper = { } }; +export const IotRecommendationList: msRest.CompositeMapper = { + serializedName: "IotRecommendationList", + type: { + name: "Composite", + className: "IotRecommendationList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IotRecommendation" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + }, + totalCount: { + readOnly: true, + serializedName: "totalCount", + type: { + name: "Number" + } + } + } + } +}; + export const AscLocationList: msRest.CompositeMapper = { serializedName: "AscLocationList", type: { diff --git a/sdk/security/arm-security/src/models/parameters.ts b/sdk/security/arm-security/src/models/parameters.ts index f52d4eecbe9f..4837c6a7f335 100644 --- a/sdk/security/arm-security/src/models/parameters.ts +++ b/sdk/security/arm-security/src/models/parameters.ts @@ -412,6 +412,26 @@ export const iotAlertTypeName: msRest.OperationURLParameter = { } } }; +export const iotRecommendationId: msRest.OperationURLParameter = { + parameterPath: "iotRecommendationId", + mapper: { + required: true, + serializedName: "iotRecommendationId", + type: { + name: "String" + } + } +}; +export const iotRecommendationTypeName: msRest.OperationURLParameter = { + parameterPath: "iotRecommendationTypeName", + mapper: { + required: true, + serializedName: "iotRecommendationTypeName", + type: { + name: "String" + } + } +}; export const jitNetworkAccessPolicyInitiateType: msRest.OperationURLParameter = { parameterPath: "jitNetworkAccessPolicyInitiateType", mapper: { @@ -491,6 +511,18 @@ export const pricingName: msRest.OperationURLParameter = { } } }; +export const recommendationType: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "recommendationType" + ], + mapper: { + serializedName: "recommendationType", + type: { + name: "String" + } + } +}; export const regulatoryComplianceAssessmentName: msRest.OperationURLParameter = { parameterPath: "regulatoryComplianceAssessmentName", mapper: { diff --git a/sdk/security/arm-security/src/models/pricingsMappers.ts b/sdk/security/arm-security/src/models/pricingsMappers.ts index 3c5fe17c0f8a..156204798101 100644 --- a/sdk/security/arm-security/src/models/pricingsMappers.ts +++ b/sdk/security/arm-security/src/models/pricingsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/regulatoryComplianceAssessmentsMappers.ts b/sdk/security/arm-security/src/models/regulatoryComplianceAssessmentsMappers.ts index b5a619b95db2..0c6d65cc6be8 100644 --- a/sdk/security/arm-security/src/models/regulatoryComplianceAssessmentsMappers.ts +++ b/sdk/security/arm-security/src/models/regulatoryComplianceAssessmentsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/regulatoryComplianceControlsMappers.ts b/sdk/security/arm-security/src/models/regulatoryComplianceControlsMappers.ts index 7009b0b33acc..e4d97772eef7 100644 --- a/sdk/security/arm-security/src/models/regulatoryComplianceControlsMappers.ts +++ b/sdk/security/arm-security/src/models/regulatoryComplianceControlsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/regulatoryComplianceStandardsMappers.ts b/sdk/security/arm-security/src/models/regulatoryComplianceStandardsMappers.ts index 28af59f90eac..3ac65af5d516 100644 --- a/sdk/security/arm-security/src/models/regulatoryComplianceStandardsMappers.ts +++ b/sdk/security/arm-security/src/models/regulatoryComplianceStandardsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/secureScoreControlDefinitionsMappers.ts b/sdk/security/arm-security/src/models/secureScoreControlDefinitionsMappers.ts index 8e57787ca78f..6e1479298676 100644 --- a/sdk/security/arm-security/src/models/secureScoreControlDefinitionsMappers.ts +++ b/sdk/security/arm-security/src/models/secureScoreControlDefinitionsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/secureScoreControlsMappers.ts b/sdk/security/arm-security/src/models/secureScoreControlsMappers.ts index ed90af21992f..4908943de32f 100644 --- a/sdk/security/arm-security/src/models/secureScoreControlsMappers.ts +++ b/sdk/security/arm-security/src/models/secureScoreControlsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/secureScoresMappers.ts b/sdk/security/arm-security/src/models/secureScoresMappers.ts index d6d44fd9e50f..e3a55f2757ec 100644 --- a/sdk/security/arm-security/src/models/secureScoresMappers.ts +++ b/sdk/security/arm-security/src/models/secureScoresMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/securityContactsMappers.ts b/sdk/security/arm-security/src/models/securityContactsMappers.ts index 2f6dfec5cc5d..a88b0730b35e 100644 --- a/sdk/security/arm-security/src/models/securityContactsMappers.ts +++ b/sdk/security/arm-security/src/models/securityContactsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/serverVulnerabilityAssessmentOperationsMappers.ts b/sdk/security/arm-security/src/models/serverVulnerabilityAssessmentOperationsMappers.ts index dc7e3a4a5784..b1a547e401a0 100644 --- a/sdk/security/arm-security/src/models/serverVulnerabilityAssessmentOperationsMappers.ts +++ b/sdk/security/arm-security/src/models/serverVulnerabilityAssessmentOperationsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/settingsMappers.ts b/sdk/security/arm-security/src/models/settingsMappers.ts index 2259145b2e14..c03f8a106df8 100644 --- a/sdk/security/arm-security/src/models/settingsMappers.ts +++ b/sdk/security/arm-security/src/models/settingsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/subAssessmentsMappers.ts b/sdk/security/arm-security/src/models/subAssessmentsMappers.ts index 67a82124343b..2a11c37cb966 100644 --- a/sdk/security/arm-security/src/models/subAssessmentsMappers.ts +++ b/sdk/security/arm-security/src/models/subAssessmentsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/tasksMappers.ts b/sdk/security/arm-security/src/models/tasksMappers.ts index 1a235346d717..acb85e72867b 100644 --- a/sdk/security/arm-security/src/models/tasksMappers.ts +++ b/sdk/security/arm-security/src/models/tasksMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/models/workspaceSettingsMappers.ts b/sdk/security/arm-security/src/models/workspaceSettingsMappers.ts index fbd70dcd215e..3367946b400d 100644 --- a/sdk/security/arm-security/src/models/workspaceSettingsMappers.ts +++ b/sdk/security/arm-security/src/models/workspaceSettingsMappers.ts @@ -56,6 +56,8 @@ export { InformationProtectionPolicy, InformationType, IotAlertType, + IotRecommendation, + IotRecommendationType, IoTSecurityAlertedDevice, IoTSecurityDeviceAlert, IoTSecurityDeviceRecommendation, diff --git a/sdk/security/arm-security/src/operations/index.ts b/sdk/security/arm-security/src/operations/index.ts index c75fcc0c60a3..6c33b324b334 100644 --- a/sdk/security/arm-security/src/operations/index.ts +++ b/sdk/security/arm-security/src/operations/index.ts @@ -20,6 +20,8 @@ export * from "./iotSecuritySolutionsAnalyticsAggregatedAlert"; export * from "./iotSecuritySolutionsAnalyticsRecommendation"; export * from "./iotAlertTypes"; export * from "./iotAlerts"; +export * from "./iotRecommendationTypes"; +export * from "./iotRecommendations"; export * from "./locations"; export * from "./operations"; export * from "./tasks"; diff --git a/sdk/security/arm-security/src/operations/iotRecommendationTypes.ts b/sdk/security/arm-security/src/operations/iotRecommendationTypes.ts new file mode 100644 index 000000000000..0ec84d74b99f --- /dev/null +++ b/sdk/security/arm-security/src/operations/iotRecommendationTypes.ts @@ -0,0 +1,155 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/iotRecommendationTypesMappers"; +import * as Parameters from "../models/parameters"; +import { SecurityCenterContext } from "../securityCenterContext"; + +/** Class representing a IotRecommendationTypes. */ +export class IotRecommendationTypes { + private readonly client: SecurityCenterContext; + + /** + * Create a IotRecommendationTypes. + * @param {SecurityCenterContext} client Reference to the service client. + */ + constructor(client: SecurityCenterContext) { + this.client = client; + } + + /** + * List IoT recommendation types + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, solutionName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param callback The callback + */ + list(resourceGroupName: string, solutionName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, solutionName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, solutionName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + solutionName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get IoT recommendation type + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param iotRecommendationTypeName Name of the recommendation type + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, solutionName: string, iotRecommendationTypeName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param iotRecommendationTypeName Name of the recommendation type + * @param callback The callback + */ + get(resourceGroupName: string, solutionName: string, iotRecommendationTypeName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param iotRecommendationTypeName Name of the recommendation type + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, solutionName: string, iotRecommendationTypeName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, solutionName: string, iotRecommendationTypeName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + solutionName, + iotRecommendationTypeName, + options + }, + getOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Security/iotSecuritySolutions/{solutionName}/iotRecommendationTypes", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.solutionName + ], + queryParameters: [ + Parameters.apiVersion3 + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.IotRecommendationTypeList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Security/iotSecuritySolutions/{solutionName}/iotRecommendationTypes/{iotRecommendationTypeName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.solutionName, + Parameters.iotRecommendationTypeName + ], + queryParameters: [ + Parameters.apiVersion3 + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.IotRecommendationType + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/security/arm-security/src/operations/iotRecommendations.ts b/sdk/security/arm-security/src/operations/iotRecommendations.ts new file mode 100644 index 000000000000..734ede4894e5 --- /dev/null +++ b/sdk/security/arm-security/src/operations/iotRecommendations.ts @@ -0,0 +1,207 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/iotRecommendationsMappers"; +import * as Parameters from "../models/parameters"; +import { SecurityCenterContext } from "../securityCenterContext"; + +/** Class representing a IotRecommendations. */ +export class IotRecommendations { + private readonly client: SecurityCenterContext; + + /** + * Create a IotRecommendations. + * @param {SecurityCenterContext} client Reference to the service client. + */ + constructor(client: SecurityCenterContext) { + this.client = client; + } + + /** + * List IoT recommendations + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, solutionName: string, options?: Models.IotRecommendationsListOptionalParams): Promise; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param callback The callback + */ + list(resourceGroupName: string, solutionName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, solutionName: string, options: Models.IotRecommendationsListOptionalParams, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, solutionName: string, options?: Models.IotRecommendationsListOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + solutionName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get IoT recommendation + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param iotRecommendationId Id of the recommendation + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, solutionName: string, iotRecommendationId: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param iotRecommendationId Id of the recommendation + * @param callback The callback + */ + get(resourceGroupName: string, solutionName: string, iotRecommendationId: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group within the user's subscription. The name + * is case insensitive. + * @param solutionName The name of the IoT Security solution. + * @param iotRecommendationId Id of the recommendation + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, solutionName: string, iotRecommendationId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, solutionName: string, iotRecommendationId: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + solutionName, + iotRecommendationId, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * List IoT recommendations + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Security/iotSecuritySolutions/{solutionName}/iotRecommendations", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.solutionName + ], + queryParameters: [ + Parameters.apiVersion3, + Parameters.recommendationType, + Parameters.limit, + Parameters.skipToken + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.IotRecommendationList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Security/iotSecuritySolutions/{solutionName}/iotRecommendations/{iotRecommendationId}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.solutionName, + Parameters.iotRecommendationId + ], + queryParameters: [ + Parameters.apiVersion3 + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.IotRecommendation + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.IotRecommendationList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/security/arm-security/src/securityCenter.ts b/sdk/security/arm-security/src/securityCenter.ts index 2e8e5cd35a36..6193dfe612ae 100644 --- a/sdk/security/arm-security/src/securityCenter.ts +++ b/sdk/security/arm-security/src/securityCenter.ts @@ -29,6 +29,8 @@ class SecurityCenter extends SecurityCenterContext { iotSecuritySolutionsAnalyticsRecommendation: operations.IotSecuritySolutionsAnalyticsRecommendation; iotAlertTypes: operations.IotAlertTypes; iotAlerts: operations.IotAlerts; + iotRecommendationTypes: operations.IotRecommendationTypes; + iotRecommendations: operations.IotRecommendations; locations: operations.Locations; operations: operations.Operations; tasks: operations.Tasks; @@ -82,6 +84,8 @@ class SecurityCenter extends SecurityCenterContext { this.iotSecuritySolutionsAnalyticsRecommendation = new operations.IotSecuritySolutionsAnalyticsRecommendation(this); this.iotAlertTypes = new operations.IotAlertTypes(this); this.iotAlerts = new operations.IotAlerts(this); + this.iotRecommendationTypes = new operations.IotRecommendationTypes(this); + this.iotRecommendations = new operations.IotRecommendations(this); this.locations = new operations.Locations(this); this.operations = new operations.Operations(this); this.tasks = new operations.Tasks(this);