src/Messenger.php
public function send($messageText, callable $callable = null)
    {
        $message = new Message($messageText);

        $response = $this->connection
            ->sendMessage($message)
            ->getBody()
        ;

        if ($callable) {
            $response = call_user_func($callable, $response);
        }

        return $response;
    }
public function send($messageText, callable $callable = null)
    {
        $message = new Message($messageText);

        $response = $this->connection
            ->sendMessage($message)
            ->getBody()
        ;

        if ($callable) {
            $response = call_user_func($callable, $response);
        }

        return $response;
    }
public function send ( $ messageText , callable $ callable = null ) { $ message = new Message ( $ messageText ) ; $ response = $ this -> connection -> sendMessage ( $ message ) -> getBody ( ) ; if ( $ callable ) { $ response = call_user_func ( $ callable , $ response ) ; } return $ response ; }
Send text to the server.

@param          $messageText

@param callable $callable

@return string
Send text to the server .