3
0
Fork 0
mirror of https://github.com/farmOS/farmOS.git synced 2024-02-23 11:37:38 +01:00

Update listener callback docblock.

This commit is contained in:
Michael Stenta 2018-11-07 15:29:10 -05:00
parent 04f6d03d34
commit 05d3a82383

View file

@ -77,11 +77,17 @@ function farm_sensor_listener_mail($key, &$message, $params) {
}
/**
* Callback function for receiving JSON over HTTP and storing data to the {farm_sensor_data} table.
* Callback function for processing GET and POST requests to a listener.
* Handles receiving JSON over HTTP and storing data to the {farm_sensor_data}
* table. Serves data back via API requests with optional parameters.
*
* @param $public_key
* The public key of the sensor that is pushing the data.
*
* The private key should be provided as a URL query string.
*
* Use HTTPS to encrypt data in transit.
*
* JSON should be in the following format:
* {
* "timestamp": 1234567890,