Download the PHP package atm-code/laravel-umami without Composer
On this page you can find all versions of the php package atm-code/laravel-umami. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package laravel-umami
Umami API wrapper for laravel
API wrapper for umami website analytics. get your statistics in the laravel app.
check out Umami, own your website analytics
Features
- Manage websites
- Manage users
- query statistics stats, page views, events and metrics
Installation
You can install the package via composer:
Umami version:
- for umami v1 use v4
- for umami v2 use v5
Config
to publish the configuration file:
and then add these to your .env
file:
Usage
Query Stats
short usage for PHP 8
to get default stats for the last 7 days and without cache:
Parameters
Site id
required: site id from umami server
Part
required: the stats part you want to get from umami,
available options : active, stats, pageviews, events, metrics
default: stats
Options for Query Stats
Dates (start_at,end_at)
optional: Timestamp of starting and end date,
default: last 7 days
you can pass carbon
object or timestamp in milliseconds
unit
only available on pageviews
and events
optional: Time unit, available options: year, month, hour, day
,
default: day
Timezone (tz)
optional: Timezone,
only available on pageviews
and events
default: config('app.timezone')
type (for metrics only)
optional: Gets metrics for a given time range,
available options: url, referrer, browser, os, device, country, event
,
default: url
Websites
Get All websites
Create a website
create a website for a diffrent user
If you want to create a website for different user then the admin user defined in the config, you need to provide the authentication for that user. this is helpful when creating a new user with a website
Update a website
Delete a website
Event data
Get website event and field key record counts within a given time range
See the API documentation for details: https://umami.is/docs/api/event-data#get-/api/event-data/events
Get website field key and value record counts within a given time range
See the API documentation for details: https://umami.is/docs/api/event-data#get-/api/event-data/fields
Users
Get all users
Create a user
Update a user
Delete a user
More details
Please check out Umami website for more information.
Changelog
Please see CHANGELOG for more information what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Credits
- Mike Cao
- All Contributors
License
The MIT License (MIT). Please see License File for more information.