Skip to content
This repository has been archived by the owner on May 5, 2023. It is now read-only.
/ mattermost-webhook Public archive

PHP client to send messages to a Mattermost webhook.

License

Notifications You must be signed in to change notification settings

nutama/mattermost-webhook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mattermost incoming webhook PHP client

PHP client to send messages to a Mattermost webhook.

See https://docs.mattermost.com/developer/webhooks-incoming.html for the documentation of the incoming webhook of Mattermost.

Build Status SensioLabsInsight

Installation / Usage

Install the latest version via composer:

php composer.phar require nutama/mattermost-webhook

Example:

<?php
require_once('vendor/autoload.php');

$webhook_uri        = 'http://{your-mattermost-site}/hooks/xxx-generatedkey-xxx';
$client             = new \GuzzleHttp\Client(['base_uri' => $webhook_uri]);
$mattermost_webhook = new \Nutama\MattermostWebhook\MattermostWebhook($client);
$message            = new \Nutama\MattermostWebhook\Message('message');

$mattermost_webhook->send($message);

Requirements

PHP 7.0.x or above.

License

This library is licensed under the MIT License - see the LICENSE file for details.

About

PHP client to send messages to a Mattermost webhook.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages