Giter Club home page Giter Club logo

javaee-rest-example's Introduction

REST API Example with Wildfly

Usage

Download Wildfly.

Uncompress it.

Start WildFly:

./wildfly-8.2.0.Final/bin/standalone.sh

Compile, test and deploy this project:

 mvn clean package test wildfly:deploy

In the main path you will find your normal web project. In this case you have a REST Console so that you can play with the REST API: http://localhost:8080/RESTExample/

In the /api/ you find the root path where all the API is located for all the services. For now there's only one service, that is the purchase simulation: http://localhost:8080/RESTExample/api/

The service for the purchase simulation is in the /api/decision/ So far there's only two operations supported: GET and POST.

GET on the main path of /api/decisions/ will return all the users. GET on a concrete user will return the current balance of that user: RESTExample/api/decision?email=[email protected]

POST : You can add a new purchase for a new user that will be identified by its email. It expects a JSON object with the following format: {"email":"[email protected]","first_name":"Eduard","last_name":"Cespedes","amount":300}

Contributors

License

BSD. See the LICENSE file at the root of this repository.

javaee-rest-example's People

Contributors

haduart avatar

Watchers

James Cloos 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.