An API for getting today's hours or getting hours for all days within a range of dates.

Usage:

HTTP GET /api/hours.json

{
    "date": "2016-06-03",
    "is_closed": false,
    "open_time": "07:00:00",
    "close_time": "00:00:00",
    "has_exception": false,
    "exception_title": null,
    "exception_message": null,
    "is_currently_open": true
}

You can also provide two query params start and stop of the format YYYY-MM-DD and get a range of days hours.

HTTP GET /api/hours.json?start=2016-01-01&stop=2016-01-31

[
    {
        "date": "2016-01-01",
        "is_closed": true,
        "open_time": null,
        "close_time": null,
        "has_exception": true,
        "exception_title": "New Year's Day",
        "exception_message": "CLOSED",
        "is_currently_open": null
    },
    {
        "date": "2016-01-02",
        "is_closed": false,
        "open_time": "08:00:00",
        "close_time": "18:00:00",
        "has_exception": true,
        "exception_title": "New Student Orientation",
        "exception_message": "Services limited to Learning Commons",
        "is_currently_open": null
    },
    .
    .
    .
]
GET /api/hours/
HTTP 200 OK
Allow: GET, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "date": "2020-10-30",
    "is_closed": false,
    "open_time": "07:00:00",
    "close_time": "00:00:00",
    "has_exception": false,
    "exception_title": null,
    "exception_message": null,
    "is_currently_open": false
}