Holidays
Description
Holidays manages annual holiday calendars and working-day overrides for Laravel Enso.
The package exposes endpoints for listing available years, showing all holidays for a selected year, and toggling individual days between holiday and working-day status.
It is a small administrative package intended to support date-aware business rules in Enso applications.
Installation
Install the package:
composer require laravel-enso/holidays
Run the package migrations:
php artisan migrate
Features
- Year index endpoint for available holiday calendars.
- Holiday list endpoint grouped by year.
- Toggle endpoint for marking a holiday as a working day or restoring it.
- API resources for normalized year and holiday payloads.
Usage
The package mounts its routes under holidays.*.
Each holiday resource exposes:
- formatted
date - numeric
month namedescriptionisWorkingDay
API
HTTP routes
GET api/holidaysGET api/holidays/{year}PATCH api/holidays/{holiday}/toggle
Models
LaravelEnso\\Holidays\\Models\\HolidayLaravelEnso\\Holidays\\Models\\HolidayYear
Depends On
The package does not require additional Enso backend packages beyond the host Laravel application.
Companion frontend package:
Contributions
are welcome. Pull requests are great, but issues are good too.
Thank you to all the people who already contributed to Enso!