Skip to content

satyamrs00/library

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Library API

Syntax to use the API

https://scouto-library.herokuapp.com/books/?name=<str:name> this url returns list of all the books with that name or term in the book name

https://scouto-library.herokuapp.com/books/?from_rent=<integer>&to_rent=<integer> this url returns list of books with rent in that range

https://scouto-library.herokuapp.com/books/?from_rent=<integer>&to_rent=<integer>&category=<str:category>&name=<str:name> this returns list of books with matching values as in input

https://scouto-library.herokuapp.com/transactions POST request to this with form-data in body with the syntax -

book=<name of the book>
person=<your name>
issue_date OR return_date=<date in iso format>

will update the Transaction DB with these values and return rent if return_date is provided

https://scouto-library.herokuapp.com/transactions?book=<str:book name> this returns list of people who have issued that book ( total count) + list of people who currently have that book issued ( currently issued only)( its count ) + Total rent generated by that book.

https://scouto-library.herokuapp.com/transactions?person=<str:person's name> this returns List of books issued to that person

https://scouto-library.herokuapp.com/transactions?from=<date in any format>&to=<date in any format> this returns list of books issued in that date range and the person they are issued to

(replace all values in <> to required values)

About

Internship Assessment - scouto

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published