Download the PHP package salines/cakephp-airbrake without Composer

On this page you can find all versions of the php package salines/cakephp-airbrake. 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 cakephp-airbrake

CakePHP Airbrake Plugin

CI License: MIT CakePHP 5.x PHP 8.1+

A native CakePHP 5.x plugin for Airbrake error tracking and exception monitoring. Automatically captures and reports exceptions, PHP errors, and log messages to Airbrake using API v3. This plugin does not depend on the legacy phpairbrake SDK.

No external dependencies - uses CakePHP's built-in HTTP client.

Features

Requirements

Installation

Install the plugin using Composer:

Migration from phpairbrake

If your application previously used the phpairbrake SDK, you can remove it from composer.json and keep the same Airbrake credentials. This plugin provides its own notifier (CakeAirbrake\Notifier) and sends notices directly using CakePHP's HTTP client.

Configuration

1. Load the Plugin

Add the plugin to your src/Application.php:

2. Configure Airbrake

Add the Airbrake configuration to your config/app.php:

3. Configure Error Logger

To automatically send all exceptions and errors to Airbrake, configure the error logger in config/app.php:

4. Configure Log Engine (Optional)

To send log messages to Airbrake, add the log engine configuration:

The log engine automatically uses the global Airbrake configuration.

Environment Variables

You can configure the plugin using environment variables:

Usage

Automatic Error Tracking

Once configured with the error logger, all uncaught exceptions and PHP errors will automatically be sent to Airbrake.

Manual Exception Reporting

You can manually send exceptions to Airbrake:

Using the Log Engine

Send log messages to Airbrake:

Adding Custom Context

You can add custom context to your error reports using filters:

Filtering Notices

You can prevent certain notices from being sent by returning null from a filter:

Setting Severity

You can set the severity level for notices:

Testing With webhook.site

You can test delivery without a real Airbrake project by sending notices to a webhook.site URL.

  1. Create a new endpoint at https://webhook.site and copy the unique URL.
  2. Configure a custom notices URL:

  3. Trigger a test notice:

Open the webhook.site page to inspect the JSON payload.

Configuration Options

Option Type Default Description
projectId int null Your Airbrake project ID (required)
projectKey string null Your Airbrake project key (required)
environment string 'production' Environment name
appVersion string null Application version
host string 'https://api.airbrake.io' Airbrake API host
enabled bool true Enable/disable Airbrake reporting
keysBlocklist array [...] Regex patterns for sensitive keys to filter
rootDirectory string ROOT Root directory for backtrace filtering
httpClientOptions array ['timeout' => 10] Options for CakePHP HTTP Client

Self-Hosted Airbrake (Errbit)

To use with a self-hosted Airbrake server like Errbit:

Filtering Sensitive Data

The plugin automatically filters sensitive data based on the keysBlocklist configuration. By default, it filters keys matching:

You can add your own patterns:

Disabling in Development

You can disable Airbrake in development:

Or using environment variables:

Notice Structure

The plugin sends notices to Airbrake in the following structure (API v3):

Testing

Run the tests:

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Credits


All versions of cakephp-airbrake with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
cakephp/cakephp Version ^5.0
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 salines/cakephp-airbrake contains the following files

Loading the files please wait ...