Commit 750cd999 authored by Peter Waher's avatar Peter Waher

Adding example.

parent 5d45055d
<?xml version="1.0" encoding="utf-8"?>
<req xmlns="urn:ieee:iot:sensordata" id="00000001" all="true"/>
<?xml version="1.0" encoding="utf-8"?>
<resp xmlns="urn:ieee:iot:sensordata" id="00000001">
<ts v="2017-09-22T15:22:33Z">
<q n="Temperature" v="12.3" u="C" m="true" ar="true"/>
<s n="SN" v="12345678" i="true" ar="true"/>
</ts>
</resp>
......@@ -168,3 +168,30 @@ list of noteable differences:
* More data is signalled using a `more` attribute, instead of a lack of a `done` attribute.
* The `cancelled` element has been removed.
* Request identities are now strings, instead of sequence numbers.
Examples
-----------------
### Simple readout
Request:
```xml
<iq type='get' from='client@example.org/1234' to='device@example.org/abcd' id='R0001'>
  <req xmlns="urn:ieee:iot:sensordata" id="00000001" all="true"/>
</iq>
```
Response:
```xml
<iq type='result' from='device@example.org/abcd' to='client@example.org/1234' id='R0001'>
<resp xmlns="urn:ieee:iot:sensordata" id="00000001">
<ts v="2017-09-22T15:22:33Z">
<q n="Temperature" v="12.3" u="C" m="true" ar="true"/>
<s n="SN" v="12345678" i="true" ar="true"/>
</ts>
</resp>
</iq>
```
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment