Skip to main content
Glama
DateTime MCP Server

DateTime MCP Server

by ryddle

date_diff

Calculate the difference between two dates in days, weeks, months, and years; omit the end date to compare against today.

Instructions

Calculate the difference between two dates. Returns the difference in days, weeks, months, and years.

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

Input Schema

NameRequiredDescriptionDefault
end_dateNoEnd date in ISO format (YYYY-MM-DD) or DD/MM/YYYY format. If omitted, uses current date.
start_dateYesStart date in ISO format (YYYY-MM-DD) or DD/MM/YYYY format

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full disclosure burden. It usefully states that results come back in four units (days, weeks, months, years), which is the main behavioral fact an agent needs, but it says nothing about negative results when start_date is later than end_date, precision/rounding of month and year values, or timezone handling.

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?

Two short sentences with zero padding: the operation is front-loaded and the return-shape sentence immediately follows. Nothing is redundant or buried.

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 tool with full schema coverage and no output schema, the definition covers both what it does and what it returns, which is the key gap it needed to fill. The remaining omission is edge-case behavior such as reversed date ordering producing negative values.

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 description coverage is 100%, so both parameters are already documented with accepted formats and the end_date default of the current date. The description adds no meaning beyond the schema, which is the expected baseline when the schema does the heavy lifting.

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 names a specific verb and resource ('Calculate the difference between two dates') and states the units returned, so the operation is unambiguous. It does not distinguish itself from the sibling tools 'datetime' or 'day_of_week', so an agent must infer the boundary from the names alone.

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

Usage Guidelines3/5

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

Usage is only implied: an agent can infer this is the tool for measuring elapsed time between two dates. There is no explicit when-to-use statement, no mention of when to prefer 'datetime' or 'day_of_week', and no stated exclusions or prerequisites.

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