Giter Club home page Giter Club logo

book-api's Introduction

Spring Book API

This simple Spring Boot project provides a basic API for performing CRUD (Create, Read, Update, Delete) operations on books and authors.

Getting Started

To run the project on your local machine, follow the steps below.

Prerequisites

  • Java JDK 21
  • Maven

Installation

  1. Navigate to the project directory:

    cd book-api-main
  2. Build the project:

    ./mvnw clean install
  3. Run the application:

    java -jar target/database-0.0.1-SNAPSHOT.jar

The application will run by default at http://localhost:8080.

API Endpoints

List Books

Endpoint: GET /books

Lists all books.

List Authors

Endpoint: GET /authors

Lists all authors.

Book Details

Endpoint: GET /books/{bookId}

Gets details of a specific book.

Author Details

Endpoint: GET /authors/{authorId}

Gets details of a specific author.

Add New Book

Endpoint: POST /books

Adds a new book. The request body should contain book details.

Add New Author

Endpoint: POST /authors

Adds a new author. The request body should contain author details.

Update Book

Endpoint: PUT /books/{bookId}

Updates information for a specific book.

Update Author

Endpoint: PUT /authors/{authorId}

Updates information for a specific author.

Delete Book

Endpoint: DELETE /books/{bookId}

Deletes a specific book.

Delete Author

Endpoint: DELETE /authors/{authorId}

Deletes a specific author.

Contributing

  1. Fork this repository and clone it to your workspace.
  2. Add new features or fix bugs.
  3. Commit your changes in a branch: git commit -m 'Add new feature'
  4. Synchronize your branch with the main repository: git push origin my-feature-branch
  5. Create a Pull Request.

book-api's People

Contributors

mehmetresitcagan avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.