Skip to main content
Glama

Business day calculator

business_days
Read-onlyIdempotent

Works with business (working) days. mode "add": returns the date N business days after start_date (start_date itself is not counted; negative N goes backward; 0 returns start_date, or the next business day if start_date is not one). mode "count": counts business days from start_date to end_date, including both ends. Weekends default to Saturday and Sunday. Public holidays are NOT built in — pass them in "holidays".

Input Schema

NameRequiredDescriptionDefault
daysNoBusiness days to add (mode "add")
modeYes"add" or "count"
weekendNoWeekend days as ISO weekday numbers (1=Monday ... 7=Sunday). Default [6, 7]. Example for Friday-Saturday weekends: [5, 6]
end_dateNoYYYY-MM-DD (mode "count")
holidaysNoDates (YYYY-MM-DD) to treat as non-working days
start_dateYesYYYY-MM-DD

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so safety is covered. The description adds genuinely non-obvious behavioral detail beyond that: start_date is excluded from the add count, negative N goes backward, N=0 snaps to the next business day, count includes both ends, and weekends default to [6,7] via the weekend parameter. It does not describe the return shape/format for either mode, which is the remaining gap.

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?

The text is front-loaded with the mode definitions and then the shared configuration rules, and every sentence carries usable information. The opening 'Works with business (working) days' is mild throat-clearing and the density of clauses makes it slightly harder to scan, but there is no real padding.

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-mode date calculator with no output schema, the description covers the mode semantics, edge cases, weekend configuration and the holiday caveat that an agent needs to call it correctly. It omits what each mode returns (a date string vs. an integer count) and the behavior when end_date precedes start_date in count mode, minor but real gaps.

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 description coverage is 100%, so the baseline is 3 and the schema already carries the format and enum details. The description goes beyond it by clarifying the semantics the schema cannot express: holidays must be supplied because none are built in, days accepts negative values meaning backward travel, and start_date is not counted in add mode.

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 states a specific resource (business/working days) and enumerates both operations it supports, "add" and "count", with their exact semantics. The business-day framing (weekends, holidays) implicitly separates it from the plain calendar-day siblings date_add and date_diff, so an agent can route correctly without opening the schema.

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

Usage Guidelines4/5

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

Mode selection is spelled out unambiguously: use "add" for N business days from a start date, use "count" for a span between start_date and end_date. It also proactively warns that public holidays are not built in, which tells the agent when extra input is required. It stops short of naming a sibling alternative (e.g. date_add for plain calendar arithmetic), so no explicit exclusion is offered.

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.

Resources