# Holidays API

> Bank, government and stock market holidays.

Holidays for a year, filterable by kind and state. Each entry says who observes it.

Base URL `https://api.dharun.dev`. No API key. Answers are JSON, `{ "data": ..., "meta": { ... } }`, and errors are `{ "error": { "code", "message" } }` with a matching HTTP status. Rate limit: 600 requests a minute per client.

## Holidays in a year

`GET /v1/holidays/{year}`

Parameters:

- `year` (path, required): Four-digit year.
- `type` (query): Kind of holiday. clearing days are ones on which the market trades but nothing settles. One of: bank, central_gazetted, central_restricted, market, clearing.
- `state` (query): State code or name, for example TN or Tamil Nadu.
- `month` (query): Month number, 1 to 12.

Example: https://api.dharun.dev/v1/holidays/2026?type=market

Response, with lists and long text shortened:

```json
{
  "data": [
    {
      "date": "2026-01-15",
      "weekday": "Thursday",
      "name": "Municipal Corporation Election - Maharashtra",
      "type": "market",
      "region": "NSE equities",
      "states": [
        "*"
      ]
    },
    {
      "date": "2026-01-26",
      "weekday": "Monday",
      "name": "Republic Day",
      "type": "market",
      "region": "NSE equities",
      "states": [
        "*"
      ]
    },
    {
      "date": "2026-02-15",
      "weekday": "Sunday",
      "name": "Mahashivratri",
      "type": "market",
      "region": "NSE equities",
      "states": [
        "*"
      ]
    }
  ],
  "meta": {
    "total": 20,
    "source": {
      "name": "Trading and clearing holidays, NSE equities",
      "url": "https://www.nseindia.com/resources/exchange-communication-holidays",
      "licence": "Official publication",
      "version": "2026",
      "retrieved": "2026-10-13",
      "attribution": "Trading and clearing holidays from the National Stock Exchange of India, capital market segment."
    },
    "note": "Compiled from official notifications. Dates of festivals fixed by moon sighting can change; check the issuing authority before relying on a date."
  }
}
```

## Data source

- [Bank holidays in India](https://www.rbi.org.in/Scripts/HolidayMatrixDisplay.aspx), 2026, retrieved 2026-10-13. Licence: Official publication. Bank holidays from the Reserve Bank of India holiday matrix, by regional office.
- [Central government holidays](https://dopt.gov.in/), 2026, 2027, retrieved 2026-10-13. Licence: Official publication. Gazetted and restricted holidays for central government offices, from the yearly Department of Personnel and Training memorandum.
- [Trading and clearing holidays, NSE equities](https://www.nseindia.com/resources/exchange-communication-holidays), 2026, retrieved 2026-10-13. Licence: Official publication. Trading and clearing holidays from the National Stock Exchange of India, capital market segment.

## Guides

- [Bank holidays, working days and T+1 settlement dates](https://api.dharun.dev/guides/working-days.md): Find whether a date is a bank holiday in a state, the next working day, N working days ahead, and NSE settlement dates, in Python.
