<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to RetrieveByDevice</title><link>https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/</link><description>Recent changes to RetrieveByDevice</description><atom:link href="https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/feed" rel="self"/><language>en</language><lastBuildDate>Tue, 27 Oct 2020 08:26:32 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/feed" rel="self" type="application/rss+xml"/><item><title>RetrieveByDevice modified by Jim</title><link>https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v3
+++ v4
@@ -13,6 +13,8 @@
 * direction ...=asc|desc: controls whether timestamped data are retrieved in ascending or descending order, ascending is default
 * count ...=true: retrieves only the number of retrieved moments, not the moments themselves
 * limit ...=nnn: only up to nnn moments are retrieved. If a limit is reached for a moment series the response contains an element &amp;lt;next_timestamp&amp;gt; which can be used in a continuation of the retrieval for this time series
+* rollupLength: the length of the rollup interval in minutes, default is 0 meaning no rollup performed
+* rollupOp: the operation to performed, one of AVG | SUM | MIN | MAX, default is AVG

 Errors:

&amp;lt;/next_timestamp&amp;gt;&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jim</dc:creator><pubDate>Tue, 27 Oct 2020 08:26:32 -0000</pubDate><guid>https://sourceforge.net53fecd7b09b69366f523f6382403f4447e47517d</guid></item><item><title>RetrieveByDevice modified by Jim</title><link>https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v2
+++ v3
@@ -22,7 +22,7 @@
 Example

 ~~~~~~
-GET http://localhost/cs-ws/resources/retrieval/device/?direction=asc&amp;amp;count=false&amp;amp;
+GET http://localhost/cs-ws/resources/retrieval/device?direction=asc&amp;amp;count=false&amp;amp;
 to=2012-09-01%2001%3A00%3A00.000&amp;amp;from=2012-08-31%2001%3A00%3A00.000
 &amp;amp;device_name=TempDev2&amp;amp;limit=-1&amp;amp;apikey=1234 HTTP/1.1

&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jim</dc:creator><pubDate>Tue, 05 Dec 2017 21:26:46 -0000</pubDate><guid>https://sourceforge.nete51b13d06a74b38250adfb8a1f1fa3b499c70af4</guid></item><item><title>WikiPage RetrieveByDevice modified by Jim</title><link>https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/</link><description>&lt;pre&gt;--- v1
+++ v2
@@ -1,4 +1,4 @@
-### Retrieve Date by Device ###
+### Retrieve Data by Device ###
 
 Returns stored device data for all sensors of a device
 
@@ -17,6 +17,7 @@
 Errors:
 
 * 401 UNAUTHORIZED if key is invalid
+* 404 NOT FOUND if the device is not found
 
 Example
 
&lt;/pre&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jim</dc:creator><pubDate>Sun, 23 Sep 2012 08:34:53 -0000</pubDate><guid>https://sourceforge.net87a35e494edb20c6c12001545f206fada69920c1</guid></item><item><title>WikiPage RetrieveByDevice modified by Jim</title><link>https://sourceforge.net/p/m2mlabs/wiki/RetrieveByDevice/</link><description>### Retrieve Date by Device ###

Returns stored device data for all sensors of a device

Path: cs-ws/resources/retrieval/device        Method: GET

Parameters

* apikey
* device_name
* from ... timestamp as yyyy-mm-dd hh:hh:ss.SSS
* to ... timestamp as yyyy-mm-dd hh:hh:ss.SSS
* direction ...=asc|desc: controls whether timestamped data are retrieved in ascending or descending order, ascending is default
* count ...=true: retrieves only the number of retrieved moments, not the moments themselves
* limit ...=nnn: only up to nnn moments are retrieved. If a limit is reached for a moment series the response contains an element &lt;next_timestamp&gt; which can be used in a continuation of the retrieval for this time series

Errors:

* 401 UNAUTHORIZED if key is invalid

Example

~~~~~~
GET http://localhost/cs-ws/resources/retrieval/device/?direction=asc&amp;count=false&amp;
to=2012-09-01%2001%3A00%3A00.000&amp;from=2012-08-31%2001%3A00%3A00.000
&amp;device_name=TempDev2&amp;limit=-1&amp;apikey=1234 HTTP/1.1

HTTP/1.1 200 OK
&lt;device&gt;
   &lt;name&gt;TempDev2&lt;/name&gt;
   &lt;sensor&gt;
      &lt;attribute&gt;
         &lt;moment&gt;
            &lt;timestamp&gt;2012-08-31 19:55:54.036&lt;/timestamp&gt;
            &lt;value&gt;1.1&lt;/value&gt;
         &lt;/moment&gt;
         &lt;moment&gt;
            &lt;timestamp&gt;2012-08-31 19:58:54.036&lt;/timestamp&gt;
            &lt;value&gt;1.1&lt;/value&gt;
         &lt;/moment&gt;
         &lt;name&gt;Temperature&lt;/name&gt;
         &lt;result&gt;
            &lt;count&gt;2&lt;/count&gt;
            &lt;limit_reached&gt;false&lt;/limit_reached&gt;
            &lt;next_timestamp/&gt;
         &lt;/result&gt;
      &lt;/attribute&gt;
      &lt;name&gt;TemperatureSensor&lt;/name&gt;
   &lt;/sensor&gt;
&lt;/device&gt;
~~~~~~
</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Jim</dc:creator><pubDate>Sun, 23 Sep 2012 08:33:46 -0000</pubDate><guid>https://sourceforge.net2141f7ff434f8e3e6db205cd36bcbd2c32234f04</guid></item></channel></rss>