Actions
Feature #12291
closedSupport for Slack notifications
Start date:
Due date:
% Done:
0%
Estimated time:
Plus Target Version:
22.01
Release Notes:
Default
Description
it would be nice to add Slack notifications
sample code:
function sendSlackMessage($message)
{
$ch = curl_init("https://slack.com/api/chat.postMessage");
$data = http_build_query([
"token" => "YOUR_API_TOKEN",
"channel" => '#random',
"text" => $message,
"username" => "John Doe",
]);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
$result = curl_exec($ch);
curl_close($ch);
return $result;
}
Updated by Viktor Gurov over 3 years ago
Updated by Jim Pingle over 3 years ago
- Status changed from New to Pull Request Review
- Assignee set to Viktor Gurov
- Target version set to CE-Next
- Plus Target Version set to Plus-Next
Updated by Viktor Gurov about 3 years ago
- Status changed from Pull Request Review to Feedback
Merged
Updated by Jim Pingle about 3 years ago
- Target version changed from CE-Next to 2.6.0
- Plus Target Version changed from Plus-Next to 22.01
Updated by Jim Pingle about 3 years ago
- Subject changed from Slack notifications to Support for Slack notifications
Updating subject for release notes.
Updated by Christopher Cope almost 3 years ago
Tested with
2.6.0-RC (amd64) built on Wed Jan 12 20:10:43 UTC 2022 FreeBSD 12.3-STABLE
It works successfully with both user & bot tokens.
Updated by Viktor Gurov almost 3 years ago
- Status changed from Feedback to Resolved
Actions