PHPackages                             wizaplace/elastic-apm-wrapper - 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. wizaplace/elastic-apm-wrapper

ActiveLibrary

wizaplace/elastic-apm-wrapper
=============================

Wizaplace Elastic APM Wrapper

0.4.4(5y ago)04.0k1MITPHPCI failing

Since Dec 2Pushed 5y ago12 watchersCompare

[ Source](https://github.com/wizaplace/elastic-apm-wrapper)[ Packagist](https://packagist.org/packages/wizaplace/elastic-apm-wrapper)[ Docs](https://github.com/wizaplace/elastic-apm-wrapper)[ RSS](/packages/wizaplace-elastic-apm-wrapper/feed)WikiDiscussions master Synced today

READMEChangelog (10)Dependencies (10)Versions (11)Used By (1)

[![CircleCI](https://camo.githubusercontent.com/353799ae70b17b03ab4a94d07eb12d2c20adddf5c3e3cd5db1662ef02ef919a3/68747470733a2f2f636972636c6563692e636f6d2f67682f77697a61706c6163652f656c61737469632d61706d2d777261707065722e7376673f7374796c653d73766726636972636c652d746f6b656e3d36633064616464336335633139306339356163316261383865616364633136343836316537343433)](https://circleci.com/gh/wizaplace/elastic-apm-wrapper)[![License](https://camo.githubusercontent.com/60b6fa51dff3fc40b678ee2169b0aadab6ba87e3627f28eb31303ef103ca9303/68747470733a2f2f706f7365722e707567782e6f72672f77697a61706c6163652f656c61737469632d61706d2d777261707065722f6c6963656e7365)](https://packagist.org/packages/wizaplace/elastic-apm-wrapper)[![Version](https://camo.githubusercontent.com/79c812d8461ef1db202fb91fdcdbf1540b0580eff790966e77b04279aaa73019/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f77697a61706c6163652f656c61737469632d61706d2d77726170706572)](https://circleci.com/gh/wizaplace/elastic-apm-wrapper/tree/master)[![Maintenance](https://camo.githubusercontent.com/5ca62441414bacaa54c6c6e5b68e46c76305947b6bf498c4949fc71c1b4b10dd/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d61696e7461696e65642533462d7965732d677265656e2e737667)](https://GitHub.com/wizaplace/elastic-apm-wrapper/graphs/commit-activity)[![Ask Me Anything !](https://camo.githubusercontent.com/f58000eb7d904f735fbbca30835a588c716bdde0781156f1fb2e601d44307a3a/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f41736b2532306d652d616e797468696e672d3161626339632e737667)](https://GitHub.com/wizaplace/elastic-apm-wrapper)

Elastic APM Wrapper
===================

[](#elastic-apm-wrapper)

PHP Wrapper to send Logs to Elastic APM

Installation
------------

[](#installation)

The recommended way to install the wrapper is through Composer.

Run the following composer command:

`composer require wizaplace/elastic-apm-wrapper`

Configuration
-------------

[](#configuration)

Communication with Elastic APM is managed by elastic-apm-php-agent (\\PhilKra\\Agent).

In order to instantiate the service using this agent, you have to provide several parameters :

- `appName` (e.g. 'Wizaplace')
- `appVersion` (e.g. '1.0.0')
- `environment` (e.g. 'Development', 'Production')
- `serverUrl` APM Server Endpoint
- `secretToken` Secret token for your Elastic APM Server
- `timeout` Guzzle Client timeout

Usage
-----

[](#usage)

### Transaction

[](#transaction)

Transactions are the highest level of work you’re measuring within a service, like a request to your server. The main idea is that you monitor one transaction at a time: your PHP script being executed.

To start a transaction, you need to use the `startTransaction()` method within AgentService.php. It should be stopped (using `stopTransaction()`) at the very end of the application you're monitoring. Ideally, you wil start the transaction at the beginning of each entry point of your application and stop it at the end of each.

### Spans

[](#spans)

Spans can be seen as 'sub-transactions', meaning they are used to help to watch parts of your application.

A new span can be started as one or several spans are already started. It is important to stop manually all the spans you started otherwise they will be closed automatically meaning you won't really get accurate data.

Within one transaction there can be 0-\* spans captured.

### Apm Handler

[](#apm-handler)

A custom Monolog handler (`ApmHandler.php`) has been included to this package, enabling you to send data to the APM automatically when Monolog is called. This configuration is optional.

### Licence

[](#licence)

This library is distributed under the terms of the MIT licence.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 69.2% 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

Every ~28 days

Recently: every ~9 days

Total

9

Last Release

2125d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/40563270?v=4)[philippe-vandermoere](/maintainers/philippe-vandermoere)[@philippe-vandermoere](https://github.com/philippe-vandermoere)

---

Top Contributors

[![ecourtial](https://avatars.githubusercontent.com/u/57905107?v=4)](https://github.com/ecourtial "ecourtial (9 commits)")[![alex-mercier](https://avatars.githubusercontent.com/u/28927041?v=4)](https://github.com/alex-mercier "alex-mercier (4 commits)")

---

Tags

elastic apm

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/wizaplace-elastic-apm-wrapper/health.svg)

```
[![Health](https://phpackages.com/badges/wizaplace-elastic-apm-wrapper/health.svg)](https://phpackages.com/packages/wizaplace-elastic-apm-wrapper)
```

###  Alternatives

[elgg/elgg

Elgg is an award-winning social networking engine, delivering the building blocks that enable businesses, schools, universities and associations to create their own fully-featured social networks and applications.

1.7k15.7k4](/packages/elgg-elgg)[drevops/git-artifact

Package artifact from your codebase in CI and push it to a separate git repo.

2133.2k](/packages/drevops-git-artifact)[doppar/framework

The Doppar Framework

366.7k8](/packages/doppar-framework)

PHPackages © 2026

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