gaguerreiro / simple-slack
PHP class to help with Slack Incoming WebHooks
dev-master
2015-05-08 12:59 UTC
Requires
- php: >=5.3.0
This package is not auto-updated.
Last update: 2025-07-05 22:21:20 UTC
README
PHP class to help with Slack Incoming WebHooks
Requirements
- PHP 5.3 or greater
Installing via Composer
You can install the package using the Composer package manager. You can install it by running this command in your project root:
composer require gaguerreiro/simple-slack:dev-master
Usage
require_once './vendor/autoload.php'; try { $options = array( 'channel' => '#general', 'username' => 'Robot' ); $ss = new SimpleSlack\Client("[YOUR TEAM ENDPOINT]", $options); $ss->sendMessage('Message test'); } catch (SimpleSlackException $e) { printf($e->getCode()); printf($e->getMessage()); }