ezeio2:apiref:subscribe

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revisionBoth sides next revision
ezeio2:apiref:subscribe [2021-01-27 22:23] andrehezeio2:apiref:subscribe [2021-01-28 20:45] andreh
Line 110: Line 110:
  
 The STATUS updates will be sent every 10 minutes even if a faster subscription is active. The STATUS updates will be sent every 10 minutes even if a faster subscription is active.
 +
 +This is an example of what a ''STATUS'' update looks like (whitespace added for readability):
 +<code javascript>
 +{
 +  "channel": "export:2",
 +  "data": {
 +    "type": "STATUS",
 +    "serial": "ABC-123",
 +    "time": "2021-01-31T14:20:00Z",
 +    "fields": [
 +      {
 +        "1": 73.4
 +      },
 +      {
 +        "2": 8.112
 +      }
 +    ]
 +  }
 +}
 +</code>
 +
 +A ''LOGDATA'' update has the following format (whitespace added for readability):
 +<code javascript>
 +{
 +  "channel": "export:2",
 +  "data": {
 +    "type": "LOGDATA",
 +    "serial": "ABC-123",
 +    "time": "2021-01-31T14:21:15Z",
 +    "timeout": 0,
 +    "fields": [
 +      {
 +        "1": 73.3
 +      },
 +      {
 +        "2": 9.021
 +      }
 +    ]
 +  }
 +}
 +</code>
  
 **Step 3 : Request subscription changes** **Step 3 : Request subscription changes**
  • ezeio2/apiref/subscribe.txt
  • Last modified: 2021-01-28 23:49
  • by andreh