Skip to main content
Glama
rag-mcp-server

rag-mcp-server

by supu02

Count days between two dates

days_between
Read-onlyIdempotent

Calculate the number of calendar days between two ISO dates; returns a negative value if the end date is earlier than the start date.

Instructions

Number of calendar days from start_date to end_date (negative if end_date is earlier).

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": {
      "start_date": "<start_date>",
      "end_date": "<end_date>"
    },
    "name": "days_between"
  }
}

Input Schema

NameRequiredDescriptionDefault
end_dateYesISO date, e.g. "2027-03-31"
start_dateYesISO date, e.g. "2027-03-31"

Output Schema

NameRequiredDescriptionDefault
daysYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, and openWorldHint=false, so the safety profile is covered. The description adds the genuinely useful sign behavior for reversed date order, but says nothing further about edge cases such as identical dates (presumably 0) or how date boundaries/timezones are treated.

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?

A single sentence with the core computation front-loaded and the sign rule parenthetically appended. No filler, nothing repeated from the schema.

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?

For a two-parameter arithmetic utility with an output schema and full annotation coverage, this is nearly complete — the return type needs no explanation and both inputs are described. The only shortfall is absent usage routing against the sibling date tool.

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% and both parameters document the ISO format, so the baseline is 3. The description goes beyond that by establishing the direction of subtraction — start_date is the origin and end_date the target — which is meaning the schema itself does not carry.

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?

The description states a specific computation over two named inputs (start_date to end_date) and clarifies the sign convention, so an agent knows exactly what it returns. It does not explicitly contrast itself with the sibling add_to_date, which shifts rather than measures dates, leaving that differentiation to inference.

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

Usage Guidelines2/5

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

There is no explicit when-to-use or when-not-to-use guidance. An agent must infer that this measures elapsed days while add_to_date offsets a date; nothing in the text states that choice or mentions any preconditions.

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