Question: How to implement REST API with MySQL database for my application using Spring or any other tool according to the specification below: 1- To get
How to implement REST API with MySQL database for my application using Spring or any other tool according to the specification below:
1- To get the number of properties by property type
HTTP request:
GET /igse/propertycount
JSON Response:
[ {
"detached":"10" },
{ "semi-detached":"2"
}, {
"terraced":"2" },
{ "flat":"2"
}, ...
]
----------
2- To get energy usage statistics for a specific property type and the number of bedroom.
HTTP request:
GET ./igse/semi-detached/3
JSON Response:
{ "type":"semi-detached", "bedroom":"3", "average_electricity_gas_cost_per_day":"9", "unit":"pound"
}
-----------
Screenshots of my database:


Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
