business_days
Calculate business days accounting for weekends and regional holidays. Add, count, or find next/previous business day with support for US, UK, EU, ISO regions, and custom holidays.
Instructions
Business-day arithmetic honoring weekends and regional public holidays.
Operations: add_business_days (needs days, may be negative) | count_business_days (needs end_date, inclusive) | next_business_day | previous_business_day.
Regions: US, UK, EU, NONE (weekends only) are built in and offline. If the
optional holidays package is installed, ANY ISO country code also works
(DE, FR, CA, AU, JP, IN, ...). custom_holidays (YYYY-MM-DD list) are added.
Args: operation: One of the four operations above. start_date: Anchor date, ISO YYYY-MM-DD. days: Business days to add (add_business_days; negative allowed). end_date: End date (count_business_days), ISO. region: US | UK | EU | NONE | ISO country code. custom_holidays: Optional extra holiday dates (YYYY-MM-DD).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| days | No | ||
| region | No | US | |
| end_date | No | ||
| operation | Yes | ||
| start_date | Yes | ||
| custom_holidays | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||