DSL4 DigitalPlatform / Sign in ↗ES
DEVELOPER INFRASTRUCTURE / DATA API

Local calendars. One software interface.

Spanish national, regional and municipal holiday data through a JSON API, built for payroll, scheduling and applications that need to understand local working days.

FestivosAPI

Released

DSL4-owned developer API. Consult the live coverage endpoint for current calendar coverage and data states.

FestivosAPI current website capture
Expand the product preview for a full-size view.
THE PRODUCT

What it solves.

A national calendar cannot answer whether a particular town observes a local holiday. FestivosAPI reconciles official calendars and municipal identifiers into a consistent interface that other software can consume.

THE ENGINEERING

How it works.

Cloudflare Workers serve the API, with D1 holding calendar data, municipal records and API usage counters. Scheduled refreshes collect source data. Exact municipal-name matching resolves official records to INE identifiers, while explicit coverage states distinguish available data, verified absence of a separate local holiday and unresolved coverage.

Cloudflare WorkersCloudflare D1JSON APIMunicipal reconciliation
WHO IT IS FOR

Who it’s for.

FestivosAPI is for developers of payroll, HR and scheduling software that must know whether a date is a working day in a particular Spanish municipality. It replaces maintaining your own list of regional and local holidays, and suits teams that store INE municipality codes or can resolve a name to one once.

FEATURES

What it does.

Answer a single date

GET /v1/is-holiday takes a date and a municipality and says whether that day is a holiday there. GET /v1/next returns the next upcoming holiday, counting from today or from a date you supply.

Full calendar for a municipality

GET /v1/holidays merges national, regional, island (where applicable) and local holidays into one sorted list. Each entry carries its scope, a legal basis and a link to the BOE, gazette or open-data source it came from.

Find the right municipality

GET /v1/municipios searches the registry by name, autonomous community or province and returns INE codes you can cache. Endpoints also accept an exact or unambiguous name, such as San Cristóbal de La Laguna.

Machine-readable documentation

An OpenAPI 3.1 contract is published at /openapi.json and a short llms.txt summary for AI agents at /llms.txt. The documentation page includes copy-paste examples in curl, JavaScript and Python.

CLOUDFLARE & PRODUCT ARCHITECTURE

Inside the system.

A data product at the edge

The Worker handles authenticated API requests and tier-based daily limits. D1 stores the structured calendar and usage data; clients consume a stable JSON interface instead of maintaining separate gazette parsers.

Precision before apparent completeness

Name reconciliation uses exact matching. Ambiguous or unresolved municipalities are reported rather than guessed, and coverage is exposed separately from the holiday response.

Built to be maintained

Quarterly and annual refresh scheduling supports calendar updates. Source provenance and coverage reports make refresh gaps visible, which matters as consuming applications depend on successive calendar years.

AVAILABILITY

Status, pricing and access.

POST /v1/signup issues a free key instantly, with no email, allowing 100 requests a day. Basic costs €9 a month for 20,000 requests a day with email support; Pro costs €19 a month for 200,000 with priority support. Limits reset at midnight UTC, and an existing free key can be upgraded in place.

FAQ

Common questions.

What does local_fiestas_declared mean?
Each holidays response returns true when the municipality has local-holiday data, false when it has been checked and declares no separate municipal holiday, and null when it has not yet been checked. /v1/coverage reports coverage by region.
How do I authenticate?
Send the key in the X-API-Key header, or as an api_key query parameter where headers are inconvenient. Responses carry X-RateLimit-Limit and X-RateLimit-Remaining headers, and a 429 response means the day’s cap has been reached.
What happens if I cancel a paid plan?
When the Stripe subscription ends, the key linked to it returns to the free tier rather than being deleted, so the same key keeps working within the free limit of 100 requests a day.
← All products