Skip to main content
Glama
debanshd

Tavily Web Search MCP Server

by debanshd

read_clipboard

Retrieve text from your macOS clipboard to use as input for web searches, enabling quick information lookup without manual typing.

Instructions

Read and return the current clipboard text (macOS). Uses pbpaste.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • server.py:65-77 (handler)
    The main handler function for the 'read_clipboard' tool. It is registered via the @mcp.tool() decorator, which also handles schema inference from type hints and docstring. The function uses subprocess to execute 'pbpaste' on macOS to retrieve and return the clipboard text.
    @mcp.tool() def read_clipboard() -> str: """Read and return the current clipboard text (macOS). Uses `pbpaste`.""" try: completed = subprocess.run([ "pbpaste" ], check=False, capture_output=True, text=True) if completed.returncode != 0: return f"❌ Failed to read clipboard (pbpaste exited {completed.returncode})." return (completed.stdout or "").strip() except Exception as e: return f"❌ Error reading clipboard: {str(e)}"

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/debanshd/AIE7-MCP-Session'

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