Skip to main content
Glama

Business days between dates, working days calculator: count working days between two dates, skipping weekends and public holidays

date_business_days
Read-only

Count business (working) days between two dates, skipping weekends and the nationwide public holidays of over 100 countries (our statutory rules for US, UK, SE, DE, FR, NO, DK, FI; Nager.Date for the rest, e.g. JP, NZ, CA, AU, IN), and list the holidays skipped; or give add=N for the date N business days after (or before) a date. Use for delivery estimates, SLAs, payment terms and payroll dates. Example: from=2026-12-01. Price $0.01/call via x402 USDC or a card key (/credits), first 25 free; failed calls free. Reads or computes only and changes nothing; each call is charged, so repeats are not free.

Input Schema

NameRequiredDescriptionDefault
toNoEnd date, YYYY-MM-DD (inclusive; default: the last day of the start month); or use add
addNoBusiness days to add to from (negative to go back), instead of to
fromYesStart date, YYYY-MM-DD
countryNoHoliday calendar: a 2-letter country code or English name, e.g. SE, JP, New Zealand (default: weekends only)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / country / description
      Previous value: -"Holiday calendar: US, GB, SE, DE, FR, NO, DK or FI (default: weekends only)"New value: +"Holiday calendar: a 2-letter country code or English name, e.g. SE, JP, New Zealand (default: weekends only)"
  2. Added

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnly/openWorld/non-idempotent/non-destructive, and the description adds genuinely new context: source of holiday rules ('our statutory rules for US, UK, SE...; Nager.Date for the rest'), the fact that skipped holidays are listed, and that it 'reads or computes only and changes nothing'. Pricing ('$0.01/call', 'first 25 free', 'failed calls free', 'repeats are not free') usefully explains why idempotentHint is false despite being read-only. It stops short of describing response shape or error behavior.

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 primary function and scoping before the alternate mode and billing details, and every clause carries information. It is a single dense mega-sentence, however, and the pricing/payment clause could be split or trimmed for readability.

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 4-parameter compute tool with no output schema, the description covers inputs, alternate mode, holiday-calendar sourcing, return content (skipped holidays listed), safety profile, and billing. An agent has everything needed to call it correctly and predict roughly what comes back.

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 baseline is 3, but the description adds real meaning: it documents the `country` parameter's underlying data sources and coverage ('over 100 countries, e.g. JP, NZ, CA, AU, IN'), and gives a concrete from=2026-12-01 example. It does not restate the `to` default or the add/to mutual exclusivity, which the schema already covers.

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+resource ('Count business (working) days between two dates') and immediately scopes it as weekend/holiday-skipping, which cleanly separates it from the plain date_diff sibling. It also declares a second mode ('give add=N for the date N business days after'), so an agent knows both capabilities up front.

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?

Names concrete use cases (delivery estimates, SLAs, payment terms, payroll dates) and explains the calendar logic that selects this tool over a plain day-difference calculator. It never explicitly says when to use date_diff/date_add instead, and the add=N mode overlaps with date_add without noting the distinction.

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