Download the PHP package trustportidentity/beacon-laravel without Composer

On this page you can find all versions of the php package trustportidentity/beacon-laravel. 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 beacon-laravel

trustportidentity/beacon-laravel

Official TrustPort Beacon APM SDK for Laravel.

Install

Package discovery auto-registers BeaconServiceProvider and the Beacon facade.

Configure

Register the middleware

Custom spans

Controlling ingest volume

Every trace is already batched (BEACON_BATCH_SIZE) instead of one network call per request. In high-traffic services, also set BEACON_SAMPLE_RATE (0.0–1.0, default 1.0) to trace only a fraction of requests — this is what actually keeps you inside your plan's monthly quota. Exceptions are always sent regardless of sampling.

See the full guide at beacon.trustportidentity.com/help/laravel.

Migrating from Laravel Nightwatch

Beacon registers itself the way Nightwatch does: install the package, set the env vars, done.

  1. composer remove laravel/nightwatch then composer require trustportidentity/beacon-laravel:^1.2
  2. In .env, replace the NIGHTWATCH_* variables with:

  3. Stop the Nightwatch agent (php artisan nightwatch:agent): Beacon has no agent process.
  4. php artisan config:clear and php artisan queue:restart.

What you get with no code changes: every HTTP request (route, status, redacted headers, the signed-in user from any guard including Sanctum), database queries with slow-query / N+1 / duplicate detection, queue jobs, cache hits and misses, and log lines as breadcrumbs, plus unhandled exceptions. Health checks (up, health, api/health) are not traced; change with BEACON_IGNORE_PATHS. Set BEACON_AUTO_MIDDLEWARE=false if you register TrustPortIdentity\Beacon\BeaconMiddleware yourself.

Errors: what is captured (v1.2+)

Situation Captured as
Exception in a web request (including ones Laravel turns into a 500 page/JSON) The request trace, with the user, route and stack trace
Exception in a queue job A QUEUE trace with the failure
Exception in artisan / scheduler / console code A CLI trace
Exceptions you report($e) or that Laravel logs Same as above, marked handled
PHP fatals: memory exhausted, max execution time, parse errors A FatalError trace, flushed from a shutdown handler
404, validation, auth exceptions Laravel does not report Not sent (no noise)

Opt out with BEACON_CAPTURE_EXCEPTIONS=false / BEACON_CAPTURE_FATALS=false. Errors are never sampled away.

Sampling, noise and privacy

Troubleshooting

Symptom Check
Only a few requests show up Sample rate below 1, or the path is in BEACON_IGNORE_PATHS
Nothing shows up BEACON_API_KEY unset, config cached (php artisan config:clear), or the server cannot reach BEACON_INGEST_URL
A fatal/exception is missing Upgrade to ^1.2; fatals need BEACON_CAPTURE_FATALS not false
Requests have no user The app authenticates in a way Laravel's guards do not see; call Beacon::identify(...) yourself
Works locally, not in a queue worker Run php artisan queue:restart after changing .env

Telemetry is silent until BEACON_API_KEY is set, so the package can ship to every environment safely.

Run the package tests with composer install && ./vendor/bin/phpunit.


All versions of beacon-laravel with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
ext-curl Version *
illuminate/support Version ^10.0 || ^11.0 || ^12.0
illuminate/http Version ^10.0 || ^11.0 || ^12.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 trustportidentity/beacon-laravel contains the following files

Loading the files please wait ...