The Simple Stats API service is a RESTful service that will provide information about the system it is running on, namely: cpuinfo, meminfo and uptime. It is implemented as a collection of REST endpoints that use JSON messages as their data format for both requests and responses. Its implementation will emphasize simplicity and straightforwardness.
1.0
Test if the service is reachable
GET
None
Code | Response |
---|---|
200 |
PONG |
Get the version of the API that we're talking
GET
None
Code | Response |
---|---|
200 |
1 |
Display information about the CPU on the system
GET
None
Code | Description | Schema |
---|---|---|
200 |
A summary of the /proc/cpuinfo entry | |
500 |
Unexpected Error |
Display information about the memory on the system
GET
None
Code | Description | Schema |
---|---|---|
200 |
A summary of the /proc/meminfo entry | |
500 |
Unexpected Error |
Display information about the uptime of the system
GET
None
Code | Description | Schema |
---|---|---|
200 |
A summary of the /proc/uptime entry | |
500 |
Unexpected Error |
- All data exchanged with the API will be in JSON form
- The API will be implemented in Ruby
- We will use Sinatra to handle request routing
- We will use RSpec to write some tests
- We provide manual, shell, and puppet provisioning scripts, along wih a Vagrantfile, see DEPLOY.manual.md and DEPLOY.md