Skip to main content
Glama

calculate_legal_date

Calculate legal deadlines, effective dates, and vacatio legis by adding or subtracting days, months, or years from a base date or today.

Instructions

Oblicz daty na potrzeby prawne (np. terminy, daty wejścia w życie, vacatio legis).

Dodaje lub odejmuje dni, miesiące i lata od daty bazowej (lub dzisiejszej). Wartości dodatnie = przyszłość, ujemne = przeszłość.

Przykłady:

  • calculate_legal_date(days=14) - Termin 14 dni od dziś (np. termin na odwołanie)

  • calculate_legal_date(days=30, base_date="2024-06-01") - 30 dni od 1 czerwca 2024

  • calculate_legal_date(years=1, base_date="2024-01-01") - Rok po 1 stycznia 2024

  • calculate_legal_date(days=-90) - 90 dni wstecz od dziś

  • calculate_legal_date(months=6, days=15) - 6 miesięcy i 15 dni od dziś

  • calculate_legal_date(years=-5, base_date="2024") - 5 lat przed 1 stycznia 2024

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNoLiczba dni do dodania (+) lub odjęcia (-). Np. days=14 = za 14 dni, days=-14 = 14 dni temu. Domyślnie 0.
monthsNoLiczba miesięcy do dodania (+) lub odjęcia (-). Np. months=3 = za 3 miesiące, months=-6 = 6 miesięcy temu. Domyślnie 0.
yearsNoLiczba lat do dodania (+) lub odjęcia (-). Np. years=1 = za rok, years=-5 = 5 lat temu. Domyślnie 0.
base_dateNoData bazowa. Akceptowane formaty: 'YYYY-MM-DD' (np. '2024-01-15'), 'YYYY-MM' (np. '2024-01' → 2024-01-01), 'YYYY' (np. '2024' → 2024-01-01). Jeśli nie podano, używa dzisiejszej daty.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It explains adding/subtracting days, months, years and sign convention, but does not disclose limitations, error handling, or edge cases like invalid dates or business day adjustments.

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, starting with purpose, then sign convention, followed by clear examples. It is slightly long but every sentence adds value.

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?

With a simple interface, optional parameters, and an output schema, the description covers essential usage and examples. It is complete enough for typical legal date calculations.

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?

All parameters have schema descriptions (100% coverage), so baseline is 3. The description adds significant value with examples illustrating parameter combinations and sign usage, earning a 4.

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 verb 'calculate' and the resource 'dates for legal purposes,' with specific examples like deadlines and effective dates, distinguishing it from sibling tools that deal with legal acts.

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 explains when to use the tool for legal date calculations and provides examples covering common use cases. However, it lacks explicit guidance on when not to use it or comparisons to alternatives.

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/numikel/law-scrapper-mcp'

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