Simple Rest API library for inserting and retrieving books. Also using Jsoup as a webcrawler
Returns json data about a single book.
-
URL
/books/:id
-
Method:
GET
-
URL Params
Required:
id=[integer]
-
Success Response:
- Code: 200
Content:{ "bookId": 1235, "title": "title example", "description": "description example", "isbn": "isbn example", "language": "pt-br" }
- Code: 200
-
Error Response:
- Code: 404 NOT FOUND
- Code: 404 NOT FOUND
Send json data.
-
URL
/books
-
Method:
POST
-
Body Params
{ "title": "title example", "description": "description example", "isbn": "isbn example", "language": "pt-br" }
-
Success Response:
- Code: 201
Content:{ "bookId": 1235, "title": "title example", "description": "description example", "isbn": "isbn example", "language": "pt-br" }
- Code: 201
Retrieve books from https://kotlinlang.org/docs/books.html.
-
URL
/books
-
Method:
GET
-
Success Response:
- Code: 200
Content:{ "numberBooks": 2, "books": [ { "bookId": null, "title": "Kotlin in Action", "description": "Kotlin in Action teaches you to use the Kotlin language for production-quality applications. Written for experienced Java developers, this example-rich book goes further than most language books, covering interesting topics like building DSLs with natural language syntax.The book is written by Dmitry Jemerov and Svetlana Isakova, developers on the Kotlin team.Chapter 6, covering the Kotlin type system, and chapter 11, covering DSLs, are available as a free preview on the publisher Web site.", "isbn": "9781617293290", "language": "en" }, { "bookId": null, "title": "Kotlin for Android Developers", "description": "Kotlin for Android Developers is a book by Antonio Leiva showing how Kotlin can be used for creating an Android application from scratch.", "isbn": "Unavailable", "language": "en" } ] }
- Code: 200
- Eclipse - IDE
- Maven - Dependency Management
- Spring - Spring framework, JPA, Boot
- Jsoup - Web crawler
- Lombok Project - Getters and Setters generator