Free Utility: Paste a User Story → Generate Catalog Item
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
Building catalog items can be tedious and repetitive, so I built a free utility that turns a plain-English user story into a first-draft scaffold.
What it Generates
Background script for sc_cat_item creation
Variables (item_option_new) with type, order, mandatory flag, and default values
Starter client script and UI policy stubs
Why I Built It
Catalog item work is often just boilerplate plus a few unique tweaks. This tool gets you to a “first working draft” in about 30 seconds so you can focus on customization and review.
How It Works
Paste a user story or field list
Adjust variable types if needed
Preview the generated code and checklist
Copy the output into Background Script or Studio in a sub-production instance, then adjust as necessary
Example Input:
New hire laptop request: Model (choice), RAM (choice), Admin Access (yes/no), Needed Date (date), Justification (string, mandatory)
Example Output Snippet:
var ci = new GlideRecord('sc_cat_item');
ci.initialize();
ci.name = 'Laptop Request';
ci.short_description = 'Request a standard laptop';
ci.category = '<your category sys_id>';
var ciId = ci.insert();
// Add variable
function addVar(q, n, t, ord, mand, def) {
var v = new GlideRecord('item_option_new');
v.initialize();
v.cat_item = ciId;
v.question = q;
v.name = n;
v.type = t;
v.order = ord;
v.mandatory = mand;
if (def) v.default_value = def;
v.insert();
}
Community-Safe Notes
Independent project — not affiliated with ServiceNow
No login required and no instance access; only processes the text you paste
Do not paste secrets or customer data
Always review in a sub-production environment before use
Feedback Requested
Edge cases you’d like supported (variable sets, reference qualifiers)
Preferred default values for variable types
Flow templates you’d like to see added