Method | Endpoint | Response |
---|---|---|
GET | [host]/books | Get All Books |
GET | [host]/book/{id} | Get Book by Id |
POST | [host]/book/insert | Insert Book to Database |
PUT | [host]/book/update/{id} | Update Book by Id |
DELETE | [host]/book/delete/{id} | Delete Book by Id |
- Setup .env
- Create Database (using Mysql)
- Create Table using [php artisan make:migration create_books_table]
- Create Route for all endpoints
- Create Controller Book
- Create method show books
- Create method get book by id
- Crate method insert book
- Create method delete book
- Create method update book
- Refactor Code