API reference

Bank holidays and company closure days in a date range

GET
/v1/holidays

Public holidays for every calendar someone in the organisation observes (see holiday_calendar on each employee), plus the organisation's own closure days. Requires holidays:read. Not paged; the range is at most 400 days.

Authorization

headerAuthorizationBearer <token>

OAuth 2.0 client credentials. Enter the client ID and client secret from Settings, API access; the token lasts one hour.

Query Parameters

from*string
Formatdate
to*string

At most 400 days after from.

Formatdate
calendar?string

One calendar key, e.g. GB-EAW, GB-SCT, ES, US-NY. Returns public holidays only.

Match^[A-Z]{2}(-[A-Z]{2,3})?$
type?string
Value in"public""company"

Response Body

Holidays in date order.

application/json
  1. response
data*array<>
curl -X GET "https://example.com/v1/holidays?from=2019-08-24&to=2019-08-24"
{  "data": [    {      "date": "2019-08-24",      "name": "string",      "type": "public",      "calendar": "string",      "applies_to": "string",      "deducts_from_leave": true,      "department": "string",      "location": "string"    }  ]}