Skip to content

omnireach/matomo API reference

Floor
Provider · Omnireach
Version
1.x
Conformance suite
not wired
Verified for real
Verified in part
Licence
MIT
composer require omnireach/matomo:1.x-dev

Read from the package's own PHP files at the commit cb405530697e: its namespaces, classes, interfaces and enums, their public constants, properties and methods with their PHPDoc, and the options its factories take. Nothing of it is run.

Omnireach\Matomo

  • MatomoFactory class

    Matomo, from its options:

    3 options · 1 method

  • MatomoProvider class

    Matomo's Reporting API (https://developer.matomo.org/api-reference/reporting-api): POST index.php?module=API with the token in the body, one report a call - API.get for the whole site, Actions.getEntryPageUrls, Actions.getPageUrls, Referrers.getAll, UserCountry.getCountry, DevicesDetection.getType for a breakdown; period=range over the query's days, or period=day for a history (Dimension::Date).

    5 methods

Omnireach\Matomo

MatomoFactory class

final class MatomoFactory extends ProviderFactory MatomoFactory.php:19

Matomo, from its options:

url the Matomo installation: https://stats.example.org, https://example.matomo.cloud site the site's id (idSite) token a token_auth with view access (Administration, Personal, Security); "anonymous" (the default) for a site whose reports anyone may view

Options

OptionDefault
token'anonymous'
urlrequired
siterequired

MatomoFactory::__construct()

public function __construct(readonly ?HttpClientInterface $http = null)

MatomoProvider class

final class MatomoProvider implements AudienceInterface MatomoProvider.php:27

Matomo's Reporting API (https://developer.matomo.org/api-reference/reporting-api): POST index.php?module=API with the token in the body, one report a call - API.get for the whole site, Actions.getEntryPageUrls, Actions.getPageUrls, Referrers.getAll, UserCountry.getCountry, DevicesDetection.getType for a breakdown; period=range over the query's days, or period=day for a history (Dimension::Date).

MatomoProvider::__construct()

public function __construct(HttpClientInterface $http, readonly string $url, readonly string $site, readonly string $token = 'anonymous')

MatomoProvider::getName()

public function getName(): string

MatomoProvider::getTitle()

public function getTitle(): string

MatomoProvider::capabilities()

public function capabilities(): Capabilities

MatomoProvider::audience()

public function audience(ReachQuery $query): Report