Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Squadcast incidents #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions hooks/squadcast/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
### Squadcast

Get notified in near real-time as errors occur on your site by sending events into Squadcast.

#### How to obtain your Errorception Webhook in Squadcast:

1. Head over to Services from the navigation bar on the left
2. For the Service of your choice, click on Alert Sources
3. Search for "Errorception" from the dropdown
4. Copy the Webhook available on the right
5. Use this copied Webhook within Settings > Service Hooks > Squadcast in Errorception
24 changes: 24 additions & 0 deletions hooks/squadcast/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
var request = require("request"),
hash = require("node_hash");

exports.serviceName = "WebHooks";

exports.author = {
name: "Anusha Ravindra",
email: "[email protected]",
github: "SquadcastHub",
twitter: "squadcastHQ"
};

exports.onError = function(error, settings, done) {
request({
url: settings.url,
headers: {
"Content-Type": "application/json",
"User-Agent": "Errorception Notifications"
},
method: "post",
body: JSON.stringify(error),
timeout: 10000
}, done);
};