Skip to content

Spring boot API being consumed by React.js(Pending hateoas impl)

Notifications You must be signed in to change notification settings

esuarezz/api-product

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Some products are added by default. Basic Entity Product representation cause we are using embedded database

Example Json schema used:

{"name": "name", "description": "desc", "tags": [ "tag1", "tag12" ], "prices": { "USD": 2, "Euro": 2.40 } }

API:

Add a new product:
POST /api/v1/products/
Response HTTP -> Created if it was successful,
Response HTTP -> Conflict if a element was in the database with same name

Update a product:
PUT /api/v1/products/{id}
Response HTTP -> OK, it was updated successfully
Response HTTP -> Not found, it was not in the database the product

Set a price for product:
PUT /api/v1/products/{id}/price Response HTTP -> OK, it was updated successfully
Response HTTP -> Not found, it was not in the database the product

Get all products
GET /api/v1/products Response HTTP -> OK, List of products will be returned, it could be empty

Get a specific product by id
GET /api/v1/products/{id} Response HTTP -> OK, product will be returned Response HTTP -> Not found, it was not in the database the product

About

Spring boot API being consumed by React.js(Pending hateoas impl)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published