45 if (!extension_loaded(
'openssl')) {
49 parent::__construct(
'ssl://api.flowdock.com:443',
$level,
$bubble);
59 throw new \InvalidArgumentException(
'The FlowdockHandler requires an instance of Monolog\Formatter\FlowdockFormatter to function correctly');
62 return parent::setFormatter($formatter);
72 throw new \InvalidArgumentException(
'The FlowdockHandler must be configured (via setFormatter) with an instance of Monolog\Formatter\FlowdockFormatter to function correctly');
80 protected function write(array $record)
108 return json_encode($record[
'formatted'][
'flowdock']);
119 $header =
"POST /v1/messages/team_inbox/" . $this->apiToken .
" HTTP/1.1\r\n";
120 $header .=
"Host: api.flowdock.com\r\n";
121 $header .=
"Content-Type: application/json\r\n";
122 $header .=
"Content-Length: " . strlen($content) .
"\r\n";
const DEBUG
Detailed debug information.
Stores to any socket - uses fsockopen() or pfsockopen().
getDefaultFormatter()
Gets the default formatter.
buildContent($record)
Builds the body of API call.
__construct($apiToken, $level=Logger::DEBUG, $bubble=true)
generateDataStream($record)
{}
Exception can be thrown if an extension for an handler is missing.
Sends notifications through the Flowdock push API.
buildHeader($content)
Builds the header of the API Call.
setFormatter(FormatterInterface $formatter)
{Sets the formatter.self}
closeSocket()
Close socket, if open.