Skip to main content
Glama

get_process_by_name

Locate running processes on mobile or desktop devices by specifying a process name or partial name for dynamic instrumentation and analysis.

Instructions

Find a process by name.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesThe name (or part of the name) of the process to find. Case-insensitive.
device_idNoOptional ID of the device to search the process on. Uses smart selection when omitted.

Implementation Reference

  • The core handler function for the 'get_process_by_name' tool, decorated with @mcp.tool() for automatic registration in FastMCP. It resolves the device, enumerates processes, and searches for a matching process name (case-insensitive partial match). Returns process details if found, or an error message.
    @mcp.tool()
    def get_process_by_name(
        name: str = Field(
            description="The name (or part of the name) of the process to find. Case-insensitive."
        ),
        device_id: Optional[str] = Field(
            default=None,
            description="Optional ID of the device to search the process on. Uses smart selection when omitted.",
        ),
    ) -> dict:
        """Find a process by name."""
        device = _resolve_device_or_raise(device_id)
        for proc in device.enumerate_processes():
            if name.lower() in proc.name.lower():
                return {"pid": proc.pid, "name": proc.name, "found": True}
        return {"found": False, "error": f"Process '{name}' not found"}
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Find a process by name' implies a read-only search operation, but it doesn't disclose key traits such as whether it returns multiple matches, handles partial names, includes performance impacts, or requires specific permissions. This is inadequate for a tool with no annotation coverage.

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 waste—'Find a process by name' directly conveys the core action without unnecessary words. It is appropriately sized and front-loaded, making it easy for an agent to parse quickly.

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?

Given the tool's complexity (a search operation with 2 parameters), lack of annotations, and no output schema, the description is incomplete. It doesn't explain return values, error handling, or behavioral nuances, leaving significant gaps for the agent to infer usage in context with siblings.

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 input schema fully documents both parameters ('name' and 'device_id') with details like case-insensitivity and smart selection. The description adds no additional meaning beyond what the schema provides, such as examples or edge cases, meeting the baseline for high schema coverage.

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 'Find a process by name' clearly states the tool's purpose with a specific verb ('find') and resource ('process'), and it distinguishes the tool from siblings like 'enumerate_processes' (which lists all processes) and 'kill_process' (which terminates processes). However, it doesn't explicitly differentiate from 'get_process_by_name' itself, which is the tool's name, making it slightly less specific than a perfect 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. It doesn't mention siblings like 'enumerate_processes' for broader searches or 'get_device' for device-specific operations, nor does it specify prerequisites or exclusions. This leaves the agent with minimal context for tool selection.

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/rmorgans/frida-mcp'

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