### Register Custom Middleware Source: https://github.com/spatie/flare-client-php/blob/main/UPGRADING.md Provides an example of how to register a custom middleware class with Flare using the `collectFlareMiddleware` method on the config object. ```php $config->collectFlareMiddleware([ MyMiddleware::class => [], ]); ``` -------------------------------- ### Run Tests Source: https://github.com/spatie/flare-client-php/blob/main/README.md This command executes the test suite for the Flare client PHP package. It ensures that all functionalities are working as expected and helps in maintaining code quality. ```bash composer test ``` -------------------------------- ### Add Multiple Context Items Source: https://github.com/spatie/flare-client-php/blob/main/UPGRADING.md Shows how to add multiple context items to Flare simultaneously using an array with the `context()` method. ```php $flare->context([ 'key' => 'value', 'key2' => 'value2', ]); ``` -------------------------------- ### Add Single Context Item Source: https://github.com/spatie/flare-client-php/blob/main/UPGRADING.md Demonstrates how to add a single context item to Flare using the `context()` method. ```php $flare->context('key', 'value'); // Single item ``` -------------------------------- ### Record Glow Message (New Way) Source: https://github.com/spatie/flare-client-php/blob/main/UPGRADING.md Illustrates the new method for recording glow messages with a level, using the `glow()` method and `record()`. ```php $flare->glow()->record('This is a message from glow!', MessageLevels::Debug); // New way ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.