Download the PHP package osa-eg/laravel-teams-notification without Composer

On this page you can find all versions of the php package osa-eg/laravel-teams-notification. 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 laravel-teams-notification

Laravel Teams Notification

Laravel Teams Notification is a package for sending notifications to Microsoft Teams using the "Post to a channel when a webhook request is received" workflow webhook. It supports sending normal messages, exception messages with trace, and messages with additional details or JSON blocks, following the JSON structure required by Microsoft Teams adaptive cards. The package also includes custom logging functionality for Laravel, making it easy to integrate with your existing Laravel applications and log important events directly to Microsoft Teams channels.

Table of Contents

Features

Installation

To install the package, you need PHP 7.0 or higher and Laravel 5.5 or later. Use Composer:

Then, add your Microsoft Teams webhook URL to your .env file:

Publishing Files

Config

To publish the config file included with this package to your Laravel project, run:

Usage

Sending a Normal Message

To send a normal message, use the sendMessage method:

Sending a Normal Message with Additional Details and Color

To send a normal message with additional details, use the sendMessage method with the second parameter:

Sending a Success Message

To send a success message, use the success method:

Sending a Warning Message

To send a warning message, use the warning method:

Sending an Error Message with Trace and Default Attention Color

To send an error message with trace, use the error method and bindTrace method:

Sending a Message with Array as JSON Block and Custom Color

To send a message with an array as a JSON block, use the sendJsonMessage method:

Custom Logging

The package also supports custom logging to Microsoft Teams. To set up custom logging, follow these steps:

  1. Configure Logging in Your Laravel Project:

    In config/logging.php, add the following configuration:

  2. Use the Custom Log Channel:

    To log messages to Teams, use the teams log channel:

Methods

Learn More

For a detailed guide on integrating Microsoft Teams notifications with your Laravel application, check out my Medium article:

Streamlining Laravel Notifications with Microsoft Teams Workflow Integration

License

This package is open-sourced software licensed under the MIT license.



This README now includes a Table of Contents section that links to different parts of the document for easier navigation.

All versions of laravel-teams-notification with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0
illuminate/support Version ^5.5 || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0 || ^11.0 || ^12.0
guzzlehttp/guzzle Version >=6.5
monolog/monolog Version >=1.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 osa-eg/laravel-teams-notification contains the following files

Loading the files please wait ....