PHPackages                             xinningsu/yii2-honeybadger - 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. [Debugging &amp; Profiling](/categories/debugging)
4. /
5. xinningsu/yii2-honeybadger

ActiveLibrary[Debugging &amp; Profiling](/categories/debugging)

xinningsu/yii2-honeybadger
==========================

Honeybadger logger for Yii2, Honeybadger integration for Yii2.

v1.0.0(10mo ago)01MITPHPPHP ^8.0.0

Since Aug 21Pushed 10mo agoCompare

[ Source](https://github.com/xinningsu/yii2-honeybadger)[ Packagist](https://packagist.org/packages/xinningsu/yii2-honeybadger)[ Docs](https://github.com/xinningsu/yii2-honeybadger)[ RSS](/packages/xinningsu-yii2-honeybadger/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (4)Versions (2)Used By (0)

Honeybadger Error Logger for Yii2
=================================

[](#honeybadger-error-logger-for-yii2)

Honeybadger integration for Yii2, Honeybadger Error Logger.

[![MIT licensed](https://camo.githubusercontent.com/7013272bd27ece47364536a221edb554cd69683b68a46fc0ee96881174c4214c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e737667)](./LICENSE)[![Build Status](https://camo.githubusercontent.com/419fd40814f396b8df5b4c9705322987c7987dcaf3878d4d79cc10f368ea9172/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f78696e6e696e6773752f796969322d686f6e65796261646765722f6261646765732f6275696c642e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/xinningsu/yii2-honeybadger/build-status/master)[![Code Coverage](https://camo.githubusercontent.com/f462b49d6bf7370a493919d66a0faec8d9337cf9e93a85f2fcf4d86ce060bd0c/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f78696e6e696e6773752f796969322d686f6e65796261646765722f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/xinningsu/yii2-honeybadger/?branch=master)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/a5a7d5b4357c5374de83cd028efa5ec0427597787c4591394891a54fbece34a5/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f78696e6e696e6773752f796969322d686f6e65796261646765722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/xinningsu/yii2-honeybadger)[![Code Intelligence Status](https://camo.githubusercontent.com/cb55694f10374898afc16816fc1bd97ab138fb18b0db5fed12341190aea4be27/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f78696e6e696e6773752f796969322d686f6e65796261646765722f6261646765732f636f64652d696e74656c6c6967656e63652e7376673f623d6d6173746572)](https://scrutinizer-ci.com/g/xinningsu/yii2-honeybadger)

Installation
============

[](#installation)

```
composer require xinningsu/yii2-honeybadger

```

Usage
=====

[](#usage)

Once you have finished the Honeybadger installation, set up Honeybadger component and Honeybadger log target in Yii common config file, e.g., `config/web.php`:

```
[
    // ...
    'components' => [
        // ...
        // Honeybadger component
        'honeybadger' => [
            'class'  => \Sulao\YiiHoneybadger\Component::class,
            'config' => [
                'api_key'     => 'your_honeybadger_api_key', // Update with your Honeybadger API key
                'report_data' => true,
                // ...
                // For more configuration options, please refer to
                // https://github.com/xinningsu/yii2-honeybadger/blob/master/config/honeybadger.php
                // https://docs.honeybadger.io/lib/php/reference/configuration/#default-configuration
            ],
        ],
        'log' => [
            // ...
            // Honeybadger log target
            'targets' => [
                // ...
                [
                    'class'  => \Sulao\YiiHoneybadger\Target::class,
                    'levels' => ['error', 'warning'],
                ],
            ],
        ],
        // ...
    ],
    // ...
],
```

Testing
=======

[](#testing)

In the `controller` file, add the code below

```
\Yii::error('test error');
```

Or trigger an exception In the `controller`

```
throw new \Exception('test exception');
```

To manually send reports, you can refer to the code below:

```
\Yii::$app->honeybadger->notify(new \Exception('test exception'));
\Yii::$app->honeybadger->customNotification([
    'title'   => 'Special Error',
    'message' => 'Special Error: a special error has occurred',
]);
```

Then, check if the report is available in the Honeybadger.

License
=======

[](#license)

[MIT](./LICENSE)

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance54

Moderate activity, may be stable

Popularity1

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity41

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

316d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/7513c529acb322b54c46bef8011275fe734f9d00944c3f3921cebc21c0cd2ed0?d=identicon)[xinningsu](/maintainers/xinningsu)

---

Top Contributors

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

---

Tags

error-handlingerror-reportingerror-trackinghoneybadgeryii2error-reportingerror-monitoringyii2error-trackinghoneybadger-phphoneybadgerhoneybadger logger

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/xinningsu-yii2-honeybadger/health.svg)

```
[![Health](https://phpackages.com/badges/xinningsu-yii2-honeybadger/health.svg)](https://phpackages.com/packages/xinningsu-yii2-honeybadger)
```

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M3.1k](/packages/craftcms-cms)[demi/backup

Basic Yii2 site backup methods

2021.4k1](/packages/demi-backup)

PHPackages © 2026

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