Skip to main content
Glama
vparlapalli490

ServiceNow MCP Server

list_users

Retrieve and filter user accounts from ServiceNow with options for pagination, status, department, and search queries.

Instructions

List users in ServiceNow

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum number of users to return
offsetNoOffset for pagination
activeNoFilter by active status
departmentNoFilter by department
queryNoCase-insensitive search term that matches against name, username, or email fields. Uses ServiceNow's LIKE operator for partial matching.

Implementation Reference

  • Pydantic BaseModel defining the input schema/parameters for the list_users tool, including pagination (limit, offset) and filters (active, department, query).
    class ListUsersParams(BaseModel):
        """Parameters for listing users."""
    
        limit: int = Field(10, description="Maximum number of users to return")
        offset: int = Field(0, description="Offset for pagination")
        active: Optional[bool] = Field(None, description="Filter by active status")
        department: Optional[str] = Field(None, description="Filter by department")
        query: Optional[str] = Field(
            None,
            description="Case-insensitive search term that matches against name, username, or email fields. Uses ServiceNow's LIKE operator for partial matching.",
        )
  • Registration of the 'list_users' tool in the central tool_definitions dictionary used by the MCP server. Maps the tool name to its handler function (list_users_tool), input schema (ListUsersParams), return type, description, and serialization method.
    "list_users": (
        list_users_tool,
        ListUsersParams,
        Dict[str, Any],  # Expects dict
        "List users in ServiceNow",
        "raw_dict",
    ),
  • Import and re-export of the list_users function from user_tools.py in the tools package __init__.py, making it available for import from the tools module.
    from servicenow_mcp.tools.user_tools import (
        create_user,
        update_user,
        get_user,
        list_users,
        create_group,
        update_group,
        add_group_members,
        remove_group_members,
        list_groups,
    )
Behavior2/5

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

With no annotations provided, the description carries full burden but offers minimal behavioral context. It doesn't disclose whether this is a read-only operation (implied by 'List' but not explicit), pagination behavior (though schema hints at it), rate limits, authentication requirements, or what fields are returned. The description adds almost no value beyond the basic action.

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 a single, efficient sentence with zero wasted words. It's appropriately sized for a simple list operation and gets straight to the point without unnecessary elaboration.

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

Completeness3/5

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

For a list operation with rich schema coverage (100%) but no annotations or output schema, the description is minimally adequate. It states what the tool does but lacks behavioral context and usage guidance that would be helpful given the tool's purpose and sibling tools available.

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 description coverage is 100%, so the schema fully documents all 5 parameters. The description adds no additional parameter semantics beyond what's in the schema, which meets the baseline of 3 when schema coverage is high.

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 clearly states the verb ('List') and resource ('users in ServiceNow'), making the purpose unambiguous. However, it doesn't differentiate this from sibling tools like 'get_user' or 'list_groups', which would require more specificity to earn 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?

The description provides no guidance on when to use this tool versus alternatives like 'get_user' (for single user details) or 'list_groups' (for listing groups). There's no mention of prerequisites, typical use cases, or exclusion criteria.

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/vparlapalli490/MCP'

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