From 1aba04f804b12f7c1b493daf5cfbcb6020ef5efe Mon Sep 17 00:00:00 2001 From: Divyansh Date: Sun, 28 Jun 2020 17:27:15 +0530 Subject: [PATCH 1/2] spike hook --- hooks/spike/README.md | 6 ++++++ hooks/spike/index.js | 27 +++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 hooks/spike/README.md create mode 100644 hooks/spike/index.js diff --git a/hooks/spike/README.md b/hooks/spike/README.md new file mode 100644 index 0000000..0414076 --- /dev/null +++ b/hooks/spike/README.md @@ -0,0 +1,6 @@ +### Spike + +Sends 'Trigger events' to Spike. + +Here are few Simple steps to get your Integration URL in [Spike](https://docs.spike.sh/integrations-guideline/create-integration-and-service-on-dashboard) +Follow the Documentation at Spike \ No newline at end of file diff --git a/hooks/spike/index.js b/hooks/spike/index.js new file mode 100644 index 0000000..280a24f --- /dev/null +++ b/hooks/spike/index.js @@ -0,0 +1,27 @@ +var request = require("request"), + path = require("path"); + +exports.serviceName = "Spike"; + +exports.author = { + name: "Kaushik Thirthappa", + email: "kaushik@spike.sh", + github: "ktkaushik", + twitter: "ktkaushik" +}; + +exports.onError = function(error, settings, done) { + + request({ + url: settings.url, + headers: { + "Content-Type": "application/json", + "User-Agent": "Spike Notification" + }, + method: "post", + body: JSON.stringify({ + details: error + }), + timeout: 10000 + }, done); +}; \ No newline at end of file From 70d62570f01cff72c9ef7bcd8d5d671c2aaa2434 Mon Sep 17 00:00:00 2001 From: Kaushik Thirthappa Date: Mon, 29 Jun 2020 20:20:02 +0530 Subject: [PATCH 2/2] update readme with slightly more clearer instructions --- hooks/spike/README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hooks/spike/README.md b/hooks/spike/README.md index 0414076..c8e5fd2 100644 --- a/hooks/spike/README.md +++ b/hooks/spike/README.md @@ -2,5 +2,7 @@ Sends 'Trigger events' to Spike. -Here are few Simple steps to get your Integration URL in [Spike](https://docs.spike.sh/integrations-guideline/create-integration-and-service-on-dashboard) -Follow the Documentation at Spike \ No newline at end of file +- On Spike's dashboard, add a new Errorception integration +- Copy the integration's webhook URL to use it on our dashboard + +Here are few Simple steps to get your Integration URL in [Spike](https://docs.spike.sh/integrations-guideline/create-integration-and-service-on-dashboard).