data-policies

Manage ServiceNow Data Policies and Dictionary entries with ES5 JavaScript.

77|23|Updated Jul 16, 2025
One-click install
npx skills add https://github.com/groeimetai/snow-flow --skill data-policies
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: data-policies
Source: https://github.com/groeimetai/snow-flow/tree/main/packages/opencode/src/bundled-skills/data-policies
Command: npx skills add https://github.com/groeimetai/snow-flow --skill data-policies

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill streamlines the development and management of ServiceNow Data Policies and Dictionary entries, ensuring data integrity and consistent field behavior across your instance.

Core Features & Use Cases

  • Dictionary Management: Create, update, and manage table schemas, fields, and field types.
  • Data Policy Enforcement: Define and implement rules for mandatory fields, read-only attributes, and conditional logic.
  • Use Case: Automatically create a new custom field on the 'Incident' table, set it as mandatory when the state is 'Resolved', and ensure it has a specific maximum length.

Quick Start

Use the data-policies skill to create a new string field named 'customer_reference' on the 'change_request' table.

Frequently Asked Questions about data-policies

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce mandatory fields in ServiceNow based on a condition?

ServiceNow data policies enforce mandatory fields and read-only attributes using scripted conditions written in ES5 JavaScript. They trigger automatically when specified conditions are met, ensuring consistent field behavior across the instance.

What is the difference between a data policy and a dictionary override in ServiceNow?

ServiceNow dictionary overrides modify field characteristics on specific tables, while data policies enforce mandatory and read-only rules dynamically. This skill manages both dictionary entries and complex data policies to maintain schema integrity.

How do I create a custom field on the Incident table and make it mandatory when resolved?

Creating a custom field on the Incident table requires adding a dictionary entry, then configuring a data policy with a scripted condition. The policy enforces the mandatory rule automatically when the incident state changes to Resolved.

Can I use ES5 JavaScript to script complex conditions for ServiceNow data policies?

Yes, ServiceNow data policies support complex scripted conditions using ES5 JavaScript. This allows you to define dynamic field behavior and enforce data integrity rules based on specific record states or logical operations.

How do I manage choice lists and field types in the ServiceNow sys_dictionary table?

Managing choice lists and field types involves creating and updating entries in the ServiceNow sys_dictionary table. This skill handles schema modifications, including setting maximum lengths and defining specific field types for custom tables.