app icon
DateTime Tool
0.0.1

Date and time manipulation tools with Japanese holiday support. Includes relative date calculation, month start/end, and holiday check.

cazziwork/datetime-tool311 installs

DateTime Tool

Overview

DateTime Tool is a Dify plugin that provides date and time manipulation utilities
with Japanese holiday support. It includes tools for relative date calculation,
month boundary detection, and Japanese holiday checking.

Features

  • Relative Date Calculation: Add or subtract days, weeks, months, or years
    from a date
  • Business Day Support: Skip weekends and Japanese public holidays when
    calculating dates
  • Month Boundaries: Get the first or last day of any month
  • Japanese Holiday Check: Determine if a date is a Japanese public holiday
    or business day
  • Timezone Support: All tools support configurable timezones (default:
    Asia/Tokyo)

Tools

1. Add Duration to Date ()

Calculate a future or past date by adding or subtracting a duration from a base
date.

Parameters:

  • (required): Base date in format
  • (required): Number of units to add (use negative values to subtract)
  • (required): , , , or
  • (optional, default: ): When and unit is
    , only count business days (skips weekends and Japanese public holidays)
  • (optional, default: ): Timezone name

Output:

FieldTypeDescription
stringCalculated date in format
stringInput base date
numberAmount added
stringUnit used
booleanWhether business days mode was used

Example:


2. Get Month Start/End ()

Get the first or last day of a month.

Parameters:

  • (optional): Reference date in format (defaults to today)
  • (required): (first day) or (last day)
  • (optional, default: ): Timezone name

Output:

FieldTypeDescription
stringResult date in format
string or
numberYear of the result
numberMonth of the result

Example:


3. Check Japanese Holiday ()

Check if a date is a Japanese public holiday or business day.

Uses the official Japanese Cabinet Office holiday data, fetched and cached
locally for 24 hours.

Parameters:

  • (optional): Date to check in format (defaults to today)
  • (optional, default: ): Timezone name

Output:

FieldTypeDescription
stringThe date checked in format
boolean if the date is a Japanese public holiday
stringName of the holiday in Japanese ( if not a holiday)
boolean if the date is Saturday or Sunday
boolean if the date is a business day (not a weekend or holiday)
stringDay of the week in Japanese (e.g., )

Example:


Common Use Cases

1. Calculate Deadline

Calculate a deadline N business days from today:

2. Get This Month's Boundaries

Get the start and end of the current month:

3. Check Before Scheduling

Verify a date is a business day before scheduling:


Requirements

  • Python: 3.12 or higher
  • Dify Version: Compatible with Dify plugin system
  • Dependencies: pytz, python-dateutil, requests (automatically installed)

Privacy

See PRIVACY.md [blocked] for privacy and data handling information.

Contributing

For bug reports or feature requests, please contact the author: cazziwork

Changelog

Version 0.0.1

  • Initial release
  • Tools: , ,
  • Japanese holiday data from Cabinet Office (cached 24 hours)
  • Business day mode in
CATEGORY
Tool
VERSION
0.0.1
cazziwork·02/21/2026 06:15 AM
REQUIREMENTS
Maximum memory
256MB