Skip to main content
Glama
Datris MCP Server

Datris MCP Server

set_tap_state

Overwrite or reset a tap's incremental-sync state to rewind a cursor and re-fetch a window, or clear state so the next run performs a full first-run fetch.

Instructions

Overwrite or reset a tap's incremental-sync state. Pass state (a JSON object) to set the bookmark the next run receives via DATRIS_TAP_STATE — e.g. rewind a cursor so a window is re-fetched. Pass reset: true to delete the state entirely: the next run sees no DATRIS_TAP_STATE and does a full first-run fetch. The state shape is defined by the tap's own script (read its code via get_tap to see what keys it expects). Only use this on explicit request or to recover a broken cursor — normal runs manage state themselves, committing it only after a successful run. If this Datris instance's agent policy requires a person to approve this action, the call does NOT perform it: it returns status pending_approval with an approvalId. Tell the user it is waiting for approval in Datris, then poll get_approval with that id (pause with wait_seconds between polls) — do not re-issue the action.

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

Input Schema

NameRequiredDescriptionDefault
nameYesName of the tap
resetNoIf true, delete the stored state entirely (next run = full first-run fetch). Ignores `state`.
stateNoThe state object the next run should receive. Must match the keys the tap's script reads from DATRIS_TAP_STATE.
reasonNoOptional one-line reason for this change, recorded in the platform's audit log and shown to anyone asked to approve it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/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: it discloses the next-run semantics of DATRIS_TAP_STATE, the reset-to-first-run behavior, the fact that normal runs commit state only after success, and a full approval flow (pending_approval status, approvalId, poll get_approval with wait_seconds, do not re-issue).

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 action, then mode semantics, then the caution, then the approval branch — a logical order. It is fairly dense, and the approval sentence is long, but nearly every clause carries actionable information.

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 mutation tool with no annotations and no output schema, nothing essential is missing: input modes, state shape provenance, safety caution, and the asynchronous approval protocol including the correct follow-up tool are all described.

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 100%, so parameters are already documented. The description nonetheless adds meaning: a concrete use case for `state` (rewinding a cursor to re-fetch a window) and the pointer to read the tap's script via get_tap to learn which keys are expected.

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 — 'Overwrite or reset a tap's incremental-sync state' — and immediately clarifies the two modes (set a bookmark vs. delete state). An agent can distinguish this from get_tap_state and run_tap based on the description alone.

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 an explicit caution: 'Only use this on explicit request or to recover a broken cursor — normal runs manage state themselves.' It also routes the agent to get_tap for discovering the expected state shape, so both when-to-use and where-to-look are covered.

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