added endpoint documentation

This commit is contained in:
micha 2021-11-12 10:08:20 +01:00
parent 5c91bc0619
commit 67cce422e8

View File

@ -35,6 +35,18 @@ micha@rpi:~ cd hr50-api
micha@rpi:~/hr50-api$ ./bootstrap.sh
```
# API Endpoints
There are two API endpoints available:
## /?cmd=<command>
This method allows you to send commands to the HR50. The commands can be taken from the HR50 operator's manual and do not require the trailing ";"
## /status
This method returns all avalable information in JSON
# Examples
Now you can access the API e.g. with your (HR50 Remote Display)[https://git.qrz.is/clemens/hr50-remote-display]
@ -57,4 +69,4 @@ Query the status:
```
micha@rpi:~/hr50-api$ curl http://<IP_ADDRESS>:5000/status
{"AVG":"43","BND":"15M","PEP":"60","PTT":"COR","STA":"RX","SWR":"1.9","TMP":"12C","VLT":"13.7V"}
```
```