Skip to main content
Glama

remove_mock_rule

Remove a single conditional rule from an existing mock API endpoint by its rule ID, without needing to resend the full rules array. Returns the full updated mock object with the remaining rules. Token-efficient counterpart to add_mock_rule — use this instead of update_mock when deleting one rule so other rules keep their existing database IDs and slugIds. Obtain the target ruleId from get_mock_detail.

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": {
      "projectId": "<projectId>",
      "mockId": "<mockId>",
      "ruleId": "<ruleId>"
    },
    "name": "remove_mock_rule"
  }
}

Input Schema

NameRequiredDescriptionDefault
mockIdYesDatabase ID of the mock endpoint containing the rule (obtain from list_mocks or get_mock_detail).
ruleIdYesDatabase ID of the specific rule to remove (obtain from the 'rules[].id' field in get_mock_detail).
projectIdYesDatabase ID of the project workspace (obtain from list_projects or get_mock_detail).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / mockId / description
      Previous value: -"Database ID of the mock endpoint"New value: +"Database ID of the mock endpoint containing the rule (obtain from list_mocks or get_mock_detail)."
    • changedInput schema / properties / projectId / description
      Previous value: -"Database ID of the project"New value: +"Database ID of the project workspace (obtain from list_projects or get_mock_detail)."
    • changedInput schema / properties / ruleId / description
      Previous value: -"Database ID of the rule to remove. Obtain from get_mock_detail."New value: +"Database ID of the specific rule to remove (obtain from the 'rules[].id' field in get_mock_detail)."
  2. First observed

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses the return payload ('full updated mock object with the remaining rules') and the key side-effect rationale (other rules keep their existing database IDs and slugIds, avoiding the resend-full-array pattern). It stops short of stating whether removal is irreversible or what happens if ruleId is not found, which keeps it below a 5.

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?

Three sentences, front-loaded with the action, then the return value, then the sibling routing. Every sentence contributes a distinct piece of information with no restatement of the name.

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?

A three-parameter mutation tool with no annotations and no output schema is well covered: the action, the return shape, the ID-preservation side effect, and the discovery path are all present. Only failure behavior (missing ruleId, invalid mock) is left unstated.

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 coverage is 100% and all three integer IDs are documented there, including where to obtain them. The description reinforces the ruleId sourcing but adds no new format, constraint, or edge-case meaning beyond the schema. Baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource with scope: 'Remove a single conditional rule from an existing mock API endpoint by its rule ID.' It explicitly contrasts with add_mock_rule and update_mock, so an agent can distinguish it from every sibling that touches mocks.

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

Usage Guidelines5/5

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

Gives explicit routing guidance: 'use this instead of update_mock when deleting one rule,' plus the precondition 'Obtain the target ruleId from get_mock_detail.' Both the when and the prerequisite discovery step are named, not implied.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources