Imported Upstream version 0.6.2.17
[psensor-pkg-debian.git] / src / server / description.txt
1 [DESCRIPTION]
2
3 /psensor-server is a/
4
5 It provides a JSON Web service which can be used by psensor(1) to
6 monitor remotely the hardware sensors of a computer.
7
8 It can provide information about:
9   * the temperature of the motherboard and CPU sensors (using lm\-sensors).
10   * the temperature of the Hard Disk Drives (using hddtemp).
11   * the rotation speed of the fans (using lm\-sensors).
12
13 It is also possible to connect to the psensor\-server with a browser, a
14 simple Web page is displaying the sensors information and the CPU
15 usage.
16
17 The URL http://hostname:3131/api/1.0/sensors/[id] returns a JSON
18 object containing all information about a sensor. [id] is the uniq
19 identifier of the sensor.
20
21 Here is an example of the JSON object of type 'sensor':
22
23 { "id": "lmsensor acpitz\-virtual\-0 temp1", 
24   "name": "temp1", 
25   "type": 257, 
26   "min": 47.800000, 
27   "max": 60.800000,
28   "measures": [ { "value": 47.800000, "time": 1311374873 },
29                 { "value": 49.800000, "time": 1311374878 },
30                 { "value": 49.800000, "time": 1311374883 } ],
31   "last_measure": { "value": 49.800000, "time": 1311374883 }
32 }
33
34 Fields of the type 'sensor':
35
36    * id: the uniq identifier of the sensor.
37    * name: a humean readable name of the sensor (might not be uniq).
38    * type: the type of sensor. Look at src/lib/psensor.h for the
39      different types.
40    * min: the minimal value of the sensor.
41    * max: the maximal value of the sensor.
42    * measures: all measures of the sensor.
43    * last_measure: the last value of the sensor.
44    * time: the time of a measure as the number of seconds since
45      1970/01/01.
46
47 The URL http://hostname:3131/api/1.0/sensors returns a JSON array
48 containing all JSON objects of type 'sensor'.
49
50 If run in debug mode, psensor\-server can be stopped by sending an HTTP
51 request with the URL 'http://hostname:port/api/1.0/server/stop'.
52
53 [WARNING]
54
55 psensor\-server does not provide any way to restrict the connection to
56 the HTTP server, worst, no effort has been made against malicious HTTP
57 attacks.  You should make the psensor\-server port available only to a
58 network or computer you trust by using the usual network security
59 tools of the system (for example, iptables(8) ).
60
61 [SEE ALSO]
62
63 psensor(1), sensors(1), sensors\-detect(8)