Skip to main content
Glama
fbdo

business-day-mcp

by fbdo

previous_business_day

Find the most recent business day before a given date, skipping weekends and public holidays. Specify country and optional subdivision for accurate results.

Instructions

Return the previous business day on/before (inclusive) or strictly before date.

Use this to move backward to the most recent working day — skipping weekends and public holidays.

Args: date: ISO 8601 date string (YYYY-MM-DD) to start from. country: ISO 3166-1 alpha-2 code (case-insensitive, normalized to upper). inclusive: When True, date itself qualifies if it is a business day. When False (default), the search starts the day before date. subdiv: Optional country-specific subdivision code (case-sensitive; see get_supported_countries). When omitted, only nation-wide holidays are considered.

Returns: dict with keys: input_date, previous_business_day, country, subdiv (only if provided), skipped_days.

Raises: ValueError: on invalid date, unknown country/subdiv, or if no business day is found within ~10 years.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dateYes
countryYes
inclusiveNo
subdivNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

No annotations are provided, but the description fully discloses behavior: it skips weekends and public holidays, has an inclusive option, raises ValueError for invalid inputs, and limits search to ~10 years. It does not mention idempotency, but that is implied for a read-only tool.

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 description is well-structured with Args, Returns, Raises sections. It is front-loaded with the main purpose. Though lengthy, each sentence adds value and no redundancy.

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?

Given the complexity (4 params, no annotations, but output schema exists), the description is very complete. It covers input, output, errors, and edge cases (inclusive, subdiv optional, 10-year limit).

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, but the description provides detailed semantics for all 4 parameters: date format, country code, inclusive boolean, subdiv with reference to get_supported_countries. This adds significant value beyond the 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 states it returns the previous business day on/before or strictly before a given date. It specifies skipping weekends and public holidays, distinguishing it from siblings like next_business_day and business_days_between.

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?

The description explicitly says 'Use this to move backward to the most recent working day' and contrasts with other tools implicitly. It does not explicitly state when not to use it, but the context is clear.

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/fbdo/business-day-mcp'

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