Install
$ agentstack add mcp-echelon-ai-labs-servicenow-mcp ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ● Environment & secrets Used
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
[](https://mseep.ai/app/osomai-servicenow-mcp)
ServiceNow MCP Server
A Model Completion Protocol (MCP) server implementation for ServiceNow, allowing Claude to interact with ServiceNow instances.
Overview
This project implements an MCP server that enables Claude to connect to ServiceNow instances, retrieve data, and perform actions through the ServiceNow API. It serves as a bridge between Claude and ServiceNow, allowing for seamless integration.
Features
- Connect to ServiceNow instances using various authentication methods (Basic, OAuth, API Key)
- Query ServiceNow records and tables
- Create, update, and delete ServiceNow records
- Execute ServiceNow scripts and workflows
- Access and query the ServiceNow Service Catalog
- Analyze and optimize the ServiceNow Service Catalog
- Debug mode for troubleshooting
- Support for both stdio and Server-Sent Events (SSE) communication
Installation
Prerequisites
- Python 3.11 or higher
- A ServiceNow instance with appropriate access credentials
Setup
- Clone this repository:
`` git clone https://github.com/echelon-ai-labs/servicenow-mcp.git cd servicenow-mcp ``
- Create a virtual environment and install the package:
`` python -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate pip install -e . ``
- Create a
.envfile with your ServiceNow credentials:
`` SERVICENOW_INSTANCE_URL=https://your-instance.service-now.com SERVICENOW_USERNAME=your-username SERVICENOW_PASSWORD=your-password SERVICENOW_AUTH_TYPE=basic # or oauth, api_key ``
Usage
Standard (stdio) Mode
To start the MCP server:
python -m servicenow_mcp.cli
Or with environment variables:
SERVICENOW_INSTANCE_URL=https://your-instance.service-now.com SERVICENOW_USERNAME=your-username SERVICENOW_PASSWORD=your-password SERVICENOW_AUTH_TYPE=basic python -m servicenow_mcp.cli
Server-Sent Events (SSE) Mode
The ServiceNow MCP server can also run as a web server using Server-Sent Events (SSE) for communication, which allows for more flexible integration options.
Starting the SSE Server
You can start the SSE server using the provided CLI:
servicenow-mcp-sse --instance-url=https://your-instance.service-now.com --username=your-username --password=your-password
By default, the server will listen on 0.0.0.0:8080. You can customize the host and port:
servicenow-mcp-sse --host=127.0.0.1 --port=8000
Connecting to the SSE Server
The SSE server exposes two main endpoints:
/sse- The SSE connection endpoint/messages/- The endpoint for sending messages to the server
Example
See the examples/sse_server_example.py file for a complete example of setting up and running the SSE server.
from servicenow_mcp.server import ServiceNowMCP
from servicenow_mcp.server_sse import create_starlette_app
from servicenow_mcp.utils.config import ServerConfig, AuthConfig, AuthType, BasicAuthConfig
import uvicorn
# Create server configuration
config = ServerConfig(
instance_url="https://your-instance.service-now.com",
auth=AuthConfig(
type=AuthType.BASIC,
config=BasicAuthConfig(
username="your-username",
password="your-password"
)
),
debug=True,
)
# Create ServiceNow MCP server
servicenow_mcp = ServiceNowMCP(config)
# Create Starlette app with SSE transport
app = create_starlette_app(servicenow_mcp, debug=True)
# Start the web server
uvicorn.run(app, host="0.0.0.0", port=8080)
Tool Packaging (Optional)
To manage the number of tools exposed to the language model (especially in environments with limits), the ServiceNow MCP server supports loading subsets of tools called "packages". This is controlled via the MCP_TOOL_PACKAGE environment variable.
Configuration
- Environment Variable: Set the
MCP_TOOL_PACKAGEenvironment variable to the name of the desired package.
``bash export MCP_TOOL_PACKAGE=catalog_builder ``
- Package Definitions: The available packages and the tools they include are defined in
config/tool_packages.yaml. You can customize this file to create your own packages.
Behavior
- If
MCP_TOOL_PACKAGEis set to a valid package name defined inconfig/tool_packages.yaml, only the tools listed in that package will be loaded. - If
MCP_TOOL_PACKAGEis not set or is empty, thefullpackage (containing all tools) is loaded by default. - If
MCP_TOOL_PACKAGEis set to an invalid package name, thenonepackage is loaded (no tools exceptlist_tool_packages), and a warning is logged. - Setting
MCP_TOOL_PACKAGE=noneexplicitly loads no tools (exceptlist_tool_packages).
Available Packages (Default)
The default config/tool_packages.yaml includes the following role-based packages:
service_desk: Tools for incident handling and basic user/knowledge lookup.catalog_builder: Tools for creating and managing service catalog items, categories, variables, and related scripting (UI Policies, User Criteria).change_coordinator: Tools for managing the change request lifecycle, including tasks and approvals.knowledge_author: Tools for creating and managing knowledge bases, categories, and articles.platform_developer: Tools for server-side scripting (Script Includes), workflow development, and deployment (Changesets).system_administrator: Tools for user/group management and viewing system logs.agile_management: Tools for managing user stories, epics, scrum tasks, and projects.full: Includes all available tools (default).none: Includes no tools (exceptlist_tool_packages).
Introspection Tool
list_tool_packages: Lists all available tool package names defined in the configuration and shows the currently loaded package. This tool is available in all packages exceptnone.
Available Tools
Note: The availability of the following tools depends on the loaded tool package (see Tool Packaging section above). By default (full package), all tools are available.
Incident Management Tools
- create_incident - Create a new incident in ServiceNow
- update_incident - Update an existing incident in ServiceNow
- add_comment - Add a comment to an incident in ServiceNow
- resolve_incident - Resolve an incident in ServiceNow
- list_incidents - List incidents from ServiceNow
Service Catalog Tools
- listcatalogitems - List service catalog items from ServiceNow
- getcatalogitem - Get a specific service catalog item from ServiceNow
- listcatalogcategories - List service catalog categories from ServiceNow
- createcatalogcategory - Create a new service catalog category in ServiceNow
- updatecatalogcategory - Update an existing service catalog category in ServiceNow
- movecatalogitems - Move catalog items between categories in ServiceNow
- createcatalogitem_variable - Create a new variable (form field) for a catalog item
- listcatalogitem_variables - List all variables for a catalog item
- updatecatalogitem_variable - Update an existing variable for a catalog item
- list_catalogs - List service catalogs from ServiceNow
Catalog Optimization Tools
- getoptimizationrecommendations - Get recommendations for optimizing the service catalog
- updatecatalogitem - Update a service catalog item
Change Management Tools
- createchangerequest - Create a new change request in ServiceNow
- updatechangerequest - Update an existing change request
- listchangerequests - List change requests with filtering options
- getchangerequest_details - Get detailed information about a specific change request
- addchangetask - Add a task to a change request
- submitchangefor_approval - Submit a change request for approval
- approve_change - Approve a change request
- reject_change - Reject a change request
Agile Management Tools
Story Management
- create_story - Create a new user story in ServiceNow
- update_story - Update an existing user story in ServiceNow
- list_stories - List user stories with filtering options
- createstorydependency - Create a dependency between two stories
- deletestorydependency - Delete a dependency between stories
Epic Management
- create_epic - Create a new epic in ServiceNow
- update_epic - Update an existing epic in ServiceNow
- list_epics - List epics from ServiceNow with filtering options
Scrum Task Management
- createscrumtask - Create a new scrum task in ServiceNow
- updatescrumtask - Update an existing scrum task in ServiceNow
- listscrumtasks - List scrum tasks from ServiceNow with filtering options
Project Management
- create_project - Create a new project in ServiceNow
- update_project - Update an existing project in ServiceNow
- list_projects - List projects from ServiceNow with filtering options
Workflow Management Tools
- list_workflows - List workflows from ServiceNow
- get_workflow - Get a specific workflow from ServiceNow
- create_workflow - Create a new workflow in ServiceNow
- update_workflow - Update an existing workflow in ServiceNow
- delete_workflow - Delete a workflow from ServiceNow
Script Include Management Tools
- listscriptincludes - List script includes from ServiceNow
- getscriptinclude - Get a specific script include from ServiceNow
- createscriptinclude - Create a new script include in ServiceNow
- updatescriptinclude - Update an existing script include in ServiceNow
- deletescriptinclude - Delete a script include from ServiceNow
Changeset Management Tools
- list_changesets - List changesets from ServiceNow with filtering options
- getchangesetdetails - Get detailed information about a specific changeset
- create_changeset - Create a new changeset in ServiceNow
- update_changeset - Update an existing changeset
- commit_changeset - Commit a changeset
- publish_changeset - Publish a changeset
- addfileto_changeset - Add a file to a changeset
Knowledge Base Management Tools
- createknowledgebase - Create a new knowledge base in ServiceNow
- listknowledgebases - List knowledge bases with filtering options
- create_category - Create a new category in a knowledge base
- create_article - Create a new knowledge article in ServiceNow
- update_article - Update an existing knowledge article in ServiceNow
- publish_article - Publish a knowledge article in ServiceNow
- list_articles - List knowledge articles with filtering options
- get_article - Get a specific knowledge article by ID
User Management Tools
- create_user - Create a new user in ServiceNow
- update_user - Update an existing user in ServiceNow
- get_user - Get a specific user by ID, username, or email
- list_users - List users with filtering options
- create_group - Create a new group in ServiceNow
- update_group - Update an existing group in ServiceNow
- addgroupmembers - Add members to a group in ServiceNow
- removegroupmembers - Remove members from a group in ServiceNow
- list_groups - List groups with filtering options
UI Policy Tools
- createuipolicy - Creates a ServiceNow UI Policy, typically for a Catalog Item.
- createuipolicy_action - Creates an action associated with a UI Policy to control variable states (visibility, mandatory, etc.).
Using the MCP CLI
The ServiceNow MCP server can be installed with the MCP CLI, which provides a convenient way to register the server with Claude.
# Install the ServiceNow MCP server with environment variables from .env file
mcp install src/servicenow_mcp/server.py -f .env
This command will register the ServiceNow MCP server with Claude and configure it to use the environment variables from the .env file.
Integration with Claude Desktop
To configure the ServiceNow MCP server in Claude Desktop:
- Edit the Claude Desktop configuration file at
~/Library/Application Support/Claude/claude_desktop_config.json(macOS) or the appropriate path for your OS:
{
"mcpServers": {
"ServiceNow": {
"command": "/Users/yourusername/dev/servicenow-mcp/.venv/bin/python",
"args": [
"-m",
"servicenow_mcp.cli"
],
"env": {
"SERVICENOW_INSTANCE_URL": "https://your-instance.service-now.com",
"SERVICENOW_USERNAME": "your-username",
"SERVICENOW_PASSWORD": "your-password",
"SERVICENOW_AUTH_TYPE": "basic"
}
}
}
}
- Restart Claude Desktop to apply the changes
Example Usage with Claude
Below are some example natural language queries you can use with Claude to interact with ServiceNow via the MCP server:
Incident Management Examples
- "Create a new incident for a network outage in the east region"
- "Update the priority of incident INC0010001 to high"
- "Add a comment to incident INC0010001 saying the issue is being investigated"
- "Resolve incident INC0010001 with a note that the server was restarted"
- "List all high priority incidents assigned to the Network team"
- "List all active P1 incidents assigned to the Network team."
Service Catalog Examples
- "Show me all items in the service catalog"
- "List all service catalog categories"
- "Get details about the laptop request catalog item"
- "Show me all catalog items in the Hardware category"
- "Search for 'software' in the service catalog"
- "Create a new category called 'Cloud Services' in the service catalog"
- "Update the 'Hardware' category to rename it to 'IT Equipment'"
- "Move the 'Virtual Machine' catalog item to the 'Cloud Services' category"
- "Create a subcategory called 'Monitors' under the 'IT Equipment' category"
- "Reorganize our catalog by moving all software items to the 'Software' category"
- "Create a description field for the laptop request catalog item"
- "Add a dropdown field for selecting laptop models to catalog item"
- "List all form fields for the VPN access request catalog item"
- "Make the department field mandatory in the software request form"
- "Update the help text for the cost center field"
- "Show me all service catalogs in the system"
- "List all hardware catalog items."
- "Find the catalog item for 'New Laptop Request'."
- "Show me the variables for the 'New Laptop Request' item."
- "Create a new variable named 'department_code' for the 'New Hire Setup' catalog item. Make it a mandatory string field."
Catalog Optimization Examples
- "Analyze our service catalog and identify opportunities for improvement"
- "Find catalog items with poor descriptions that need improvement"
- "Identify catalog items with low usage that we might want to retire"
- "Find catalog items with high abandonment rates"
- "Optimize our Hardware category to improve user experience"
Change Management Examples
- "Create a change request for server maintenance to apply security patches tomorrow night"
- "Schedule a database upgrade for next Tuesday from 2 AM to 4 AM"
- "Add a task to the server maintenance change for pre-implementation checks"
- "Submit the server maintenance change for approval"
- "Approve the database upgrade change with comment: implementation plan looks thorough"
- "Show me all emergency changes scheduled for this week"
- "List all changes assigned to the Network team"
- "Create a normal change request to upgrade the production database server."
- "Update change CHG0012345, set the state to 'Implement'."
Agile Management Examples
- "Create a new user story for implementing a new reporting dashboard"
- "Update the 'Implement a new reporting dashboard' story to se
…
Source & license
This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: echelon-ai-labs
- Source: echelon-ai-labs/servicenow-mcp
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.