PHPackages                             potsky/rollbar-laravel - 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. potsky/rollbar-laravel

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

potsky/rollbar-laravel
======================

Rollbar error monitoring integration for Laravel projects

v2.0.1(8y ago)12.1kMITPHPPHP &gt;=5.4

Since Apr 27Pushed 8y ago1 watchersCompare

[ Source](https://github.com/potsky/rollbar-php-laravel)[ Packagist](https://packagist.org/packages/potsky/rollbar-laravel)[ Docs](https://github.com/potsky/rollbar-php-laravel)[ RSS](/packages/potsky-rollbar-laravel/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (7)Versions (21)Used By (0)

Laravel Rollbar
===============

[](#laravel-rollbar)

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

[](#installation)

Install using composer:

```
composer require potsky/rollbar-laravel

```

Add Project Access Token `post_server_item` from Rollbar.com -&gt; Settings -&gt; Project Access Tokens to .env:

```
ROLLBAR_TOKEN=[your Rollbar project access token]

```

Add the service provider to the `'providers'` array in `config/app.php`:

```
Rollbar\Laravel\RollbarServiceProvider::class,
```

If you only want to enable Rollbar reporting for certain environments you can conditionally load the service provider in your `AppServiceProvider`:

```
if ($this->app->environment('production')) {
    $this->app->register(\Rollbar\Laravel\RollbarServiceProvider::class);
}
```

Configuration
-------------

[](#configuration)

This package supports configuration through the services configuration file located in `config/services.php`. All configuration variables will be directly passed to Rollbar:

```
'rollbar' => [
    'access_token' => env('ROLLBAR_TOKEN'),
    'level' => env('ROLLBAR_LEVEL'),
    'person_fn' => function() {
		if (Auth::user()) {
			return [
				'id'       => strval(Auth::user()->id),
				'username' => strval(Auth::user()->name),
				'email'    => strval(Auth::user()->email),
			];
		} else {
			return [];
		}
	}
],
```

The level variable defines the minimum log level at which log messages are sent to Rollbar. For development you could set this either to `debug` to send all log messages, or to `none` to sent no messages at all. For production you could set this to `error` so that all info and debug messages are ignored.

If you compile configuration files, do not use a callback function directly. Define the function in a helper include for example and configure the service like this :

```
'rollbar' => [
    'access_token' => env('ROLLBAR_TOKEN'),
    'level' => env('ROLLBAR_LEVEL'),
    'person_fn' => 'get_rollbar_person'
],
```

In the helper file:

```
function get_rollbar_person() {
	if (Auth::user()) {
		return [
			'id'       => strval(Auth::user()->id),
			'username' => strval(Auth::user()->name),
			'email'    => strval(Auth::user()->email),
		];
	} else {
		return [];
	}
}
```

Usage
-----

[](#usage)

Fatal error and exceptions handled by Laravel are automatically sent to Rollbar. You do not need to add something in `app/Exceptions/Handler.php`.

Your other log messages will also be sent to Rollbar:

```
\Log::debug('Here is some debug information');
```

### Context informaton

[](#context-informaton)

You can pass extra information:

```
\Log::warning('Something went wrong', [
    'download_size' => 3432425235
]);
```

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community17

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 69.4% 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

Every ~60 days

Recently: every ~130 days

Total

20

Last Release

3247d ago

Major Versions

v1.5.1 → v2.0.02017-04-30

PHP version history (2 changes)v1.0.0PHP &gt;=5.3

v1.4.5PHP &gt;=5.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/769401da6eb09b7a0e45be648517fc7042bcb33971caa36c0ccad3e2e2ea6b2b?d=identicon)[potsky](/maintainers/potsky)

---

Top Contributors

[![jenssegers](https://avatars.githubusercontent.com/u/194377?v=4)](https://github.com/jenssegers "jenssegers (77 commits)")[![ArturMoczulski](https://avatars.githubusercontent.com/u/2106631?v=4)](https://github.com/ArturMoczulski "ArturMoczulski (8 commits)")[![potsky](https://avatars.githubusercontent.com/u/408237?v=4)](https://github.com/potsky "potsky (6 commits)")[![DougSisk](https://avatars.githubusercontent.com/u/70512?v=4)](https://github.com/DougSisk "DougSisk (6 commits)")[![throck95](https://avatars.githubusercontent.com/u/13982974?v=4)](https://github.com/throck95 "throck95 (3 commits)")[![cyrrill](https://avatars.githubusercontent.com/u/2376084?v=4)](https://github.com/cyrrill "cyrrill (1 commits)")[![antonioribeiro](https://avatars.githubusercontent.com/u/3182864?v=4)](https://github.com/antonioribeiro "antonioribeiro (1 commits)")[![jnbn](https://avatars.githubusercontent.com/u/112425?v=4)](https://github.com/jnbn "jnbn (1 commits)")[![lowerends](https://avatars.githubusercontent.com/u/6588791?v=4)](https://github.com/lowerends "lowerends (1 commits)")[![lucasmpb](https://avatars.githubusercontent.com/u/713024?v=4)](https://github.com/lucasmpb "lucasmpb (1 commits)")[![sdebacker](https://avatars.githubusercontent.com/u/134503?v=4)](https://github.com/sdebacker "sdebacker (1 commits)")[![ILM126](https://avatars.githubusercontent.com/u/7699696?v=4)](https://github.com/ILM126 "ILM126 (1 commits)")[![brianr](https://avatars.githubusercontent.com/u/12275?v=4)](https://github.com/brianr "brianr (1 commits)")[![charles-rumley](https://avatars.githubusercontent.com/u/8379704?v=4)](https://github.com/charles-rumley "charles-rumley (1 commits)")[![chuprik](https://avatars.githubusercontent.com/u/802946?v=4)](https://github.com/chuprik "chuprik (1 commits)")[![CthulhuDen](https://avatars.githubusercontent.com/u/3912367?v=4)](https://github.com/CthulhuDen "CthulhuDen (1 commits)")

---

Tags

laravelloggingmonitoringerrorrollbar

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/potsky-rollbar-laravel/health.svg)

```
[![Health](https://phpackages.com/badges/potsky-rollbar-laravel/health.svg)](https://phpackages.com/packages/potsky-rollbar-laravel)
```

###  Alternatives

[rollbar/rollbar-laravel

Rollbar error monitoring integration for Laravel projects

14110.4M7](/packages/rollbar-rollbar-laravel)[jenssegers/rollbar

Rollbar error monitoring integration for Laravel projects

3301.1M2](/packages/jenssegers-rollbar)[jenssegers/raven

Sentry (Raven) error monitoring integration for Laravel projects

92197.2k1](/packages/jenssegers-raven)[saasscaleup/laravel-log-alarm

Laravel log Alarm help you to set up alarm when errors occur in your system and send you a notification via Slack and email

27025.0k](/packages/saasscaleup-laravel-log-alarm)

PHPackages © 2026

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