INNER CODE UNIT · Python

browser_take_screenshot

feder-cr/Jobs_Applier_AI_Agent_AIHawk · src/aihawk/mcp/server.py:514

async def browser_take_screenshot(browser: Browser = None) -> Image:
    """One screenshot of this browser's page, on demand."""
    png = await work.acting(actions.screenshot_png, role=browser)
    return Image(data=png, format="png")


@mcp.tool(annotations=_says("Watch the browser window", read_only=True))
async def browser_watch(browser: Browser = None) -> Image:
    """The whole browser window as a person at the machine sees it: tab strip,
    address bar, the page and the pointer, from a live capture kept running on
    that page. For watching the work, not for acting on it: the picture
    is window pixels, so do not feed its coordinates to browser_click_at; use
    browser_take_screenshot for that.

    Starts nothing. A browser that is not open has no window, so this answers
    the sentence that says so, and the live panes - which call this many times
    a second - read that sentence as the idle pane."""
    # It REFUSES rather than answering the sentence as text, and only because

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…