Skip to main content
Glama
mfa-servicenow-mcp

mfa-servicenow-mcp

by jshsakura

get_logs

Query ServiceNow system, journal, transaction, or background logs by level, timeframe, source, user, status, or text to troubleshoot issues.

Instructions

Query ServiceNow logs. log_type: system/journal/transaction/background. Max 20 rows.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "log_type": "<log_type>"
    },
    "name": "get_logs"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameNo[background] Execution name LIKE
levelNo[system] trace|debug|info|warning|error|fatal or number
limitNo
queryNoRaw encoded query appended
stateNo[background] running|complete|cancelled
tableNo
offsetNo
sourceNo[system/background] Source LIKE
containsNoText search (message/value)
log_typeYesLog type
timeframeNoTime filterlast_24h
created_byNo[journal/transaction] User filter
field_nameNo[journal] work_notes|comments
url_containsNo[transaction] URL LIKE
record_sys_idNo[journal] Record sys_id
max_text_lengthNo
response_statusNo[transaction] HTTP status
min_response_time_msNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.25.19
    • changedInput schema / properties / level / description
      Previous value: -"[system] error|warning|info|debug"New value: +"[system] trace|debug|info|warning|error|fatal or number"
  2. Changed1 schema field changedv1.25.8
    • addedInput schema / properties / query / description
      Added value: +"Raw encoded query appended"
  3. Addedv1.21.21
  4. Removedv1.21.20
  5. First observedv1.18.41

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose one genuine behavioral limit that the schema does not: results are capped at 20 rows regardless of the limit parameter. However, it says nothing about permissions, whether output text is truncated (max_text_length exists), or what the response contains.

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?

Two short sentences, front-loaded with the resource and the discriminator, with no filler. The row-cap constraint is stated plainly and does not bury the core purpose.

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

Completeness2/5

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

For an 18-parameter tool with no annotations and no output schema, the description is too thin: it never explains that most filters are log_type-specific, how the row cap interacts with limit/offset, or what a returned log entry looks like. An agent must reverse-engineer behavior from the schema alone.

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

Parameters3/5

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

Schema coverage is 72% and the per-parameter bracketed tags ([background], [journal], [transaction]) already explain which filters apply to which log_type. The description only restates the log_type enum and the row cap, adding little meaning beyond the schema, though coverage is low enough that more compensation would have helped.

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

Purpose4/5

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

The description states a specific verb and resource ('Query ServiceNow logs') and enumerates the four log_type values, so an agent knows exactly what domain this covers. It doesn't name a sibling (e.g., sn_query) or say how it differs, so it falls short of a 5.

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

Usage Guidelines2/5

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

There is no guidance on when to choose this over sn_query or other data-access siblings, and no hint about which log_type to pick for a given question. The only usage-adjacent content is the enum listing, which is already in the schema.

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