Skip to content

API Documentation

jmthorn edited this page Apr 4, 2021 · 31 revisions

API-Routes

This web app uses the following API routes to dynamically update the page to create a single-page-app-like feel for the user for specific features.

Reviews

  • A logged in user may delete one of their own reviews, removing it from the list of visible reviews without causing a refresh/redirect. Create:

    • POST /books/:id/reviews

    Edit: (the reviews or the stars)

    • PUT /books/:id/reviews/:id

    Delete:

    • `DELETE /books/:id/reviews/:id

ReadStatus

  • A logged in user can add a status to indicate whether they are "Read", "Currently Reading" or "Want to Read". Create:

    • POST /readstatus

    Edit:

    • PUT /readstatus/:id

Bookshelf

  • A logged in user can add/remove a Book to their Bookshelf on the specific book's page via a custom category or through a Tag(Want to Read/Genre/etc). Create:

    • GET /bookshelf

    Create:

    • POST /bookshelf

    Edit:

    • PUT /bookshelf/:id

    Delete:

    • `DELETE /bookshelf/:id

Clone this wiki locally