PHPackages                             margatampu/laravel-teams-logging - 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. margatampu/laravel-teams-logging

ActiveLibrary

margatampu/laravel-teams-logging
================================

Laravel handler to sending messages to Microsoft Teams using the Incoming Webhook connector

v1.2.5(1y ago)45773.5k↓27.1%35[9 issues](https://github.com/margatampu/laravel-teams-logging/issues)MITPHPPHP ^8.1

Since Oct 25Pushed 1y ago1 watchersCompare

[ Source](https://github.com/margatampu/laravel-teams-logging)[ Packagist](https://packagist.org/packages/margatampu/laravel-teams-logging)[ RSS](/packages/margatampu-laravel-teams-logging/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (1)Versions (15)Used By (0)

laravel-teams-logging
=====================

[](#laravel-teams-logging)

[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)

Laravel handler to sending messages to Microsoft Teams using the Incoming Webhook connector.

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

[](#installation)

Require this package with composer.

```
$ composer require margatampu/laravel-teams-logging
```

Integration
-----------

[](#integration)

Package tested and worked with Laravel and Lumen framework (10+).

**Laravel**: After installation using composer finishes up, you'll have to add the following line to your `config/app.php`:

```
MargaTampu\LaravelTeamsLogging\LoggerServiceProvider::class
```

**Lumen**: For Lumen, you'll have to add the following line to your `bootstrap/app.php`:

```
$app->register(MargaTampu\LaravelTeamsLogging\LoggerServiceProvider::class);
```

**Laravel**: Then copy `teams` config file from laravel-teams-logging to your config folder:

```
$ php artisan vendor:publish --provider="MargaTampu\LaravelTeamsLogging\LoggerServiceProvider"
```

**Lumen**: For Lumen, you need to copy file manually to your config folder and enable it in `bootstrap/app.php`:

```
$app->configure('teams');
```

Create a [custom channel](https://laravel.com/docs/master/logging#creating-custom-channels) using laravel logging file or create new logging config file for lumen.

Add this configuration to `config/logging.php` file

```
'teams' => [
    'driver'    => 'custom',
    'via'       => \MargaTampu\LaravelTeamsLogging\LoggerChannel::class,
    'level'     => 'debug',
    'url'       => env('INCOMING_WEBHOOK_URL'),
    'style'     => 'simple',    // Available style is 'simple' and 'card', default is 'simple'
],
```

or simply add name to specify different project name for each connector.

```
'teams' => [
    'driver'    => 'custom',
    'via'       => \MargaTampu\LaravelTeamsLogging\LoggerChannel::class,
    'level'     => 'debug',
    'url'       => env('INCOMING_WEBHOOK_URL'),
    'style'     => 'simple',    // Available style is 'simple' and 'card', default is 'simple'
    'name'      => 'Dummy Project'
],
```

There are 2 available styles for microsoft teams message, using simple and card. You can see card style in results style which is difference from simple style.

After added configs to your `config/logging.php` file, add `INCOMING_WEBHOOK_URL` variable to your `.env` file with connector url from your microsoft teams connector. Please read [microsoft teams](https://docs.microsoft.com/en-us/microsoftteams/platform/concepts/connectors/connectors-using) document to find your connector url.

Usage
-----

[](#usage)

To send a simple error message to teams channel, you kindly use script below:

```
Log::channel('teams')->error('Error message');
```

Or you can include additional info to card message using log context.

```
Log::channel('teams')->error('Error message', [
    'name'  => 'value',
    'Assigned to' => 'Unassigned'
]);
```

When using simple style, log context will ignore from message.

You can also add `teams` to the default `stack` channel so all errors are automatically send to the `teams` channel.

```
'channels' => [
    'stack' => [
        'driver' => 'stack',
        'channels' => ['single', 'teams'],
    ],
],
```

Results
-------

[](#results)

Here are some results of notifications sent to microsoft teams channel using card style.

- Debug log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-1debug.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-1debug.png)
- Info log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-2info.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-2info.png)
- Notice log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-3notice.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-3notice.png)
- Warning log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-4warning.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-4warning.png)
- Error log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-5error.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-5error.png)
- Critical log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-6critical.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-6critical.png)
- Alert log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-7alert.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-7alert.png)
- Emergency log preview in microsoft teams channel [![Screenshot](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-8emergency.png)](https://raw.githubusercontent.com/margatampu/laravel-teams-logging/master/assets/ltl-8emergency.png)

License
-------

[](#license)

This laravel-teams-logging package is available under the MIT license. See the LICENSE file for more info.

###  Health Score

50

—

FairBetter than 96% of packages

Maintenance27

Infrequent updates — may be unmaintained

Popularity53

Moderate usage in the ecosystem

Community23

Small or concentrated contributor base

Maturity78

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~157 days

Recently: every ~396 days

Total

14

Last Release

719d ago

Major Versions

v0.1.1 → v1.0.02018-10-25

PHP version history (3 changes)v0.1.0PHP ^7.0

v1.2.2PHP ^7.0|^8.0

v1.2.4PHP ^8.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/c360c1c1e82a8bb84c4ff0785c2c6b2fb419bbaabb014975ed3f1aa21e646652?d=identicon)[margatampu](/maintainers/margatampu)

---

Top Contributors

[![margatampu](https://avatars.githubusercontent.com/u/3712334?v=4)](https://github.com/margatampu "margatampu (11 commits)")[![stampubolon](https://avatars.githubusercontent.com/u/37098202?v=4)](https://github.com/stampubolon "stampubolon (10 commits)")[![AntonioDiPassio-AppSys](https://avatars.githubusercontent.com/u/67696112?v=4)](https://github.com/AntonioDiPassio-AppSys "AntonioDiPassio-AppSys (2 commits)")[![DevBodin](https://avatars.githubusercontent.com/u/26846258?v=4)](https://github.com/DevBodin "DevBodin (2 commits)")[![dgood-gdba](https://avatars.githubusercontent.com/u/69916835?v=4)](https://github.com/dgood-gdba "dgood-gdba (1 commits)")[![firespeed](https://avatars.githubusercontent.com/u/2051999?v=4)](https://github.com/firespeed "firespeed (1 commits)")[![fridzema](https://avatars.githubusercontent.com/u/8180660?v=4)](https://github.com/fridzema "fridzema (1 commits)")[![gsferro](https://avatars.githubusercontent.com/u/12704346?v=4)](https://github.com/gsferro "gsferro (1 commits)")[![j-dohnalek](https://avatars.githubusercontent.com/u/6439903?v=4)](https://github.com/j-dohnalek "j-dohnalek (1 commits)")[![daniel-braga](https://avatars.githubusercontent.com/u/1929857?v=4)](https://github.com/daniel-braga "daniel-braga (1 commits)")[![MultiSuperFreek](https://avatars.githubusercontent.com/u/31889292?v=4)](https://github.com/MultiSuperFreek "MultiSuperFreek (1 commits)")[![paraflu](https://avatars.githubusercontent.com/u/3051226?v=4)](https://github.com/paraflu "paraflu (1 commits)")[![sh-ogawa](https://avatars.githubusercontent.com/u/9303287?v=4)](https://github.com/sh-ogawa "sh-ogawa (1 commits)")[![chack1172](https://avatars.githubusercontent.com/u/12584098?v=4)](https://github.com/chack1172 "chack1172 (1 commits)")

### Embed Badge

![Health badge](/badges/margatampu-laravel-teams-logging/health.svg)

```
[![Health](https://phpackages.com/badges/margatampu-laravel-teams-logging/health.svg)](https://phpackages.com/packages/margatampu-laravel-teams-logging)
```

###  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.7k5](/packages/elgg-elgg)[pressbooks/pressbooks

Pressbooks is an open source book publishing tool built on a WordPress multisite platform. Pressbooks outputs books in multiple formats, including PDF, EPUB, web, and a variety of XML flavours, using a theming/templating system, driven by CSS.

44643.1k1](/packages/pressbooks-pressbooks)[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)
