# timeanddate public holidays and observances by country API

Get timeanddate Holidays data via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Apish, pass parameters such as country, output, raw, and retrieve structured data including source country slug, requested year, holiday or observance date, entry name, and source entry classification for calendar context, and follow-up calculations.

Documentation: https://openany.si/timeanddate/timeanddate-public-holidays-and-observances-by-country-api/2f708b78-9918-4a34-ba73-5dcd3e14e534/
API ID: 2f708b78-9918-4a34-ba73-5dcd3e14e534
Provider: apish
Contract revision: 3
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/apish/timeanddate/v1/holidays
Page update time: 2026-12-03T02:45:13.683Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0.002 / billing credit
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract.
Contract update time: 2026-12-03T02:45:12.186Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "rules",
  "parameters": [],
  "policy_version": 2,
  "sale": {
    "addons": [],
    "base_price_micro_usd": "0",
    "max_cost_micro_usd": "2000",
    "quantities": [
      {
        "id": "upstream_credits",
        "label": "Actual API.SH credits used",
        "max_quantity": "1",
        "measure": "value",
        "pointer": "/credits_used",
        "price_micro_usd": "2000",
        "quantity_scale": 0,
        "source": "response",
        "unit": "credit",
        "unit_quantity": "1"
      }
    ],
    "rounding": "ceil",
    "variants": []
  }
}
```

## Usage and limits
## timeanddate Holidays API

country uses timeanddate’s country slug such as us, uk or germany, rather than assuming the Calendar endpoint’s ISO lookup. year defaults to this year. types accepts documented comma-separated categories including national, local and observance groups. Preserve each entry’s type and categories when displaying dates.

## What You Can Build

- **Calendar context**: Retain the requested date range and returned source context when displaying calendar information.
- **Follow-up calculations**: Use explicit source conventions and the returned identifiers or dates when planning a follow-up calculation.

## Returned Data

| Field | Meaning |
| --- | --- |
| `country` | Source country slug |
| `year` | Requested year |
| `items[].date` | Holiday or observance date |
| `items[].name` | Entry name |
| `items[].type` | Source entry classification |
| `items[].url` | Source details URL |

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "timeanddate public holidays and observances by country API request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {}
    },
    "query": {
      "type": "object",
      "properties": {
        "country": {
          "type": "string",
          "description": "timeanddate country slug (us, uk, germany, india...; see /timeanddate/v1/holiday-countries)."
        },
        "year": {
          "type": "integer",
          "description": "Year (default: this year)."
        },
        "types": {
          "type": "string",
          "description": "Categories, comma-separated: national, local, local_observance, important_observance, common_observance, other_observance, season, clock_change, worldwide, united_nations, christian, christian_more, jewish, jewish_more, muslim, hindu, orthodox, sport."
        },
        "raw": {
          "type": "string",
          "description": "0 leaves out the bulky `raw` source blocks (often 10-30x smaller).",
          "enum": [
            "0",
            "1"
          ]
        },
        "fields": {
          "type": "string",
          "description": "Comma-separated fields to return, e.g. `posts.id,posts.title`. Call metadata is always included."
        },
        "fresh": {
          "type": "string",
          "description": "1 skips the 24-hour cache and fetches live.",
          "enum": [
            "1"
          ]
        },
        "output": {
          "type": "string",
          "description": "JSON only for this OpenAny product. CSV and NDJSON exports are not supported; omit output or send json.",
          "enum": [
            "json"
          ]
        },
        "records": {
          "type": "string",
          "description": "With output=csv|ndjson: the top-level list to turn into rows (e.g. `reviews`), or `.` for the whole object as one row."
        }
      },
      "required": [
        "country"
      ]
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "applied_filters": {
      "type": "object",
      "properties": {
        "types": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "cached": {
      "type": "boolean"
    },
    "count": {
      "type": "integer"
    },
    "country": {
      "type": "string"
    },
    "credits_used": {
      "type": "integer"
    },
    "fetched_at": {
      "type": "string"
    },
    "items": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "categories": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "date": {
            "type": "string"
          },
          "details": {
            "type": "null"
          },
          "name": {
            "type": "string"
          },
          "type": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "weekday": {
            "type": "string"
          }
        }
      }
    },
    "title": {
      "type": "string"
    },
    "url": {
      "type": "string"
    },
    "year": {
      "type": "integer"
    }
  }
}
```

## Request example
Scenario: Official example · Live API.SH response · Minimal request
```bash
curl \
  'https://api.openany.si/v1/agent-apis/apish/timeanddate/v1/holidays?country=us&output=json&raw=0&types=national&year=2026' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Example from the provider's documentation. Field values in your results will differ.
Sample response · Documented HTTP 200
```json
{
  "applied_filters": {
    "types": [
      "national"
    ]
  },
  "cached": false,
  "count": 12,
  "country": "us",
  "credits_used": 1,
  "fetched_at": "2026-11-19T12:20:16.562Z",
  "items": [
    {
      "categories": [
        "national"
      ],
      "date": "2026-01-01",
      "details": null,
      "name": "New Year's Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/new-year-day",
      "weekday": "Thursday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-01-19",
      "details": null,
      "name": "Martin Luther King Jr. Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/martin-luther-king-day",
      "weekday": "Monday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-02-16",
      "details": null,
      "name": "Presidents’ Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/washington-birthday",
      "weekday": "Monday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-05-25",
      "details": null,
      "name": "Memorial Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/memorial-day",
      "weekday": "Monday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-06-19",
      "details": null,
      "name": "Juneteenth",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/juneteenth",
      "weekday": "Friday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-07-03",
      "details": null,
      "name": "Independence Day (substitute)",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/independence-day",
      "weekday": "Friday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-07-04",
      "details": null,
      "name": "Independence Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/independence-day",
      "weekday": "Saturday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-09-07",
      "details": null,
      "name": "Labor Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/labor-day",
      "weekday": "Monday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-10-12",
      "details": null,
      "name": "Columbus Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/columbus-day",
      "weekday": "Monday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-11-11",
      "details": null,
      "name": "Veterans Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/veterans-day",
      "weekday": "Wednesday"
    },
    {
      "categories": [
        "national"
      ],
      "date": "2026-11-26",
      "details": null,
      "name": "Thanksgiving Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/thanksgiving-day",
      "weekday": "Thursday"
    },
    {
      "categories": [
        "national",
        "christian"
      ],
      "date": "2026-12-25",
      "details": null,
      "name": "Christmas Day",
      "type": "Federal Holiday",
      "url": "https://www.timeanddate.com/holidays/us/christmas-day",
      "weekday": "Friday"
    }
  ],
  "title": "Holidays and Observances in the United States in 2026",
  "url": "https://www.timeanddate.com/holidays/us/2026",
  "year": 2026
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Common questions
### Is country always an ISO code?
No. Use timeanddate country slugs such as us, uk or germany.

### Can I combine several categories?
Yes. Pass supported types as a comma-separated list.

### Are observances necessarily public holidays?
No. Keep each entry’s type and category context.

### What year is used by default?
This year; set year to choose another supported year.

### How do I bypass cached results?
Pass fresh=1. A cache bypass retrieves available source data; it does not make unpublished or restricted records available.

### Can I request CSV or NDJSON?
This OpenAny implementation serves JSON only. Omit output or set output=json.

## Available implementations
- apish: https://openany.si/timeanddate/timeanddate-public-holidays-and-observances-by-country-api/2f708b78-9918-4a34-ba73-5dcd3e14e534/

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
