ljr/livejournal/doc/raw/build/protocol/getdaycounts.mode.xml

144 lines
3.8 KiB
XML
Raw Permalink Normal View History

2019-02-05 21:49:12 +00:00
<method name="getdaycounts">
<shortdes>
This mode retrieves the number of journal entries per day.
</shortdes>
<des>
This mode retrieves the number of journal entries per day. Useful for populating calendar widgets in GUI clients. Optionally a journal can be specified. It returns a list of the dates and accompanied counts.
</des>
<arguments><struct count="1">
&authInfo;
<key name="usejournal" count="opt">
<des>
If getting the day counts of a shared journal, include this key and the username you wish to get the counts of. By default, you load the counts of "user" as specified above.
</des>
&useJournal;
</key>
</struct></arguments>
<expost>
POST /interface/xmlrpc HTTP/1.0
User-Agent: XMLRPC Client 1.0
Host: www.livejournal.com
Content-Type: text/xml
Content-Length: 403
&lt;?xml version=&quot;1.0&quot;?&gt;
&lt;methodCall&gt;
&lt;methodName&gt;LJ.XMLRPC.getdaycounts&lt;/methodName&gt;
&lt;params&gt;
&lt;param&gt;
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;username&lt;/name&gt;
&lt;value&gt;&lt;string&gt;test&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;password&lt;/name&gt;
&lt;value&gt;&lt;string&gt;test&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;ver&lt;/name&gt;
&lt;value&gt;&lt;int&gt;1&lt;/int&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
&lt;/param&gt;
&lt;/params&gt;
&lt;/methodCall&gt;
</expost>
<!--===================[ RETURN ]==============================-->
<returns><struct count="1">
<key name="daycounts" count="1"><list count="1"><struct count="0more"><des>
For each day that the user has posted a journal entry, a struct is returned in the list.
</des>
<key name="date"><scalar><des>The date, in yyyy-dd-mm format.</des></scalar></key>
<key name="count"><scalar><des>The number of journal entries on that date.</des></scalar></key>
</struct>
</list></key>
</struct></returns>
<exreturn>
HTTP/1.1 200 OK
Connection: close
Content-length: 70580
Content-Type: text/xml
Date: Tue, 16 Jul 2002 20:50:28 GMT
Server: Apache/1.3.4 (Unix)
&lt;?xml version="1.0"?&gt;
&lt;methodResponse&gt;
&lt;params&gt;
&lt;param&gt;
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;daycounts&lt;/name&gt;
&lt;value&gt;&lt;array&gt;
&lt;data&gt;
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;count&lt;/name&gt;
&lt;value&gt;&lt;int&gt;1&lt;/int&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;date&lt;/name&gt;
&lt;value&gt;&lt;string&gt;1995-05-01&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;count&lt;/name&gt;
&lt;value&gt;&lt;int&gt;1&lt;/int&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;date&lt;/name&gt;
&lt;value&gt;&lt;string&gt;1997-05-01&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;count&lt;/name&gt;
&lt;value&gt;&lt;int&gt;1&lt;/int&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;date&lt;/name&gt;
&lt;value&gt;&lt;string&gt;1999-05-03&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;count&lt;/name&gt;
&lt;value&gt;&lt;int&gt;17&lt;/int&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;date&lt;/name&gt;
&lt;value&gt;&lt;string&gt;1999-05-04&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
...
&lt;value&gt;&lt;struct&gt;
&lt;member&gt;&lt;name&gt;count&lt;/name&gt;
&lt;value&gt;&lt;int&gt;1&lt;/int&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;member&gt;&lt;name&gt;date&lt;/name&gt;
&lt;value&gt;&lt;string&gt;2020-02-20&lt;/string&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
&lt;/data&gt;
&lt;/array&gt;&lt;/value&gt;
&lt;/member&gt;
&lt;/struct&gt;&lt;/value&gt;
&lt;/param&gt;
&lt;/params&gt;
&lt;/methodResponse&gt;
</exreturn>
</method>