Skip to main content
Glama

mobile_click

Click on specific screen coordinates to automate Android device interactions. Use this tool to perform precise touch actions by providing X and Y coordinates for targeted UI manipulation.

Instructions

Click on a specific coordinate on the Android screen.

Args: x: X coordinate to click y: Y coordinate to click

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xYes
yYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • main.py:124-143 (handler)
    The main handler function for the 'mobile_click' tool. It performs a click at the specified coordinates after validating the device connection and UI coordinates.
    @mcp.tool()
    def mobile_click(x: int, y: int) -> str:
        """Click on a specific coordinate on the Android screen.
        
        Args:
            x: X coordinate to click
            y: Y coordinate to click
        """
        if device is None:
            return "Error: Device not initialized. Please call mobile_init() first to establish connection with Android device."
        try:
            _mobile_dump_ui()
            global ui_coords
            if (x, y) not in ui_coords:
                return "Invalid elements coordinates. Please use mobile_dump_ui to get the latest UI state first."
            
            device.click(x, y)
            return f"Successfully clicked on coordinate ({x}, {y})"
        except Exception as e:
            return f"Error clicking coordinate ({x}, {y}): {str(e)}"
  • main.py:124-124 (registration)
    The @mcp.tool() decorator registers the mobile_click function as an MCP tool.
    @mcp.tool()
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions clicking but doesn't specify whether this requires the device to be unlocked, if it's a simulated or physical click, potential side effects, or error conditions. This leaves significant gaps for a tool that interacts with a mobile interface.

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

Conciseness4/5

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

The description is efficiently structured with a clear purpose statement followed by parameter explanations. Both sentences earn their place, though it could be slightly more front-loaded by integrating parameter hints into the main description.

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?

Given the tool's moderate complexity (interactive mobile action) and the presence of an output schema (which handles return values), the description covers the basic purpose and parameters. However, with no annotations and incomplete behavioral context, it's adequate but has clear gaps in usage and operational details.

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?

The schema description coverage is 0%, but the description explicitly documents both parameters (x and y) and their purpose as coordinates. This adds meaningful context beyond the bare schema, though it doesn't specify coordinate systems, units, or valid ranges, keeping it at a baseline level.

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 action ('Click on') and target ('a specific coordinate on the Android screen'), providing a specific verb+resource combination. However, it doesn't explicitly distinguish this from sibling tools like mobile_swipe or mobile_tap, which might have similar coordinate-based interactions.

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 mobile_swipe or mobile_tap, nor does it mention prerequisites such as needing mobile_init first or context about screen coordinates. It only states what the tool does, not when it's appropriate.

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/erichung9060/Android-Mobile-MCP'

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