GithubHelp home page GithubHelp logo

uliana200407 / rest_app_project Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 8.9 MB

Сlient-server architecture app

License: Apache License 2.0

Java 60.99% Shell 20.26% Batchfile 18.75%
dto-entity-mapper java maven mock-server mysql-database postman-api spring-boot unit-testing

rest_app_project's Introduction

Rest_App_Project

To run the server we can use varios programs as Postman, CURL, Paw, Insomnia etc.

Postman requests

  • GET /api/books: Retrieve all books.
  • GET /api/books/{id}: Retrieve a book by its ID.
  • POST /api/books: Create a new book.
  • PUT /api/books/{id}: Update an existing book by its ID.
  • DELETE /api/books/{id}: Delete a book by its ID.

CURL requests in terminal

Create a book (POST request):

curl -X POST -H "Content-Type: application/json" -d '{"title":"New Book","author":"New Name","isbn":"1234567890"}' http://localhost:8080/api/books

Get a book by ID (GET request):

curl http://localhost:8080/api/books/{id}

Update a book (PUT request):

curl -X PUT -H "Content-Type: application/json" -d '{"title":"Updated Book ","author":"Updated Name","isbn":"1234567890"}' http://localhost:8080/api/books/{id}

Delete a book (DELETE request):

curl -X DELETE http://localhost:8080/api/books/{id}

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.