Skip to main content
Glama
philogicae

rqbit Torrent Client MCP

get_torrent_stats

Retrieve detailed stats and status of a torrent using its ID or infohash to monitor progress, peers, and download information.

Instructions

Get stats and status for a specific torrent by its ID or infohash.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
torrent_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The MCP tool handler function for 'get_torrent_stats'. It is registered via the @mcp.tool() decorator and delegates to RqbitClient.get_torrent_stats().
    @mcp.tool()
    async def get_torrent_stats(torrent_id: str) -> str:
        """Get stats and status for a specific torrent by its ID or infohash."""
        logger.info(f"Getting stats/status for torrent: {torrent_id}")
        result = await rqbit_client.get_torrent_stats(torrent_id)
        if isinstance(result, str):
            error = f"Error getting torrent stats {torrent_id}: {result}"
            logger.error(error)
            return error
        return dumps(result)
  • The actual implementation of get_torrent_stats in the RqbitClient class. Makes a GET request to /torrents/{id_or_infohash}/stats/v1 on the rqbit API.
    async def get_torrent_stats(self, id_or_infohash: str) -> dict[str, Any] | str:
        """Get stats for a specific torrent."""
        return await self._safe_request("GET", f"/torrents/{id_or_infohash}/stats/v1")  # type: ignore
  • Registration of the tool via @mcp.tool() decorator on the async function get_torrent_stats.
    @mcp.tool()
    async def get_torrent_stats(torrent_id: str) -> str:
Behavior3/5

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

Implies read-only operation, but does not explicitly confirm no side effects. With no annotations, a bit more clarity would be beneficial, but the description is adequate for a simple getter.

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?

Single sentence, front-loaded with key information. No unnecessary words.

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

Completeness4/5

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

Given the simplicity (one param, output schema exists), the description covers the essential purpose and identifier. Minor omission: no mention of what 'stats' includes, but output schema likely covers it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Description notes that torrent_id can be an ID or infohash, adding meaning beyond the raw schema. However, it does not specify format or examples, which would improve clarity.

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?

Description clearly states the tool retrieves stats/status for a specific torrent by ID or infohash. However, it does not differentiate from sibling 'get_torrent_details', which could be similar.

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?

No guidance on when to use this tool versus alternatives like 'get_torrent_details' or 'list_torrents'. No context on prerequisites or typical use cases.

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/philogicae/rqbit-mcp'

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