2017 © Pedro Peláez
 

library knp-piwik-client

Simple client for Piwik (web analytics) API.

image

xstyled/knp-piwik-client

Simple client for Piwik (web analytics) API.

  • Thursday, March 3, 2016
  • by RomainLegouverneur
  • Repository
  • 1 Watchers
  • 0 Stars
  • 50 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 10 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

PiwikClient

PHP 5.3 client for Piwik web analytics., (*1)

Usage

  1. Through HTTP connection:, (*2)

    <?php
    
    $connection = new Knp\PiwikClient\Connection\HttpConnection('http://demo.piwik.org');
    $client     = new Knp\PiwikClient\Client($connection, 'YOUR_API_TOKEN');
    
    $array = $client->call('API.getReportMetadata', array('idSites' => array(23, 55)));
  2. Through local (PHP) connection:, (*3)

    <?php
    
    require_once PIWIK_INCLUDE_PATH . "/index.php";
    require_once PIWIK_INCLUDE_PATH . "/core/API/Request.php";
    Piwik_FrontController::getInstance()->init();
    
    $connection = new Knp\PiwikClient\Connection\PiwikConnection();
    $client     = new Knp\PiwikClient\Client($connection, 'YOUR_API_TOKEN');
    
    $array = $client->call('API.getReportMetadata', array('idSites' => array(23, 55)));

Methods

To see all available methods & their parameters, visit Piwik API Reference., (*4)

PiwikClient Copyright (c) 2011 KnpLabs http://www.knplabs.com. See LICENSE for details., (*5)

The Versions

03/03 2016

dev-master

9999999-dev https://github.com/xSTyled/PiwikClient

Simple client for Piwik (web analytics) API.

  Sources   Download

MIT

The Requires

 

analytics knplabs piwik knp xstyled