Created Node msg Conventions (markdown)

Raminios 2014-10-22 08:20:58 -07:00
parent 3fbfd55e3f
commit 8ebd9409a8
1 changed files with 15 additions and 0 deletions

15
Node-msg-Conventions.md Normal file

@ -0,0 +1,15 @@
There are a few reserved properties within the structure of the msg objects being passed around in node-RED.
* **msg.title** - a title giving a good representation of what the message contains.
* **msg.description** - a brief explanation of what data is contained within the message.
* **msg.data** - storage for raw, unparsed data. This may have come from an API call and is included to give more advanced users options to access data which might not have been deemed entirely neccessary for all users.
* **msg.payload** - Storage for parsed and organised data with meaningful and understandable properties for direct access by other nodes.
* **msg.lat** - Reserved for latitudes. It should be a string representation of a number between the range of -90 and 90. It can have several decimal places, but doesn't need to.
* **msg.lon** - Reserved for longitudes. It should be a string representation of a number between the range of -180 and 180. It can also have several decimal places, but doesn't need to.
* **msg.time** - Reserved for times. The time should be a javascript Date object.