Skip to main content
Glama
OpenCDR MCP

OpenCDR MCP

Official
by dbnz-io

opencdr_rules_get

Read-onlyIdempotent

Retrieve a signal or correlation rule by rule ID. Supply agent ID for fleet mode; leave it unset for core mode. Read-only lookup for inspecting deployed rules.

Instructions

Get a rule by id. Read-only. kind must be "signal" or "correlation".

In fleet mode, supply agent_id explicitly. Core mode leaves agent_id unset.

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": {
      "rule_id": "<rule_id>",
      "kind": "<kind>"
    },
    "name": "opencdr_rules_get"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindYes
rule_idYes
agent_idNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.0
    • addedInput schema / properties / agent_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Agent Id"
      +}
  2. First observedv0.1.0

TDQS

A3.6/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint and destructiveHint=false, so the redundant "Read-only" sentence earns nothing. However, the deployment-mode sentence (agent_id explicit in fleet mode, unset in core mode) discloses scoping behavior the annotations and schema do not convey, adding real value beyond structured fields.

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?

The definition is short and front-loads the action, with no filler sentences. The one wasted line is "Read-only," which merely restates annotation data, and the fragmentary style leaves a few clauses implicit.

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

Completeness3/5

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

For a simple three-parameter lookup with no output schema, the description covers the action and the mode-dependent scoping but says nothing about what a returned rule contains or how a missing id is surfaced, so it is adequate rather than complete.

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 carry the burden. It clarifies agent_id semantics via the fleet/core distinction and mentions the kind constraint, but rule_id is given no form, format, or uniqueness guidance, leaving one of three parameters essentially undocumented anywhere.

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?

"Get a rule by id" gives a specific verb (get) plus resource (rule) and scopes it to single-item retrieval by identifier, which distinguishes it from the list-style sibling by implication. It stops short of naming an alternative outright, so it sits just below the top mark.

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

Usage Guidelines3/5

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

The description supplies conditional usage for one parameter (fleet mode vs core mode) which implicitly tells the agent when to pass agent_id, but it never states when to use this tool versus opencdr_rules_list or other rules siblings, nor what to do when the id is unknown.

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