Skip to main content
Glama
dev-in-black

OpenProject MCP Server

by dev-in-black

add_watcher

Add a user as a watcher to monitor updates and changes in a specific work package within OpenProject.

Instructions

Add a user as a watcher to a work package.

Args:
    work_package_id: Work package ID
    user_id: User ID to add as watcher

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
work_package_idYes
user_idYes

Implementation Reference

  • Core implementation of add_watcher: Posts to OpenProject API to add user as watcher to work package.
    async def add_watcher(work_package_id: int, user_id: int) -> dict[str, Any]:
        """Add a user as a watcher to a work package.
    
        Args:
            work_package_id: Work package ID
            user_id: User ID to add as watcher
    
        Returns:
            Updated work package with watchers information
        """
        client = OpenProjectClient()
    
        try:
            payload = {"user": build_link(f"/api/v3/users/{user_id}")}
    
            result = await client.post(
                f"work_packages/{work_package_id}/watchers", data=payload
            )
            return result
        finally:
            await client.close()
  • Tool registration via @mcp.tool() decorator. Thin wrapper delegating to work_packages.add_watcher.
    @mcp.tool()
    async def add_watcher(work_package_id: int, user_id: int):
        """Add a user as a watcher to a work package.
    
        Args:
            work_package_id: Work package ID
            user_id: User ID to add as watcher
        """
        return await work_packages.add_watcher(
            work_package_id=work_package_id, user_id=user_id
        )
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 states the action but doesn't cover critical aspects like required permissions, whether the operation is idempotent, what happens if the user is already a watcher, error conditions, or the response format. This leaves significant gaps for an agent to understand the tool's behavior.

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 front-loaded with the core purpose in the first sentence, followed by a clear parameter list. Every sentence earns its place by providing essential information without redundancy, making it appropriately sized and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity of a mutation tool with no annotations, no output schema, and low schema description coverage, the description is incomplete. It lacks details on behavioral traits, error handling, and return values, which are crucial for an agent to use the tool effectively in context with its siblings.

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 lists the parameters with brief explanations ('Work package ID' and 'User ID to add as watcher'), which adds some meaning beyond the schema's basic types. However, with 0% schema description coverage, it doesn't fully compensate by detailing format constraints, valid ranges, or examples, leaving the semantics somewhat vague.

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 verb 'Add' and the resource 'a user as a watcher to a work package', making the purpose specific and understandable. However, it doesn't explicitly differentiate from its sibling 'remove_watcher', which is a clear alternative, though the naming implies the opposite action.

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 'remove_watcher' or other work package management tools. It lacks context about prerequisites, such as user permissions or work package state, and doesn't mention any exclusions or when-not-to-use scenarios.

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/dev-in-black/openproject-mcp'

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