You are here

interface SlackInterface in Slack 8

Interface for the Slack service.

Hierarchy

Expanded class hierarchy of SlackInterface

All classes that implement SlackInterface

2 files declare their use of SlackInterface
SendTestMessageForm.php in src/Form/SendTestMessageForm.php
SlackSendMessage.php in src/Plugin/RulesAction/SlackSendMessage.php

File

src/SlackInterface.php, line 8

Namespace

Drupal\slack
View source
interface SlackInterface {

  /**
   * Sends a message to a Slack channel.
   *
   * @param string $message
   *   The message sent to the channel.
   * @param string $channel
   *   The channel in the Slack service to send messages.
   * @param string $username
   *   The bot name displayed in the channel.
   *
   * @return bool|object
   *   Slack response.
   *
   * @throws \GuzzleHttp\Exception\GuzzleException
   */
  public function sendMessage($message, $channel = '', $username = '');

}

Members

Namesort descending Modifiers Type Description Overrides
SlackInterface::sendMessage public function Sends a message to a Slack channel. 1