---
sourceDocument: Yokohama IT Operations Management
sourceDocumentLink: https://servicenow-prod.fluidtopics.net/r/yokohama/it-operations-management

 Release :

    - yokohama

ft:locale :

    - en-US

ft:publication_title :

    - Yokohama IT Operations Management

ft:clusterId :

    - itom

bundleId :

    - itom

workflow :

    - Technology


---

# Create a policy through script

# Create a policy through script {#ariaid-title1}

* Release version: Yokohama
* 
* Updated January 30, 2025
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 1 minute to read

Use the ServiceNow platform native scripting mechanism to
define the policy condition. You can externalize the decision making to script includes and
reuse the code across different policies.

## Before you begin

Role required: sn_itom_ccg.governor

## Procedure

1. Navigate to Cloud Configuration GovernancePolicies.
2. Select New.
3. On the Policy form, fill in the fields.  
   For the description of the form fields, see [Cloud Configuration Governance Policy form](https://servicenow-prod.fluidtopics.net/y9qvc781pDn3syNA9IacDw "The Cloud Configuration Governance Policy form displays detailed information about the policy such as cloud provider, resource type, policy type, and policy violation reporting settings.").

   Refer to one of the base system script-based policies as an example for
   creating the custom policy.
4. Select Submit.

## What to do next

Test the policy to make sure that it is working properly. For more information, see
[Test the policy](https://servicenow-prod.fluidtopics.net/xwfHEJdWbcHsBpTT5R2Ejw "Test the Cloud Configuration Governance policy against the configuration data imported for a previous scan run. Test the policy to make sure that it is working properly.").

*[\>]: and then


