Skip to main content
Glama

open_image_locally

Access and view saved Street View images by opening them directly in your system’s default application. Verify and manage local image files with ease using this tool.

Instructions

Open a saved Street View image in the default application.

Args: filename: The filename of the image to open (must exist in output directory)

Returns: Dict: A status message indicating success or failure

Raises: ValueError: If the file doesn't exist in the output directory

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filenameYes

Implementation Reference

  • Registers the 'open_image_locally' tool with the FastMCP server using the @mcp.tool() decorator.
    @mcp.tool()
  • Executes the tool logic: checks if the image file exists in the output directory, converts it to an absolute URI, opens it in the default local application using webbrowser.open, and returns a success status.
    def open_image_locally(filename: str) -> Dict[str, str]: """ Open a saved Street View image in the default application. Args: filename: The filename of the image to open (must exist in output directory) Returns: Dict: A status message indicating success or failure Raises: ValueError: If the file doesn't exist in the output directory """ # Check if file exists image_path = OUTPUT_DIR / filename if not image_path.exists(): raise ValueError(f"Image file '{filename}' does not exist in the output directory") # Convert to absolute path abs_path = image_path.absolute().as_uri() # Open in local application webbrowser.open(abs_path) return {"status": "success", "message": f"Opened {filename} in default application"}

Other Tools

Related 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/vlad-ds/street-view-mcp'

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