Policy types for @turbot/servicenow-azure-automation

Azure > Automation > Automation Account > ServiceNow

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNow
Targets

Azure > Automation > Automation Account > ServiceNow > Configuration Item

Synchronize the data for the Azure > Automation > Automation Account based on the policies Azure > Automation > Automation Account > ServiceNow > Configuration Item > *

The Configuration Item control is responsible for automatically synchronizing records in a designated ServiceNow table, maintaining an up-to-date reflection of the Azure > Automation > Automation Account information within the ServiceNow CMDB.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNowConfigurationItem
Valid Value
[
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
],
"example": [
"Skip"
],
"default": "Skip"
}

Azure > Automation > Automation Account > ServiceNow > Configuration Item > Record

The policy facilitates the accurate representation of cloud resource within the ServiceNow environment, ensuring that critical data is effectively mapped and managed. Attribute of an Azure > Automation > Automation Account is systematically mapped to a specific column in a ServiceNow table.

The policy allows enabling organizations to select and map only those attributes that are most relevant to their operational needs. It significantly reduces the manual effort involved in data transfer and minimizes the risk of errors, thereby enhancing the overall efficiency of data management.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNowConfigurationItemRecord
Default Template Input
"{\n resource: automationAccount{\n data\n metadata\n turbot {\n akas\n id\n tags\n title\n }\n }\n}\n"
Default Template
"automation_account_name: {{ $.resource.data.name | dump | safe }}\ncreation_time: {{ $.resource.data.creationTime | dump | safe }}\netag: {{ $.resource.data.etag | dump | safe }}\nid: {{ $.resource.data.id | dump | safe }}\nlast_modified_by: {{ $.resource.data.lastModifiedBy | dump | safe }}\nlast_modified_time: {{ $.resource.data.lastModifiedTime | dump | safe }}\nregion: {{ $.resource.metadata.azure.regionName | dump | safe }}\nresource_group: {{ $.resource.metadata.azure.resourceGroupName | dump | safe }}\nsku_capacity: {{ $.resource.data.sku.capacity | dump | safe }}\nsku_family: {{ $.resource.data.sku.family | dump | safe }}\nsku_name: {{ $.resource.data.sku.name | dump | safe }}\nstate: {{ $.resource.data.state | dump | safe }}\nsubscription_id: {{ $.resource.metadata.azure.subscriptionId | dump | safe }}\ntags: {{ $.resource.turbot.tags | dump | safe }}\ntype: {{ $.resource.data.type | dump | safe }}\n"
Schema
{
"type": "object"
}

Azure > Automation > Automation Account > ServiceNow > Configuration Item > Table Definition

This policy specifically allows users to define two key aspects: the name of the ServiceNow table where the Azure > Automation > Automation Account data will be stored, and the details of the columns used for archiving purposes.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNowConfigurationItemTableDefinition
Default Template Input
[
"{\n serviceNowInstance: resources(filter: \"resourceTypeId:tmod:@turbot/servicenow#/resource/types/instance level:self limit:1\") {\n items {\n turbot {\n id\n }\n }\n }\n}\n",
"{\n tableDefinition: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNowTableDefinition resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n applicationScope: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow#/policy/types/serviceNowApplicationScope resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n}\n"
]
Default Template
"tableName: "{%- if $.applicationScope.items | length == 0 or $.tableDefinition.items | length == 0 %} {%- else %}{{$.applicationScope.items[0].value}}_{{$.tableDefinition.items[0].value.table.name | lower}}{% endif %}"\n"
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"tableName"
],
"properties": {
"tableName": {
"type": "string"
},
"archiveColumns": {
"type": "object"
}
}
}

Azure > Automation > Automation Account > ServiceNow > Table

Configure a Table for Azure > Automation > Automation Account resource type in ServiceNow via the Azure > Automation > Automation Account > ServiceNow > Table > * policies.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNowTable
Valid Value
[
"Skip",
"Check: Configured",
"Enforce: Configured"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Configured",
"Enforce: Configured"
],
"example": [
"Skip"
],
"default": "Skip"
}

Azure > Automation > Automation Account > ServiceNow > Table > Definition

The policy enables the definition of ServiceNow table properties, including its name and the base table from which it extends, and details the specific columns required for representing Azure > Automation > Automation Account data.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/automationAccountServiceNowTableDefinition
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"table",
"columns"
],
"properties": {
"table": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string"
},
"extendsTable": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
}
}
},
"columns": {
"type": "array",
"description": "An array of columns with their mappings to the CMDB.",
"default": [],
"items": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"description": "The name of the column in the table.",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string",
"description": "The label for the column."
},
"type": {
"description": "The data type of the column.",
"type": "string"
},
"size": {
"type": "integer",
"description": "The length for data type."
}
}
}
}
},
"default": {
"table": {
"name": "guardrails_azure_automation_automationaccount",
"label": "Azure > Automation > Automation Account",
"extendsTable": "cmdb_ci"
},
"columns": [
{
"name": "automation_account_name",
"label": "Name"
},
{
"name": "creation_time",
"label": "Creation Time"
},
{
"name": "etag",
"label": "Etag"
},
{
"name": "id",
"label": "ID"
},
{
"name": "last_modified_by",
"label": "Last Modified By"
},
{
"name": "last_modified_time",
"label": "Last Modified Time"
},
{
"name": "region",
"label": "Region"
},
{
"name": "resource_group",
"label": "Resource Group"
},
{
"name": "sku_capacity",
"label": "SKU Capacity"
},
{
"name": "sku_family",
"label": "SKU Family"
},
{
"name": "sku_name",
"label": "SKU Name"
},
{
"name": "state",
"label": "State"
},
{
"name": "subscription_id",
"label": "Subscription ID"
},
{
"name": "tags",
"label": "Tags",
"type": "string",
"size": 1000
},
{
"name": "type",
"label": "Type"
}
]
}
}

Azure > Automation > Runbook > ServiceNow

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNow
Targets

Azure > Automation > Runbook > ServiceNow > Configuration Item

Synchronize the data for the Azure > Automation > Runbook based on the policies Azure > Automation > Runbook > ServiceNow > Configuration Item > *

The Configuration Item control is responsible for automatically synchronizing records in a designated ServiceNow table, maintaining an up-to-date reflection of the Azure > Automation > Runbook information within the ServiceNow CMDB.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNowConfigurationItem
Valid Value
[
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Archived",
"Check: Deleted",
"Check: Sync",
"Enforce: Archived",
"Enforce: Deleted",
"Enforce: Sync",
"Enforce: Sync, archive on delete"
],
"example": [
"Skip"
],
"default": "Skip"
}

Azure > Automation > Runbook > ServiceNow > Configuration Item > Record

The policy facilitates the accurate representation of cloud resource within the ServiceNow environment, ensuring that critical data is effectively mapped and managed. Attribute of an Azure > Automation > Runbook is systematically mapped to a specific column in a ServiceNow table.

The policy allows enabling organizations to select and map only those attributes that are most relevant to their operational needs. It significantly reduces the manual effort involved in data transfer and minimizes the risk of errors, thereby enhancing the overall efficiency of data management.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNowConfigurationItemRecord
Default Template Input
"{\n resource: runbook{\n data\n metadata\n turbot {\n akas\n id\n tags\n title\n }\n }\n}\n"
Default Template
"creation_time: {{ $.resource.data.creationTime | dump | safe }}\ndescription: {{ $.resource.data.description | dump | safe }}\netag: {{ $.resource.data.etag | dump | safe }}\nid: {{ $.resource.data.id | dump | safe }}\nlast_modified_time: {{ $.resource.data.lastModifiedTime | dump | safe }}\nparameters: {{ $.resource.data.parameters | dump | safe }}\nprovisioning_state: {{ $.resource.data.provisioningState | dump | safe }}\nregion: {{ $.resource.data.location | dump | safe }}\nresource_group: {{ $.resource.metadata.azure.resourceGroupName | dump | safe }}\nrunbook_name: {{ $.resource.data.name | dump | safe }}\nrunbook_type: {{ $.resource.data.runbookType | dump | safe }}\nstate: {{ $.resource.data.state | dump | safe }}\nsubscription_id: {{ $.resource.metadata.azure.subscriptionId | dump | safe }}\ntags: {{ $.resource.turbot.tags | dump | safe }}\ntype: {{ $.resource.data.type | dump | safe }}\n"
Schema
{
"type": "object"
}

Azure > Automation > Runbook > ServiceNow > Configuration Item > Table Definition

This policy specifically allows users to define two key aspects: the name of the ServiceNow table where the Azure > Automation > Runbook data will be stored, and the details of the columns used for archiving purposes.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNowConfigurationItemTableDefinition
Default Template Input
[
"{\n serviceNowInstance: resources(filter: \"resourceTypeId:tmod:@turbot/servicenow#/resource/types/instance level:self limit:1\") {\n items {\n turbot {\n id\n }\n }\n }\n}\n",
"{\n tableDefinition: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNowTableDefinition resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n applicationScope: policyValues(filter: \"policyTypeId:tmod:@turbot/servicenow#/policy/types/serviceNowApplicationScope resourceId:{{$.serviceNowInstance.items[0].turbot.id}} level:self\") {\n items {\n value\n }\n }\n}\n"
]
Default Template
"tableName: "{%- if $.applicationScope.items | length == 0 or $.tableDefinition.items | length == 0 %} {%- else %}{{$.applicationScope.items[0].value}}_{{$.tableDefinition.items[0].value.table.name | lower}}{% endif %}"\n"
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"tableName"
],
"properties": {
"tableName": {
"type": "string"
},
"archiveColumns": {
"type": "object"
}
}
}

Azure > Automation > Runbook > ServiceNow > Table

Configure a Table for Azure > Automation > Runbook resource type in ServiceNow via the Azure > Automation > Runbook > ServiceNow > Table > * policies.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNowTable
Valid Value
[
"Skip",
"Check: Configured",
"Enforce: Configured"
]
Schema
{
"type": "string",
"enum": [
"Skip",
"Check: Configured",
"Enforce: Configured"
],
"example": [
"Skip"
],
"default": "Skip"
}

Azure > Automation > Runbook > ServiceNow > Table > Definition

The policy enables the definition of ServiceNow table properties, including its name and the base table from which it extends, and details the specific columns required for representing Azure > Automation > Runbook data.

URI
tmod:@turbot/servicenow-azure-automation#/policy/types/runbookServiceNowTableDefinition
Schema
{
"type": "object",
"additionalProperties": false,
"required": [
"table",
"columns"
],
"properties": {
"table": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string"
},
"extendsTable": {
"type": "string",
"pattern": "^([0-9a-z_])+$"
}
}
},
"columns": {
"type": "array",
"description": "An array of columns with their mappings to the CMDB.",
"default": [],
"items": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string",
"description": "The name of the column in the table.",
"pattern": "^([0-9a-z_])+$"
},
"label": {
"type": "string",
"description": "The label for the column."
},
"type": {
"description": "The data type of the column.",
"type": "string"
},
"size": {
"type": "integer",
"description": "The length for data type."
}
}
}
}
},
"default": {
"table": {
"name": "guardrails_azure_automation_runbook",
"label": "Azure > Automation > Runbook",
"extendsTable": "cmdb_ci"
},
"columns": [
{
"name": "creation_time",
"label": "Creation Time"
},
{
"name": "description",
"label": "Description"
},
{
"name": "etag",
"label": "Etag"
},
{
"name": "id",
"label": "ID"
},
{
"name": "last_modified_time",
"label": "Last Modified Time"
},
{
"name": "parameters",
"label": "Parameters"
},
{
"name": "provisioning_state",
"label": "Provisioning State"
},
{
"name": "region",
"label": "Region"
},
{
"name": "resource_group",
"label": "Resource Group"
},
{
"name": "runbook_name",
"label": "Name"
},
{
"name": "runbook_type",
"label": "Runbook Type"
},
{
"name": "state",
"label": "State"
},
{
"name": "subscription_id",
"label": "Subscription ID"
},
{
"name": "tags",
"label": "Tags",
"type": "string",
"size": 1000
},
{
"name": "type",
"label": "Type"
}
]
}
}