Skip to main content
Glama

TeamPredict HR Calculators

Business days between two dates

business_days_between
Read-onlyIdempotent

Count the business days (Monday to Friday, optionally skipping US federal holidays) between two dates. Use it for working-day questions such as notice periods, delivery windows, payroll runs and project lead times. Use add_business_days instead to find the date that is N business days from a start date, and days_between_dates for plain calendar days. Holidays are the 11 US federal holidays with their observed dates when one falls on a weekend; company and state holidays are not included. Valid for years 2000 to 2100.

Input Schema

NameRequiredDescriptionDefault
end_dateYesThe second date; if it is before start_date the two are swapped as a calendar date in the form YYYY-MM-DD, for example 2026-11-02.
start_dateYesThe first date as a calendar date in the form YYYY-MM-DD, for example 2026-11-02.
include_end_dateNoWhether the end date itself is counted when it is a business day. Default true.
skip_us_federal_holidaysNoWhether US federal holidays are left out of the business-day count. Default true.

Output Schema

NameRequiredDescriptionDefault
inputsYesThe inputs as used, with defaults filled in.
resultsYesThe computed numbers. Unavailable numbers are null.
summaryYesOne or two plain sentences with the headline numbers.
calculator_urlYesThe TeamPredict calculator page that shows the same calculation, where a person can change the inputs.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/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 behavior: exactly which 11 holidays are skipped, that observed dates are used for weekend holidays, that company/state holidays are excluded, and the supported year range — none of which is in the annotations.

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?

Five tight sentences, front-loaded with the core verb and scope, then routing, then the holiday caveat and year bounds. Nothing repeats the schema and no sentence is filler.

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 read-only date arithmetic tool with an output schema, 100% parameter coverage and full annotations, the description closes the remaining gaps an agent would care about: sibling disambiguation, holiday dataset scope, and valid year range.

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 the baseline is 3. The description still adds meaning beyond the schema by defining what 'skipping US federal holidays' concretely means (11 holidays, observed dates), which directly clarifies the skip_us_federal_holidays flag rather than restating it.

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 and resource ('Count the business days ... between two dates') plus the default holiday rule in the same sentence. It explicitly separates itself from add_business_days and days_between_dates, so the agent can pick it without opening schemas.

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?

Gives concrete use cases (notice periods, delivery windows, payroll runs, lead times) and names both alternatives with the condition that selects them (N business days from a start date vs. plain calendar days). It also bounds the tool: US federal holidays only, years 2000–2100.

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