Skip to main content
Glama
Jambozx

OnlineCyberTools MCP (280+ filterable tools)

time_date_difference

Read-onlyIdempotent

Calculate the difference between two dates in years, months, days, and business days. Add or subtract a duration from a date with month-clamping.

Instructions

Date Difference and Duration Calculator. Pure deterministic proleptic-Gregorian date math over UTC, with no clock/now dependency — every date is supplied by the caller. operation "diff" returns the calendar years/months/days gap between two dates, the direction (forward/backward/same), and absolute totals (days, weeks plus remainder, hours/minutes/seconds, and Mon-Fri business days, no holiday exclusion). operation "addDuration" / "subtractDuration" apply a signed years/months/weeks/days duration to a base date using month-clamp (Jan 31 + 1 month is Feb 28/29) and return the resulting date. Use this for days-between, business-day counts, or date arithmetic; use time_age_calculator for age/birthday math, time_date_calculator for weekend-skipping business-day arithmetic, and time_time_duration for HH:MM:SS clock-time math. Read-only, non-destructive, idempotent, offline-capable, rate-limited (60 req/min anonymous), no auth. Result is wrapped as operation plus data.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
operationYes"diff": gap between two dates (needs from* and to*). "addDuration"/"subtractDuration": apply duration to a base date (needs year/month/day and duration).
fromYearNoStart-date year (proleptic Gregorian). Required when operation is diff.
fromMonthNoStart-date month 1-12. Required when operation is diff.
fromDayNoStart-date day 1-31; must be a real calendar date. Required when operation is diff.
toYearNoEnd-date year. Required when operation is diff.
toMonthNoEnd-date month 1-12. Required when operation is diff.
toDayNoEnd-date day 1-31. Required when operation is diff.
yearNoBase-date year. Required when operation is addDuration or subtractDuration.
monthNoBase-date month 1-12. Required when operation is addDuration or subtractDuration.
dayNoBase-date day 1-31; must be a real calendar date. Required when operation is addDuration or subtractDuration.
durationNoSigned duration to apply. Required when operation is addDuration or subtractDuration. Each component defaults to 0 and may be negative.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
operationNoThe operation that was run, echoed back (diff, addDuration, or subtractDuration).
dataNoResult payload; shape depends on operation.
Behavior4/5

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

Annotations already declare readOnlyHint, destructiveHint, idempotentHint. Description adds non-annotation info: offline-capable, rate-limited (60 req/min), no auth, month-clamp behavior. No contradiction.

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?

Description is moderately long but well-structured, front-loading core purpose. Each sentence adds value, though could be slightly shortened. Efficient communication.

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?

Given complexity (11 params, 3 operations, output schema exists), description covers main behaviors, input requirements, return types (implied by operation), and error handling (month-clamp). Sibling differentiation is complete.

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% with descriptions for all parameters. Description adds semantics by explaining operation enum behavior and duration object meaning (signed, month-clamp), going beyond schema.

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 description clearly states the tool calculates date differences and duration arithmetic using proleptic-Gregorian date math, with specific operations (diff, addDuration, subtractDuration). It distinguishes itself from siblings in the usage guidelines section.

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?

Explicitly states when to use this tool (days-between, business-day counts, date arithmetic) and when to use alternative siblings (time_age_calculator, time_date_calculator, time_time_duration). Provides clear direction.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Jambozx/onlinecybertools-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server