SkyeNet-MCP-ACE
The SkyeNet-MCP-ACE server enables AI agents to interact with ServiceNow instances through server-side JavaScript execution, CRUD operations, and update set management, with built-in context bloat reduction.
Core Capabilities:
Execute Server-Side JavaScript: Run server-side JavaScript directly on ServiceNow instances with configurable application scopes, timeout controls (1-300 seconds), auto-truncation of large outputs, and support for loading scripts from local files using
{{file:path}}placeholdersPerform Table Operations: Execute full CRUD operations (GET, POST, PUT, PATCH, DELETE) on any ServiceNow table with query syntax, batch operations, pagination, field filtering, display value resolution, and field validation to prevent injection attacks
Manage Update Sets: Handle complete update set lifecycle including create, set/show/clear working sets, insert/update records, rehome XMLs, view contents and recent activity, complete, reopen, delete, and diff against Default update set
Context Bloat Reduction: Use minimal, compact, and quiet response modes to reduce token usage by 90%+ through field truncation, record limiting, and removal of redundant data—preventing AI context overflow
Security & Validation: Sandbox execution environment, field validation to prevent injection attacks, scope-aware operations, and flexible credential management via environment variables, project
.envfiles, or system-wide filesIntegration Features: Designed for Cursor IDE and Codex compatibility with system-wide or project-level deployment options, bulletproof deployment scripts for Linux, response times under 3 seconds, and optimized memory usage
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@SkyeNet-MCP-ACE get the 5 most recent incidents with minimal details"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
SkyeNet-MCP-ACE
ServiceNow Background Script Execution for AI Agents - A Model Context Protocol (MCP) server that enables AI agents to execute server-side JavaScript directly on ServiceNow instances with context bloat reduction features.
🚀 Quick Start
Prerequisites
Node.js 20+ (system-wide installation recommended for Linux, nvm works on macOS)
ServiceNow instance with API access
Root/sudo access for system-wide installation (Linux only)
Installation
For Local Development (macOS/Linux)
# Clone the repository
git clone https://github.com/skyenet/skyenet-mcp-ace.git
cd skyenet-mcp-ace
# Install dependencies
npm install
# Build the project
npm run build
# Run locally
npm startFor System-Wide Installation (Linux)
# Clone the repository
git clone https://github.com/skyenet/skyenet-mcp-ace.git
cd skyenet-mcp-ace
# Bulletproof deployment (handles all edge cases)
sudo ./bulletproof-deploy.sh
# Verify installation
./bulletproof-verify.shNote: The deployment scripts are Linux-specific. For macOS, use local development mode or configure manually.
Configuration
The MCP server supports multiple ways to provide credentials, checked in priority order:
Environment variables in MCP config (highest priority) - Recommended for project-specific configs
Project directory
.servicenow-ace.envfile - In the SkyeNet-MCP-ACE repository rootHome directory
~/.servicenow-ace.envfile - Global/shared credentialsSystem directory
/etc/csadmin/servicenow-ace.env- Linux system-wide fallback
Option 1: Environment Variables in MCP Config (Recommended)
When configuring the MCP server in Cursor (.cursor/mcp.json), you can pass credentials directly:
{
"mcpServers": {
"skyenet-ace": {
"command": "node",
"args": ["/absolute/path/to/SkyeNet-MCP-ACE/build/index.js"],
"env": {
"SERVICENOW_ACE_INSTANCE": "your-instance.service-now.com",
"SERVICENOW_ACE_USERNAME": "your-username",
"SERVICENOW_ACE_PASSWORD": "your-password"
}
}
}
}Advantages: Project-specific credentials, no separate .env files needed, works from any project folder.
Option 2: Environment File
Create your ServiceNow credentials file:
# Copy the example file
cp servicenow-ace.env.example ~/.servicenow-ace.env
# Edit with your ServiceNow details
nano ~/.servicenow-ace.envRequired environment variables:
SERVICENOW_ACE_INSTANCE=your-instance.service-now.com
SERVICENOW_ACE_USERNAME=your-username
SERVICENOW_ACE_PASSWORD=your-passwordNote: You can also place .servicenow-ace.env in the project root directory for project-specific credentials.
Cursor IDE Integration
For Cursor IDE (Project-Level Configuration)
Create .cursor/mcp.json in your project folder:
{
"mcpServers": {
"skyenet-ace": {
"command": "node",
"args": ["/absolute/path/to/SkyeNet-MCP-ACE/build/index.js"],
"env": {
"SERVICENOW_ACE_INSTANCE": "your-instance.service-now.com",
"SERVICENOW_ACE_USERNAME": "your-username",
"SERVICENOW_ACE_PASSWORD": "your-password"
}
}
}
}Replace /absolute/path/to/SkyeNet-MCP-ACE with the actual path to this repository. See .cursor/mcp.json.example for a template.
Note: If credentials are provided via the env field, they take highest priority over any .env files.
For Codex (System-Wide Configuration)
Add to your Codex configuration (/etc/codex/config.toml):
[[mcp.servers.skyenet-ace]]
command = "/usr/local/sbin/skyenet-mcp-ace-server"
args = []🛠️ Available Tools
1. execute_background_script
Execute server-side JavaScript directly on ServiceNow instances.
Parameters:
script(string): The JavaScript code to executequiet(boolean, optional): Ultra-minimal response mode
Example:
// Get user information
var user = new GlideRecord('sys_user');
user.get('admin');
gs.print(user.getDisplayValue());2. execute_table_operation
Perform CRUD operations on ServiceNow tables with context bloat reduction.
Parameters:
operation(string): GET, POST, PUT, DELETEtable(string): Table name (e.g., 'sys_user', 'incident')sys_id(string, optional): Record sys_id for specific operationssys_ids(array, optional): Multiple sys_ids for batch operationsfields(array, optional): Specific fields to retrievequery(string, optional): Encoded query stringlimit(number, optional): Maximum records to returnstrict_fields(boolean, optional): Enable strict field validationresponse_mode(string, optional): 'minimal' for reduced response size
Examples:
// Get user records
{
"operation": "GET",
"table": "sys_user",
"fields": ["sys_id", "user_name", "email"],
"limit": 10,
"response_mode": "minimal"
}
// Create incident
{
"operation": "POST",
"table": "incident",
"data": {
"short_description": "New incident",
"priority": "3"
}
}3. execute_updateset_operation
Manage ServiceNow Update Sets with context bloat reduction.
Parameters:
operation(string): recent, contents, set_working, get_workingupdate_set_sys_id(string, optional): Update Set sys_idresponse_mode(string, optional): 'minimal' for reduced response sizequiet(boolean, optional): Ultra-minimal response mode
Examples:
// Get recent XML activity (minimal mode)
{
"operation": "recent",
"response_mode": "minimal"
}
// Set working update set
{
"operation": "set_working",
"update_set_sys_id": "abc123def456",
"quiet": true
}🔧 Context Bloat Reduction Features
Minimal Mode
Table API: Truncates large fields, limits records, removes redundant data
Update Sets: Limits to 5 records, compact summaries, flattened structure
Background Scripts: Truncates output, removes verbose logging
Quiet Mode
Ultra-minimal responses: Only success/failure status
No verbose output: Essential information only
Reduced token usage: 90%+ reduction in response size
Response Size Examples
Standard Table API: ~15KB
Minimal Table API: ~700 bytes
Quiet Update Set: ~300 bytes
Minimal Update Set: ~2.6KB
🔄 Maintenance
Update Installation
# Pull latest changes
git pull origin main
# Re-run bulletproof deployment
sudo ./bulletproof-deploy.sh
# Verify everything works
./bulletproof-verify.shClean Reinstall
# Clean everything
sudo rm -rf /usr/local/lib/node_modules/skyenet-mcp-ace
sudo rm -f /usr/local/sbin/skyenet-mcp-ace-server
# Re-run bulletproof deployment
sudo ./bulletproof-deploy.sh
# Verify
./bulletproof-verify.sh🚨 Troubleshooting
Server Won't Start
# Check server binary
ls -la /usr/local/sbin/skyenet-mcp-ace-server
# Test manually
/usr/local/sbin/skyenet-mcp-ace-server
# Check Node.js version
/usr/bin/node --versionCodex Timeout Issues
# Verify server works
echo '{"jsonrpc": "2.0", "id": 1, "method": "tools/list"}' | /usr/local/sbin/skyenet-mcp-ace-server
# Check Codex configuration
cat /etc/codex/config.toml | grep skyenetPermission Issues
# Fix permissions
sudo chmod +x /usr/local/sbin/skyenet-mcp-ace-server
# Verify ownership
sudo chown root:root /usr/local/sbin/skyenet-mcp-ace-server📊 Project Structure
SkyeNet-MCP-ACE/
├── bulletproof-deploy.sh # Bulletproof deployment script
├── bulletproof-verify.sh # Comprehensive verification
├── src/ # TypeScript source code
│ ├── index.ts # Main MCP server
│ ├── servicenow/ # ServiceNow integration
│ └── utils/ # Utility functions
├── build/ # Compiled JavaScript
└── README.md # This file🎯 Key Features
Context Bloat Reduction: Minimal and quiet modes for AI agents
Bulletproof Deployment: Handles all edge cases automatically
Multi-User Compatibility: Works for all users system-wide
Comprehensive Verification: Tests all scenarios
ServiceNow Integration: Direct API access with error handling
Update Set Management: Full lifecycle support
Table Operations: CRUD with field validation
🔒 Security
Credential Management: Separate from MCP-Connect
Field Validation: Prevents injection attacks
Error Handling: Secure error responses
System-wide Installation: Proper permissions
📈 Performance
Response Times: < 3 seconds for most operations
Memory Usage: Optimized for AI agent interactions
Token Efficiency: 90%+ reduction in context bloat
Reliability: Bulletproof deployment ensures stability
For detailed deployment instructions, see the bulletproof deployment script comments.
Available Tools
3 toolsexecute_background_scriptA
Execute server-side JavaScript in ServiceNow using Background Scripts. ⚠️ SANDBOX ONLY - executes arbitrary code. 🛡️ Auto-truncates large outputs. 📁 Use {{file:path}} for large scripts.
Inputs: script (required), scope (required), timeout_ms, include_html, +1 more.
execute_table_operationA
CRUD operations on ServiceNow tables via Table API. Supports GET/POST/PUT/PATCH/DELETE with query syntax and batch operations. ⚠️ SANDBOX ONLY - reads/modifies data. 🛡️ Auto-limits large results. Use pagination for big datasets. 📁 Use {{file:path}} for large data.
Inputs: operation (required), table (required), sys_id, sys_ids, +12 more.
execute_updateset_operationA
Manage ServiceNow update sets with lifecycle operations, XML reassignment, and working set tracking. ⚠️ SANDBOX ONLY - modifies update sets. 🛡️ Auto-limits large results. Use pagination for big datasets. 📁 Use {{file:path}} for large data.
Inputs: operation (required), name, description, scope, +14 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: execute_background_script runs JavaScript code, execute_table_operation performs CRUD on tables, and execute_updateset_operation manages update sets. There is no overlap or ambiguity between these three domains.
All tools follow a consistent verb_noun pattern with 'execute_' prefix and descriptive suffixes (background_script, table_operation, updateset_operation). The naming is uniform and predictable throughout the set.
With only 3 tools, the set feels thin for a ServiceNow automation server, potentially lacking coverage for other common operations like user management, incident handling, or workflow automation. However, the tools are well-scoped for their specific purposes.
The tools cover script execution, table operations, and update set management, but there are notable gaps in ServiceNow functionality such as user/group operations, incident/change request handling, and workflow automation. Agents may need workarounds for common tasks outside these three areas.
Related MCP Connectors
Give AI agents 30,000+ safe, token-optimized actions across Workday, SAP, Oracle + hundreds more.
Manage tickets, run agents and workflows, query tables, and search workspace knowledge.
Connect AI agents to ProductNow's context engine to search, create, review, and act.
Shared business knowledge, tools and skills for AI agents, with citations and approval controls.