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
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| state | No | ||
| query_text | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |