Skip to main content
Glama

scrapewise_preview_reapply_rules

Read-onlyIdempotent
        Runs the scraper's CURRENT post-scrape rules (its own rules, then its group's rules, plus constant
        columns) on the first stored rows of one finished run IN MEMORY and answers what a re-apply would
        change. Writes nothing. Free (no credits).

        Args:
          - jobId (string, path, required): the run's id (scraperJobStatusId) — from
            scrapewise_get_scraper_load_history.

        Returns:
          rulesHash (pass it to scrapewise_run_reapply_rules as expectedRulesHash), rowsTotal, scannedRows,
          changedRows, scanCapped (true when only the first rows were read), per column {added, updated,
          keptStale}, frozenColumns (currency-conversion outputs, never re-computed), failureRowsSkipped and
          up to 20 before/after examples.

        Examples:
          - Use when: "I changed the cleaning rules — what would change on run {jobId}?"
          - Don't use when: you want to write the values → scrapewise_run_reapply_rules.

        Error Handling:
          - 400 (CustomerError) when the run does not exist for this customer or has no data.
          - 409 when the run is not finished yet.
          - 429 when a preview is already running; try again in a moment.
          - 401 Unauthorized; 500 INTERNAL.

[runtime hint] This tool returns JSON-as-text — its response shape is dynamic (per-scraper itemsConfig, file binary, etc.) so the MCP outputSchema is omitted. Do not rely on the presence of any specific field in the response; treat the result as a string-or-object blob and parse defensively.

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": {
      "jobId": "<jobId>"
    },
    "name": "scrapewise_preview_reapply_rules"
  }
}

Input Schema

NameRequiredDescriptionDefault
jobIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare readOnly/destructive/idempotent, but the description adds material behavior the agent cannot get elsewhere: in-memory only, no credits consumed, scanCapped signalling partial reads, frozenColumns (currency-conversion outputs) never re-computed, failureRowsSkipped, and the 429 'preview already running' lock plus 409/400 conditions. That is concrete operational context beyond the structured hints.

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 key constraint is front-loaded in the first sentence, and the Args/Returns/Examples/Error Handling sections are each doing work. The Returns enumeration is long, though it is justified by the absent output schema; the indented multi-line formatting is slightly heavier than needed.

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

Completeness5/5

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

With no output schema, the description supplies the return shape (rulesHash, rowsTotal, scannedRows, changedRows, scanCapped, per-column added/updated/keptStale, frozenColumns, before/after examples) and the handoff of rulesHash to scrapewise_run_reapply_rules. Error codes and the partial-scan caveat cover what an agent needs to call and interpret this correctly.

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?

Schema coverage is 0% (jobId is a bare string), so the description must compensate; it identifies jobId as the run's scraperJobStatusId and tells the agent to source it from scrapewise_get_scraper_load_history. A format hint or example value would close the remaining gap, but the semantic meaning is delivered.

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?

The opening sentence gives a specific verb and resource: run the scraper's CURRENT post-scrape rules (own rules, then group rules, plus constant columns) on the first stored rows of one finished run IN MEMORY, and report what a re-apply would change. It also bounds scope with 'writes nothing' and 'Free (no credits)', which separates it from the write-side sibling named later.

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?

It contains an explicit 'Use when' example phrased as a user question and a matching 'Don't use when: you want to write the values → scrapewise_run_reapply_rules.' The alternative and the condition that selects it are both stated, leaving nothing to inference.

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.