Changes

111 bytes added ,  03:56, 12 May 2014
Line 239: Line 239:  
While working, Sugar Network servers collect depersonalized and common [[Sugar_Network/Node_Statistics|statistics]]. To read such info, call the command:
 
While working, Sugar Network servers collect depersonalized and common [[Sugar_Network/Node_Statistics|statistics]]. To read such info, call the command:
   −
  '''GET''' /?cmd='''stats'''&start=''SECONDS''&end=''SECONDS''&records=''NUMBER''&source=''STATS-NAME''
+
  '''GET''' /?cmd='''stats'''&records=''NUMBER''[&start=''SECONDS''][&end=''SECONDS''][&source=''STATS-NAME'']
    
Where:
 
Where:
   −
* {{Code|start}} and {{Code|end}} is a time interval to get statistics for;
+
* {{Code|records}}, number of stat records to return for the {{Code|start}}-{{Code|end}} interval; note that this amount is not precise, the final resultset might be smaller or bigger depending on chosen resolution; stats resolution depends on node configuration, default values are 1 day, 10 days, 30 days, 365 days;
* {{Code|records}}, number of stat records to return for the {{Code|start}}-{{Code|end}} interval; note that this amount is not precise, the final resultset might be smaller or bigger depending on chosen resolution; stats resolution depends on node configuration, default values are 1 day, 10 days, 30 days, 366 days;
+
* {{Code|start}} and {{Code|end}} is a time interval to get statistics for; if omitted, the beginning and the end of entire life cycle will be used;
* {{Code|source}}, multiple argument to specify what [[Sugar_Network/Node_Statistics#Common_statistics|stats]] should be returned.
+
* {{Code|source}}, multiple argument to specify what [[Sugar_Network/Node_Statistics#Common_statistics|stats]] should be returned; if omitted, return all sources.
    
== Client API ==
 
== Client API ==