Skip to main content
Glama
jabberjabberjabber

qBittorrent MCP Server

resume_torrent

Resume paused torrent downloads in qBittorrent using the torrent hash to continue interrupted downloads and complete file transfers.

Instructions

Resume a paused torrent.

Args: torrent_hash: Hash of the torrent to resume

Returns: Status message

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
torrent_hashYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • main.py:241-257 (handler)
    The main handler function for the 'resume_torrent' tool, decorated with @mcp.tool() to register it. It resumes the specified torrent using the qBittorrent client's torrents_resume method and returns a status dictionary.
    def resume_torrent(torrent_hash: str) -> dict[str, str]:
        """
        Resume a paused torrent.
    
        Args:
            torrent_hash: Hash of the torrent to resume
    
        Returns:
            Status message
        """
        client = get_qbt_client()
    
        try:
            client.torrents_resume(torrent_hashes=torrent_hash)
            return {"status": "success", "message": f"Torrent {torrent_hash} resumed"}
        except Exception as e:
            return {"status": "error", "message": str(e)}
  • main.py:17-38 (helper)
    Helper function to get or initialize the qBittorrent client instance, used by the resume_torrent handler.
    def get_qbt_client():
        """Get or create qBittorrent client instance."""
        global qbt_client
    
        if qbt_client is None:
            host = os.getenv("QBITTORRENT_HOST", "http://localhost:8080")
            username = os.getenv("QBITTORRENT_USERNAME", "admin")
            password = os.getenv("QBITTORRENT_PASSWORD", "adminadmin")
    
            qbt_client = qbittorrentapi.Client(
                host=host,
                username=username,
                password=password
            )
    
            try:
                qbt_client.auth_log_in()
            except qbittorrentapi.LoginFailed as e:
                raise Exception(f"Failed to login to qBittorrent: {e}")
    
        return qbt_client
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It states the action ('Resume a paused torrent') but lacks behavioral details such as required permissions, whether it's idempotent (resuming an already active torrent), side effects, or error conditions. The description adds minimal context beyond the basic action.

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 appropriately sized and front-loaded: the first sentence states the purpose clearly, followed by structured 'Args' and 'Returns' sections. Every sentence earns its place by providing essential information without redundancy. The structure enhances readability and efficiency.

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 tool's low complexity (one parameter, simple action) and the presence of an output schema (implied by 'Returns: Status message'), the description is mostly complete. It covers the action, parameter, and return value. However, it lacks behavioral context (e.g., error handling) and usage guidelines, which are minor gaps for this straightforward tool.

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?

Schema description coverage is 0%, so the description must compensate. It adds meaning by specifying 'torrent_hash' as 'Hash of the torrent to resume', clarifying the parameter's purpose. However, it doesn't provide format details (e.g., hash length, encoding) or examples, leaving gaps in documentation. With 0% coverage and one parameter, this meets the baseline but doesn't fully compensate.

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 ('Resume') and resource ('a paused torrent'), making the purpose immediately understandable. It distinguishes from siblings like 'pause_torrent' and 'delete_torrent' by specifying the opposite action. However, it doesn't explicitly differentiate from all siblings (e.g., 'download_torrent' might also involve torrent manipulation).

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. It doesn't mention prerequisites (e.g., torrent must be paused), exclusions (e.g., cannot resume if deleted), or comparisons to siblings like 'pause_torrent' for toggling states. Usage is implied but not explicitly stated.

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/jabberjabberjabber/qbit-mcp'

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