REST API Design for getting days without resource

by DenizEng   Last Updated February 13, 2018 10:05 AM

I need to retrieve the days where there are no bookings for a given date range.

/bookings

{ "id": 1, "title": "mybooking" }

What I need is also to be able to get the list of dates without bookings.

/freedays Returns: ["2018-01-15T16:18:44.258843Z", "2019-01-15T16:18:44.258843Z"]

As the response schema is different, compared to a booking response, I think a filter on the bookings resource would not be applicable for this scenario.

What would be a good rest design for the above use case?

Tags : rest


Related Questions



Google CustomSearch API Image Search Not Working

Updated May 30, 2015 04:02 AM


RESTful way of requesting server generated resource

Updated March 31, 2016 08:02 AM