Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added New API - Library API #72

Merged
merged 2 commits into from
May 14, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions New_APIs/LibraryApi/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
26 changes: 26 additions & 0 deletions New_APIs/LibraryApi/Readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Description
It is a library API which can be use to manage library data and library management.

# Installation
First of all clone the repository and navigate to this directory. Then run the following commands
```
npm i
cd src
node index.js
```

# End Points
### GET /api/v1/books
Returns the list of all books present in the library
### POST /api/v1/books
Add books to the library and it takes body parameters
### GET /api/v1/borrowers
Returns the list of all borrowers and their details
### POST /api/v1/borrowers
Add a borrower with details
### GET /api/v1/return/:id
Deletes a borrowers record when he/she had returned it
### GET /api/v1/search
Searches for the given book in the library

This can be use in real time also if we use Mongo DB
Loading
Loading