Favourites accessible via API
API Endpoint or Feature
At the moment the favourites of a user are not visible in the API. The status should be visible in the following calls as isFavourite: boolean:
- GET /api/[shelves|books|chapters|pages]
- GET /api/[shelves|books|chapters|pages]/{id}
In addition a user should be able to set/unset them
- PUT /api/[shelves|books|chapters|pages]/{id}/favourite
{
isFavourite: boolean
}
Use-Case
Feature completeness of the API. Make all the information stored in Bookstack available over the API
Additional context
No response
Thanks for the request @bytepoets-ssi. Are you able to detail your specific use-case for these details? Knowing this helps think about implementation options outside of the ones proposed, while still thinking what works well for your usage. It also helps ensure efforts are going to actually required features, A use-case of "Feature completeness" is generic and could apply to any endpoints added.
The use case here is to gather the information that is stored in Bookstack and other places in a central system. Show all e.g. unread emails, Bookstack pages,... Favourite entries are highlighted accordingly and can be updated from there.
I thought of a joint endpoint but decided that adding it to the available route to retrieve a page is the more RESTful approach.