Skip to main content
Glama
matheuscalma

servicenow-mcp

by matheuscalma

query_incidents

Search ServiceNow incidents, newest first, to find existing tickets or check on an incident number. Filter by text or state for targeted results.

Instructions

List ServiceNow incidents, newest first, optionally filtered by text and/or state.

Use this to find existing tickets before creating a new one, to check on a
ticket by number, or to answer "what incidents are open about X?".

Args:
    query_text: What to search for. An incident number ("INC0010001") matches
        exactly; anything else runs ServiceNow's keyword search over the
        incident's text fields, falling back to a substring match on
        short_description/description. Leave empty to list the most recent incidents.
    state: Filter by state. Accepts a numeric code ("1".."8") or a name such as
        "New", "In Progress", "On Hold", "Resolved", "Closed", "Canceled".
        Leave empty for any state.
    limit: Maximum number of incidents to return (1-100). Defaults to 5.

Returns:
    A list of {"number", "sys_id", "short_description", "state", "state_code",
    "urgency", "created_on"}; an empty list means nothing matched.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
stateNo
query_textNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description fully discloses behavioral details: search semantics (exact number matching vs. keyword search with substring fallback), state filter format (numeric or name), limit behavior with default, and return format. It also explains the meaning of an empty list. This is comprehensive and goes beyond a simple 'lists incidents.'

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is organized into clear sections: a one-line summary, usage guidance, parameter details, and return format. Every sentence serves a purpose, from explaining search fallback to specifying defaults. It is appropriately sized given the behavioral complexity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description is complete for a read-only query tool: it defines input semantics, output structure, and edge cases (empty list, empty query). The presence of an output schema is complemented by a human-readable description of the return fields. Given the sibling tools, it clearly fits into the workflow as the search/read operation. No gaps are apparent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must fully explain parameters. The 'Args' section does exactly that: query_text, state, and limit are each described with accepted formats, defaults, and special behavior (e.g., prefix matching for incident numbers, state code ranges). This adds significant meaning beyond the raw schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states 'List ServiceNow incidents, newest first, optionally filtered by text and/or state.' This uses a specific verb, names the resource (ServiceNow incidents), and distinguishes it from sibling tools like create_incident and update_incident by focusing on listing/querying.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly provides use cases: 'Use this to find existing tickets before creating a new one, to check on a ticket by number, or to answer "what incidents are open about X?".' This gives clear when-to-use guidance. It implies when-not-to-use (e.g., before creating) but does not explicitly name alternatives or exclude other tools, so it stops short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/matheuscalma/servicenow-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server