[Piwik-hackers] API improvements: now handling periods 'last 10 days' 'last 5 months' + RSS support
Matthieu Aubry
matthieu.aubry at gmail.com
Fri Jan 18 15:56:16 CET 2008
[ The links in the email were not good, thunderbird is strange... ]
There are unlimited combinations!
Here are a few examples:
Basic examples
===
XML of the visits of the last 10 days, one entry per day
http://piwik.org/demo/?module=API&method=VisitsSummary.getVisits&idSite=1&period=day&date=last10&format=xml
XML containing keywords from the last 3 weeks, one entry per week
http://piwik.org/demo/?module=API&method=Referers.getKeywords&idSite=1&period=week&date=last3&format=xml
XML containing the keywords from the last 3 days which match the pattern
"piwik"
http://piwik.org/demo/?module=API&method=Referers.getKeywords&idSite=1&period=day&date=last3&format=xml&filter_column=label&filter_pattern=piwik
RSS feeds
===
RSS feed containing visit information (nb of visits, nb of actions, nb
of unique visitors, etc) for the last 30 days
http://piwik.org/demo/?module=API&method=VisitsSummary.get&idSite=1&period=day&date=last30&format=rss
RSS feed containing the top 30 keywords for the last 3 weeks, ordered by
the number of actions people did when coming from these keywords
http://piwik.org/demo/?module=API&method=Referers.getKeywords&idSite=1&period=week&date=last3&format=xml&filter_limit=30&filter_sort_column=3
Very advanced stuff
===
php array containing actions of the last 3 days with the label
containing the string "development". Recursive search.
http://piwik.org/demo/?module=API&method=Actions.getActions&idSite=1&period=day&date=last3&format=php&expanded=1&filter_column_recursive=label&filter_pattern_recursive=development&prettyDisplay=1
it gives the same result as if you go on http://piwik.org/demo in the
"Actions" section, then type in "development" in the search field under
the Actions table
==============
API documentation = http://dev.piwik.org/trac/wiki/API
More information about the Piwik-hackers
mailing list