Skip to main content
Glama

scrapewise_update_matcher_engine_setup_fields

Destructive
        Changes some fields of the engine setup of a group on the newer matching engine with a JSON merge patch
        (RFC 7396), without sending the whole setup: an object merges key by key, so a map keyed by scraper id
        (columnsByScraper, derivedKeysByScraper, codeKeysByScraper, ...) takes one source at a time; null
        removes a key (back to its default); a list (joins, ignoreScraperIds, ...) or a value replaces the field
        whole. All the changes of one call become ONE new version and are checked together, so related edits
        (rename a role column and re-key every source that uses it) go live together or not at all. The group's
        owner (Full key or portal) changes the fields whose writer is customer (GET include=fields); picture
        fields and engineEnabled are Scrapewise's (null on one of them is refused too). A Scrapewise admin key
        changes everything. The matcher checks the draft within about a minute.

        Args:
          - id (string, path, required): the group's id.
          - idempotency_key (string, query): REQUIRED for AI-agent keys. A new value per new change; the same
            value only to retry it. After a 4xx nothing was saved: you may retry with the SAME key.
          - body (required): editVersion (from the last read; required with patch), patch (the merge patch),
            requireIdle (default true). Do not send engineEnabled (admin/support only): from the owner a value
            other than the current state is 403 ENGINE_SWITCH_ADMIN_ONLY; the current state is a no-op.
          - customerRef (string, query, optional): only for a Scrapewise admin key in Take Over.

        Returns:
          The small setup answer: status PENDING, editVersion, saveWarnings (LIST_WIDENED_TO_ALL:<field> when a
          list that means "every source" when absent was removed). VALIDATOR_DOWN = your draft is saved and waits
          for the check; the active setup is unchanged; do not resend. A later read with REJECTED = the check
          refused the draft: the active setup is unchanged; your next save starts from the active setup, so send
          your whole change again (an UNKNOWN_KEY refusal may still go live after a matcher update until you save
          again).

        Examples:
          - Use when: "source S has no raw EAN column" -> patch {"columnsByScraper": {"S": {"ean": "eanRawNone"}}}.
          - Use when: "ignore scraper X too" -> patch {"ignoreScraperIds": [ ...the whole new list... ]}.
          - Don't use when: you replace the whole setup or restore a version -> scrapewise_update_matcher_engine_setup.

        Error Handling:
          - 400 IDEMPOTENCY_KEY_REQUIRED, ENGINE_SETUP_INVALID, UNKNOWN_SCRAPER_ID, JOB_NOT_OF_SOURCE,
            NOT_ON_NEWER_ENGINE, ENGINE_SETUP_TOO_DEEP, PHOTO_LINE_VALUE_MISSING (photoMode confirm / open while a
            picture line has no threshold). Nothing was changed.
          - 409 VERSION_CHANGED (read again, redo the edit), SETUP_FROM_DB_OFF, NOT_SEEDED, OWN_MATCH_RUNNING /
            SCRAPER_RUN_IN_PROGRESS (wait, retry with the SAME key), ENGINE_DISABLE_NEEDS_EMPTY_MATCH,
            ENGINE_ENABLE_WAITS_FOR_RETRIGGER, TAKE_OVER_ACTIVE, IDEMPOTENCY_IN_FLIGHT, ARGS_HASH_MISMATCH,
            PHOTO_SWITCH_STILL_ON (the owner takes photoMode off confirm / veto / score while photo checks are on: switch
            them off in the match setup first).
          - 403 FIELD_ADMIN_ONLY / FIELD_NOT_CUSTOMER_WRITABLE (a field the owner may not change),
            ENGINE_SWITCH_ADMIN_ONLY (engineEnabled from the owner), NOT_ON_NEWER_ENGINE (the owner's setup for a group not on it); 403 for a read-only key.
          - 413 ENGINE_SETUP_TOO_LARGE; 503 FIELD_LIST_UNKNOWN.
          - 429 OWNER_EDIT_RATE_LIMIT: more than 10 owner changes of this group in 10 minutes; wait Retry-After.
          - IDEMPOTENCY_IN_FLIGHT (an idempotency conflict): retry after a second.
          - 5xx: read again (scrapewise_get_matcher_engine_setup) before retrying.
          - 401 Unauthorized; 404 unknown group or another customer's group. Nothing was changed in each refusal.

[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": {
      "id": "<id>",
      "idempotency_key": "<idempotency_key>",
      "body": "<body>"
    },
    "name": "scrapewise_update_matcher_engine_setup_fields"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesthe group's id.
bodyYesChange some fields of the engine setup of a group (JSON merge patch, RFC 7396).
customerRefNoAdmin keys in Take Over only: the customerUniqueRef of the customer the admin works for. Required then; leave it out otherwise.
idempotency_keyYesRequired for AI-agent keys: a new value per new change, the same value only to retry it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / id / description
      Added value: +"the group's id."
  2. Added

TDQS

A4.9/5.0
Behavior5/5

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

Annotations already flag a destructive, non-idempotent mutation, and the description adds substantial behavior beyond that: merge semantics (object merges key by key, null resets to default, lists replace whole), atomicity (all edits become ONE new version and are checked together), write-permission partitioning (picture fields and engineEnabled are Scrapewise's), validator timing (~1 minute) and VALIDATOR_DOWN/REJECTED draft lifecycle. It also discloses rate limits (10 owner changes in 10 minutes, Retry-After) and idempotency-key retry rules, which are not implied by the annotations.

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?

Despite its length, it is strongly front-loaded with the merge-patch contract before Args/Returns/Examples/Error Handling, and every section is labeled. There is minor redundancy: permission restrictions on engineEnabled appear in the Args section and again in the 403 error list, and the error catalogue is long, but the repetition serves error recovery rather than padding.

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?

For a destructive nested-object mutation with no output schema, the description supplies what an agent needs: return shape (status PENDING, editVersion, saveWarnings), the VALIDATOR_DOWN/REJECTED lifecycle including that a rejected draft means resending the whole change, and refusal semantics that guarantee nothing was saved on 4xx. Combined with the runtime hint about a dynamic response, an agent can call and recover correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With schema coverage at 100%, the description still adds real meaning the schema does not: how patch values merge per key, that editVersion must come from the last read or it yields 409 VERSION_CHANGED, that requireIdle defaults to true and blocks while a run is in progress, and that engineEnabled from an owner returns 403 ENGINE_SWITCH_ADMIN_ONLY. idempotency_key's 'new value per new change, same value only to retry' contract is spelled out rather than left to the schema wording.

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 first sentence states a specific verb (changes fields), resource (engine setup of a group), scope (newer matching engine, JSON merge patch, not the whole setup), which is precise enough for an agent to distinguish it from any reader. The 'Don't use when' clause explicitly contrasts it with scrapewise_update_matcher_engine_setup (replacing the whole setup or restoring a version), so sibling differentiation is explicit rather than inferred.

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?

Usage is stated in both directions: 'Use when' examples give concrete scenarios (missing raw EAN column, adding an ignore scraper) and 'Don't use when' points to the correct sibling for whole-setup replacement or restore. It also states who may call it (owner with Full key or portal, Scrapewise admin key) and which fields each role may write.

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.