Download the PHP package sergeybruhin/laravel-analytics-nova-tool without Composer

On this page you can find all versions of the php package sergeybruhin/laravel-analytics-nova-tool. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-analytics-nova-tool

Laravel Analytics Nova Tool

Latest Version on Packagist PHP version

The Laravel Nova companion for sergeybruhin/laravel-analytics: Nova resources for browsing visitors/sessions/pageviews/events, a couple of dashboard metrics, and a filterable analytics report Tool — traffic trend, top pages, traffic sources and device breakdown, all driven by one shared filter bar.

The data package stays free of any Nova dependency on purpose. Nova is a paid, credentialed package, so putting Nova-facing code inside the core analytics package would make it uninstallable for anyone without a licence and break its CI, which installs with no credentials at all. Hence two packages:

Requirements

PHP 8.2+
Nova 4 or 5
sergeybruhin/laravel-analytics ^0.0.1

Installation

Nova is not on Packagist, so this only works in an application that already has Nova's own Composer repository configured — which every Nova application does. Until this package itself is on Packagist, add a vcs repository first:

then run the same composer require command above.

Nothing here is auto-discovered onto the Nova sidebar — Resources, the Dashboard and the Tool are plain Nova classes you register yourself, same as every other resource in a typical Nova app:

Resources

Resources\{Visitor,Session,Pageview,Event} — read-only by design (authorizedToCreate/Update /Delete/Replicate all hard-return false; this data is written exclusively through the collect endpoint's queue job in laravel-analytics). Drill-down works through real BelongsTo/HasMany fields: Visitor → Sessions/Pageviews/Events, Session → Visitor, Session → Pageviews/Events, Pageview/Event → Session, Visitor.

Metrics & Dashboard

Metrics\PageviewsTrend (daily pageviews, bot sessions excluded) and Metrics\TopTrafficSources (visitors by first-touch UTM source) are bundled into Dashboards\Analytics, a small always-visible-range dashboard for a quick glance from the sidebar.

The Tool

NovaAnalyticsTool registers its own sidebar page — a deeper report the Dashboard's fixed-range metric cards can't express, since Nova gives each card its own independent range dropdown with no way to share a filter across cards. One filter bar here drives four views at once:

Filter bar dimensions: date-range presets (today / yesterday / last 7 days / last 30 days / this month / last month), UTM source/medium/campaign, device type/browser/OS, and a bot-traffic include/exclude toggle (every view excludes bot sessions by default).

HTTP surface

Everything the Tool's page talks to, under Nova's own domain and prefixed nova-vendor/laravel-analytics-nova-tool. Every route sits behind Nova's authentication and the package's own Authorize middleware, which defers to a viewNovaAnalytics gate — defined by the host app, or allowed by default if the host hasn't defined it.

Method Path Returns
GET /filter-options distinct UTM/device/browser/OS values for the current date range, plus the period preset list
GET /trend zero-filled daily pageviews + unique visitors
GET /top-pages top paths by views/unique visitors
GET /traffic-sources sessions grouped by UTM source/medium/campaign
GET /devices sessions grouped by device type/browser/OS

All five accept the same query params: period, utm_source, utm_medium, utm_campaign, device_type, browser, os, include_bots (0/1).

Building the assets

dist/ is committed, so installing the package needs no Node. To change the front end:

Standard Nova 4 nova:tool scaffold — Laravel Mix, Vue 3, Chart.js as a real bundled dependency (Nova's own chart library, Chartist, isn't in the tool scaffold's webpack externals — only vue is). Nova registers Head, Heading, Card, SelectControl, CheckboxWithLabel and friends globally, so the Tool imports nothing from Nova's own JS.

Changelog

See CHANGELOG.md for what changed in each release. This package follows semantic versioning; while the version is below 1.0.0, routes, config keys and response shapes may change in a minor release.

Credits

License

The MIT License (MIT). Please see License File for more information.


All versions of laravel-analytics-nova-tool with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
laravel/nova Version ^4.0|^5.0
sergeybruhin/laravel-analytics Version >=0.0.2 <0.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package sergeybruhin/laravel-analytics-nova-tool contains the following files

Loading the files please wait ...