Skip to main content
Glama
anki-connect-mcp
by SolarianGG

operations.cancel

operations_cancel
Destructive

Request cancellation of a queued or running long-running operation by operationId; terminal operations return requested=false, and no rollback is guaranteed.

Instructions

Request supported cancellation without claiming rollback.

Already terminal returns requested=false. Queued operations can cancel; running operations use native cancellation only. A cancellation request may lose a race with success.

Anki-Connect method operations.cancel. Scope: application. Effect: lifecycle. Completion: completed. Undo: none.

Possible errors: internalError, invalidParams, notFound, unsupportedCapability.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "operationId": "<operationId>"
    },
    "name": "operations_cancel"
  }
}

Input Schema

NameRequiredDescriptionDefault
operationIdYes`operationId` from the operation handle returned by a long-running tool (or by `operations_get`).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior5/5

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

Beyond destructiveHint=true the description discloses the genuinely important semantics: no rollback ('Undo: none'), best-effort outcome, a race condition against success, and a defined terminal-state response. It also enumerates the possible error codes, so the agent knows what failure looks like.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core constraint, then supporting conditions, then metadata and errors. The 'Scope/Effect/Completion/Undo' line is telegraphic boilerplate but informative; overall there is little waste.

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?

For a destructive, non-readOnly mutation with an accurate annotation set and no output schema, the description covers the key gaps: outcome semantics, no rollback, race behavior, and error surface. It does not describe the success response shape, but that is a minor omission.

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 100%, so the single operationId parameter is already fully documented in the schema. The description adds nothing further about the identifier (e.g. format or source beyond what the schema states), so baseline 3 applies.

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 opening sentence gives a specific verb and resource ('Request supported cancellation') and immediately bounds the claim ('without claiming rollback'). It is easily separable from siblings like operations_get, though it never names an alternative tool by name.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit conditions are given: already-terminal operations return requested=false, queued operations can cancel, running operations use native cancellation only, and the request may lose a race with success. That is strong when/when-not guidance, but no sibling alternative (e.g. collection_undo) is offered for the rollback case.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools