Skip to main content
Glama
rahulkr
by rahulkr

toggle_talkback

Control Android accessibility by enabling or disabling TalkBack service for testing and development workflows.

Instructions

Enable or disable TalkBack accessibility service

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
enableYes
device_serialNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • Handler function for toggle_talkback tool. Decorated with @mcp.tool() which also serves as registration. Enables/disables TalkBack by modifying the enabled_accessibility_services setting via ADB.
    @mcp.tool()
    def toggle_talkback(enable: bool, device_serial: str | None = None) -> str:
        """Enable or disable TalkBack accessibility service"""
        service = "com.google.android.marvin.talkback/com.google.android.marvin.talkback.TalkBackService"
        if enable:
            return run_adb([
                "shell", "settings", "put", "secure", 
                "enabled_accessibility_services", service
            ], device_serial)
        else:
            return run_adb([
                "shell", "settings", "put", "secure",
                "enabled_accessibility_services", ""
            ], device_serial)
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states the action but doesn't mention important behavioral traits like whether this requires USB debugging enabled, if it affects device state persistently, what permissions are needed, or potential side effects. 'Enable or disable' implies mutation but lacks safety context.

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 that states exactly what the tool does with zero wasted words. It's appropriately sized for this simple toggle operation and front-loads the core functionality.

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 this is a mutation tool with no annotations but with an output schema (which handles return values), the description is minimally adequate. It states the action but lacks important context about device requirements, permissions, and behavioral implications. For a tool that modifies device accessibility settings, more completeness would be expected.

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 description doesn't mention any parameters, while the schema has 2 parameters with 0% description coverage. However, the parameters are straightforward (a boolean 'enable' and optional 'device_serial'), and the tool's purpose inherently explains the 'enable' parameter's meaning. The description doesn't add explicit parameter semantics but the tool's simplicity keeps it at baseline.

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 ('Enable or disable') and the target resource ('TalkBack accessibility service'), providing a specific verb+resource combination. However, it doesn't explicitly differentiate from sibling tools like 'toggle_color_inversion' or 'toggle_high_contrast' that also toggle accessibility features, which prevents a perfect score.

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, nor does it mention prerequisites like device connectivity or accessibility permissions. While the context suggests it's for Android device testing, this is implied rather than stated explicitly.

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/rahulkr/r_adb_mcp_server'

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