PHPackages                             julesgraus/actionlogs - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. julesgraus/actionlogs

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

julesgraus/actionlogs
=====================

Tools for logging actions

1.0.0(3y ago)012PHPPHP ^8.0

Since Mar 6Pushed 2y ago1 watchersCompare

[ Source](https://github.com/julesgraus/actionlogs)[ Packagist](https://packagist.org/packages/julesgraus/actionlogs)[ RSS](/packages/julesgraus-actionlogs/feed)WikiDiscussions main Synced today

READMEChangelog (1)Dependencies (4)Versions (2)Used By (0)

Actionlogs
==========

[](#actionlogs)

Log any actions users do in your Laravel application.

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require julesgraus/actionlogs
```

Usage
-----

[](#usage)

### Direct logging

[](#direct-logging)

You can log actions directly like so:

```
JulesGraus\Actionlogs\Actionlogs::log('your action', 'a payload');
```

The logged action wil be linked to the authenticated user if any. The payload can be anything but a resource.

### Automatic logging

[](#automatic-logging)

The package listens to some events in the `Illuminate\Auth\Events` namespace by default and automatically logs those. This is a list of those events:

- Login
- Logout
- Failed
- Lockout
- Registered
- PasswordReset
- Verified

You can listen to extra events if you would like to. You could for example do that like so:

```
JulesGraus\Actionlogs\Actionlogs::listenToAndLog(MyCustomEvent::class, fn(MyCustomEvent::class $event) => 'Logging something for my customevent: '.$event->user->email)
```

Put that line of code in the register method of a service provider in your implementation.

### Housekeeper

[](#housekeeper)

The package is compatible with `julesgraus/housekeeper`. Register the `JulesGraus\Actionlogs\Actionlogs` class to the housekeeper and read the published [config options](#configuration-and-localisation) for more info.

Customisation
-------------

[](#customisation)

### Configuration and localisation

[](#configuration-and-localisation)

publish the config files and translation file of this package by running `php artisan vendor:publish --tag=actionlogs`. You can then edit the config file that will be put in the config dir. And the translations that are put in `resources/lang/vendor/actionlogs`

### Overriding the default Actionlog model

[](#overriding-the-default-actionlog-model)

When the default `actionlog` model from this package does not provide the functionality you want, you can create a custom model yourself.

Just make sure it implements `JulesGraus\Actionlogs\Contracts\Actionlog` and then register it to Laravel's container in the register method of a service provider like so:

```
use Illuminate\Support\ServiceProvider;
use App\Actionlogs\MyCustomActionLog;
use JulesGraus\Actionlogs\Contracts\Actionlog as ActionlogContract;

class AppServiceProvider extends ServiceProvider {
    register() {
        $this->app->bind(ActionlogContract::class, MyCustomActionlog::class);
    }
}
```

Also make sure your custom implementation can accept any variable type for the payload attribute except a resource type.

### Overriding other stuff

[](#overriding-other-stuff)

Like the actionlog model you can also override other stuff by implementing and registering these interfaces in the `JulesGraus\Actionlogs\Contracts` namespace:

- ActionlogPolicy
- ActionlogResource
- ActionlogResourceCollection

Please bind resources and collections to a function that returns the class name of an implementation. Else Laravel will try to instantiate the classes and nag about the resource parameter that it cannot resolve.

Testing
-------

[](#testing)

Run tests by running this command in the root of the package.

```
composer test
```

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1215d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/aa9d50f487032f07737b2201a5500719f0f3d91207ad93541c50bc01440c1f7e?d=identicon)[julesgraus](/maintainers/julesgraus)

---

Top Contributors

[![julesgraus](https://avatars.githubusercontent.com/u/4387442?v=4)](https://github.com/julesgraus "julesgraus (4 commits)")

---

Tags

laravelaction logsJulesGraus

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/julesgraus-actionlogs/health.svg)

```
[![Health](https://phpackages.com/badges/julesgraus-actionlogs/health.svg)](https://phpackages.com/packages/julesgraus-actionlogs)
```

###  Alternatives

[unopim/unopim

UnoPim Laravel PIM

10.5k2.4k](/packages/unopim-unopim)[open-telemetry/opentelemetry-auto-laravel

OpenTelemetry auto-instrumentation for Laravel

592.7M9](/packages/open-telemetry-opentelemetry-auto-laravel)[guanguans/laravel-exception-notify

Monitor exception and report to the notification channels(Log、Mail、AnPush、Bark、Chanify、DingTalk、Discord、Gitter、GoogleChat、IGot、Lark、Mattermost、MicrosoftTeams、NowPush、Ntfy、Push、Pushback、PushBullet、PushDeer、PushMe、Pushover、PushPlus、QQ、RocketChat、ServerChan、ShowdocPush、SimplePush、Slack、Telegram、WeWork、WPush、XiZhi、YiFengChuanHua、ZohoCliq、ZohoCliqWebHook、Zulip).

14845.8k1](/packages/guanguans-laravel-exception-notify)[nightowl/agent

NightOwl monitoring agent — collects telemetry from laravel/nightwatch and writes to PostgreSQL

771.7k](/packages/nightowl-agent)[ecotone/laravel

Ecotone for Laravel — CQRS, Event Sourcing, Sagas, Durable Workflows, and Outbox on top of Laravel Queue, via PHP attributes.

21318.6k3](/packages/ecotone-laravel)[api-platform/laravel

API Platform support for Laravel

58170.8k13](/packages/api-platform-laravel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
