Download the PHP package robertogallea/pulse-api without Composer
On this page you can find all versions of the php package robertogallea/pulse-api. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download robertogallea/pulse-api
More information about robertogallea/pulse-api
Files in robertogallea/pulse-api
Package pulse-api
Short Description Add an API layer to Laravel Pulse metrics
License
Informations about the package pulse-api
Access Laravel Pulse data using API
This package provides the very same information from Laravel Pulse as a JSON api endpoint.
Installation
You can install the package via composer:
Usage
The package adds api endpoints to your application that exposes metrics collected by Pulse.
/api/pulse
- Provides the full set of metrics collected by Pulse/api/pulse/{$type}
- Provides the metrics from a single type
By default, the available types are the one provided by Pulse itself:
servers
usage
queues
cache
slow_queries
exceptions
slow_requests
slow_jobs
slow_outgoing_requests
However, you can integrate your own by mimicking any Pulse card or by using your own implementation.
Configuration
The file config/pulse-api.php
defines the configuration and can be customized after publishing the package Service
Provider.
Access to endpoints
The endpoint is allowed according to the logic defined by the middlewares defined in the middleware
section of the
config. By default, the following apply:
Custom resources
Like in the web version of Pulse you can add your Cards, in PulseAPI you can add your own Resources, you can
integrate the default ones by editing the resources
configuration section:
Including recorders configuration in json response
Laravel Pulse cards use configuration to adjust the rendering of the card view. This may be not required or not useful in
api but is enabled by default.
You can disable the configuration exposure by proper setting of the include-config
configuration key to false
:
Changelog
Please see CHANGELOG for more information on what has changed recently.
Credits
- Roberto Gallea
- All Contributors
License
The MIT License (MIT). Please see License File for more information.