custom_recommendations
Creates, updates, deletes, gets or lists a custom_recommendations
resource.
Overview
Name | custom_recommendations |
Type | Resource |
Id | azure.security.custom_recommendations |
Fields
- vw_custom_recommendations
- custom_recommendations
Name | Datatype | Description |
---|---|---|
id | text | Resource Id |
name | text | Resource name |
description | text | field from the properties object |
assessment_key | text | field from the properties object |
cloud_providers | text | field from the properties object |
customRecommendationName | text | field from the properties object |
display_name | text | field from the properties object |
query | text | field from the properties object |
remediation_description | text | field from the properties object |
scope | text | field from the properties object |
security_issue | text | field from the properties object |
severity | text | field from the properties object |
system_data | text | field from the properties object |
type | text | Resource type |
Name | Datatype | Description |
---|---|---|
id | string | Resource Id |
name | string | Resource name |
properties | object | describes the Custom Recommendation properties |
systemData | object | Metadata pertaining to creation and last modification of the resource. |
type | string | Resource type |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | customRecommendationName, scope | Get a specific custom recommendation for the requested scope by customRecommendationName |
list | SELECT | scope | Get a list of all relevant custom recommendations over a scope |
create_or_update | INSERT | customRecommendationName, scope | Creates or updates a custom recommendation over a given scope |
delete | DELETE | customRecommendationName, scope | Delete a custom recommendation over a given scope |
SELECT
examples
Get a list of all relevant custom recommendations over a scope
- vw_custom_recommendations
- custom_recommendations
SELECT
id,
name,
description,
assessment_key,
cloud_providers,
customRecommendationName,
display_name,
query,
remediation_description,
scope,
security_issue,
severity,
system_data,
type
FROM azure.security.vw_custom_recommendations
WHERE scope = '{{ scope }}';
SELECT
id,
name,
properties,
systemData,
type
FROM azure.security.custom_recommendations
WHERE scope = '{{ scope }}';
INSERT
example
Use the following StackQL query and manifest file to create a new custom_recommendations
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.security.custom_recommendations (
customRecommendationName,
scope,
properties
)
SELECT
'{{ customRecommendationName }}',
'{{ scope }}',
'{{ properties }}'
;
- name: your_resource_model_name
props:
- name: properties
value:
- name: query
value: string
- name: cloudProviders
value:
- []
- name: severity
value: string
- name: securityIssue
value: string
- name: displayName
value: string
- name: description
value: string
- name: remediationDescription
value: string
- name: assessmentKey
value: string
- name: systemData
value:
- name: createdBy
value: string
- name: createdByType
value: string
- name: createdAt
value: string
- name: lastModifiedBy
value: string
- name: lastModifiedByType
value: string
- name: lastModifiedAt
value: string
- name: id
value: string
- name: name
value: string
- name: type
value: string
DELETE
example
Deletes the specified custom_recommendations
resource.
/*+ delete */
DELETE FROM azure.security.custom_recommendations
WHERE customRecommendationName = '{{ customRecommendationName }}'
AND scope = '{{ scope }}';