|
| 1 | +# Spring Library |
| 2 | + |
| 3 | +Library REST API developed with Java Spring boot and JWT. |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | + |
| 12 | + |
| 13 | + |
| 14 | + |
| 15 | + |
| 16 | + |
| 17 | + |
| 18 | +## API Reference |
| 19 | + |
| 20 | +#### Get a book |
| 21 | + |
| 22 | +```http |
| 23 | + GET /books/${id} |
| 24 | +``` |
| 25 | + |
| 26 | +| Parameter | Type | Description | |
| 27 | +| :-------- | :------- | :------------------------- | |
| 28 | +| `Id` | `int` | **Required**. Search a specific book with an Id. |
| 29 | + |
| 30 | +#### Get all books |
| 31 | + |
| 32 | +```http |
| 33 | + GET /books/all |
| 34 | +``` |
| 35 | + |
| 36 | +| Parameter | Type | Description | |
| 37 | +| :-------- | :------- | :-------------------------------- | |
| 38 | +| `No Parameter` | | **Required**. Search all books | |
| 39 | + |
| 40 | +#### Get books by author |
| 41 | + |
| 42 | +```http |
| 43 | + GET /books/author/nameOrSurname |
| 44 | +``` |
| 45 | + |
| 46 | +| Parameter | Type | Description | |
| 47 | +| :-------- | :------- | :-------------------------------- | |
| 48 | +| `Name or surname` | `String` | **Required**. Search a book with the author's name or surname (not working right now) | |
| 49 | + |
| 50 | +### Delete a book |
| 51 | +```http |
| 52 | + Delete /books/delete |
| 53 | +``` |
| 54 | + |
| 55 | +| Parameter | Type | Description | |
| 56 | +| :-------- | :------- | :-------------------------------- | |
| 57 | +| `Id` | `int` | **Required**. Deletes a book with the specified Id. | |
| 58 | + |
| 59 | + |
| 60 | +### Save a book |
| 61 | +```http |
| 62 | + Post /books/save |
| 63 | +``` |
| 64 | + |
| 65 | +| Parameter | Type | Description | |
| 66 | +| :-------- | :------- | :-------------------------------- | |
| 67 | +| `Book` | `book` | **Required**. Saves a book with the information required. | |
| 68 | + |
| 69 | + |
| 70 | + |
| 71 | +#### Get all borrows |
| 72 | + |
| 73 | +```http |
| 74 | + GET /borrows/all |
| 75 | +``` |
| 76 | + |
| 77 | +| Parameter | Type | Description | |
| 78 | +| :-------- | :------- | :------------------------- | |
| 79 | +| `No parameter` | | **Required**. Gets all the borrows registered. |
| 80 | + |
| 81 | +### Gets a specific borrow |
| 82 | +```http |
| 83 | + Get /borrows/book/{bookId} |
| 84 | +``` |
| 85 | + |
| 86 | +| Parameter | Type | Description | |
| 87 | +| :-------- | :------- | :-------------------------------- | |
| 88 | +| `Id` | `int` | **Required**. Search a specifics borrow with a book ID | |
| 89 | + |
| 90 | +### Gets a specific borrow |
| 91 | +```http |
| 92 | + Get /borrows/student/{studentId} |
| 93 | +``` |
| 94 | + |
| 95 | +| Parameter | Type | Description | |
| 96 | +| :-------- | :------- | :-------------------------------- | |
| 97 | +| `Id` | `int` | **Required**. Search a specifics borrow with a student ID | |
| 98 | + |
| 99 | +### Saves a borrow |
| 100 | +```http |
| 101 | + Post /borrows/save |
| 102 | +``` |
| 103 | + |
| 104 | +| Parameter | Type | Description | |
| 105 | +| :-------- | :------- | :-------------------------------- | |
| 106 | +| `Borrow` | `borrow` | **Required**. Saves a borrow with the information required.| |
| 107 | + |
| 108 | +## Authors |
| 109 | + |
| 110 | +- [@BrunoMazzocchi](https://www.github.com/BrunoMazzocchi) |
| 111 | + |
| 112 | + |
| 113 | +## 🚀 About Me |
| 114 | +I'm a student looking for opportunities as a backend developer. |
| 115 | + |
0 commit comments