pager_tree-integrations 1.0.1 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/models/pager_tree/integrations/alert.rb +3 -1
- data/app/models/pager_tree/integrations/app_dynamics/v3.rb +74 -0
- data/app/models/pager_tree/integrations/auvik/v3.rb +94 -0
- data/app/models/pager_tree/integrations/aws_cloudwatch/v3.rb +108 -0
- data/app/models/pager_tree/integrations/azure_monitor/v3.rb +79 -0
- data/app/models/pager_tree/integrations/boolean_store_accessor.rb +42 -0
- data/app/models/pager_tree/integrations/channel/hangouts/v3.rb +176 -0
- data/app/models/pager_tree/integrations/channel/mattermost/v3.rb +6 -0
- data/app/models/pager_tree/integrations/channel/microsoft_teams/v3.rb +142 -0
- data/app/models/pager_tree/integrations/channel/slack/v3.rb +136 -0
- data/app/models/pager_tree/integrations/cronitor/v3.rb +64 -0
- data/app/models/pager_tree/integrations/datadog/v3.rb +72 -0
- data/app/models/pager_tree/integrations/dead_mans_snitch/v3.rb +76 -0
- data/app/models/pager_tree/integrations/elast_alert/v3.rb +63 -0
- data/app/models/pager_tree/integrations/form/v3.rb +114 -0
- data/app/models/pager_tree/integrations/freshdesk/v3.rb +103 -0
- data/app/models/pager_tree/integrations/freshservice/v3.rb +103 -0
- data/app/models/pager_tree/integrations/grafana/v3.rb +67 -0
- data/app/models/pager_tree/integrations/healthchecks/v3.rb +68 -0
- data/app/models/pager_tree/integrations/honeybadger/v3.rb +76 -0
- data/app/models/pager_tree/integrations/hyperping/v3.rb +60 -0
- data/app/models/pager_tree/integrations/integration.rb +27 -5
- data/app/models/pager_tree/integrations/jira_server/v3.rb +61 -0
- data/app/models/pager_tree/integrations/jotform/v3.rb +50 -0
- data/app/models/pager_tree/integrations/kapacitor/v3.rb +65 -0
- data/app/models/pager_tree/integrations/logic_monitor/v3.rb +79 -0
- data/app/models/pager_tree/integrations/mattermost/outgoing_webhook/v3.rb +77 -0
- data/app/models/pager_tree/integrations/new_relic/v3.rb +67 -0
- data/app/models/pager_tree/integrations/outgoing_event.rb +2 -0
- data/app/models/pager_tree/integrations/outgoing_webhook/v3.rb +37 -6
- data/app/models/pager_tree/integrations/outgoing_webhook_delivery/hook_relay.rb +8 -6
- data/app/models/pager_tree/integrations/outgoing_webhook_delivery.rb +1 -1
- data/app/models/pager_tree/integrations/pingdom/v3.rb +71 -0
- data/app/models/pager_tree/integrations/prometheus/v3.rb +79 -0
- data/app/models/pager_tree/integrations/prtg/v3.rb +58 -0
- data/app/models/pager_tree/integrations/server_guard24/v3.rb +74 -0
- data/app/models/pager_tree/integrations/site24x7/v3.rb +68 -0
- data/app/models/pager_tree/integrations/solar_winds/v3.rb +77 -0
- data/app/models/pager_tree/integrations/stackdriver/v3.rb +60 -0
- data/app/models/pager_tree/integrations/status_cake/v3.rb +65 -0
- data/app/models/pager_tree/integrations/twilio/incoming_sms/v3.rb +78 -0
- data/app/models/pager_tree/integrations/typeform/v3.rb +43 -0
- data/app/models/pager_tree/integrations/uptime/v3.rb +68 -0
- data/app/models/pager_tree/integrations/uptime_robot/v3.rb +79 -0
- data/app/models/pager_tree/integrations/webhook/v3.rb +112 -0
- data/app/models/pager_tree/integrations/zendesk/v3.rb +83 -0
- data/app/views/pager_tree/integrations/app_dynamics/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/app_dynamics/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/auvik/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/auvik/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/aws_cloudwatch/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/aws_cloudwatch/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/azure_monitor/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/azure_monitor/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/channel/hangouts/v3/_form_options.html.erb +34 -0
- data/app/views/pager_tree/integrations/channel/hangouts/v3/_show_options.html.erb +40 -0
- data/app/views/pager_tree/integrations/channel/mattermost/v3/_form_options.html.erb +1 -0
- data/app/views/pager_tree/integrations/channel/mattermost/v3/_show_options.html.erb +1 -0
- data/app/views/pager_tree/integrations/channel/microsoft_teams/v3/_form_options.html.erb +34 -0
- data/app/views/pager_tree/integrations/channel/microsoft_teams/v3/_show_options.html.erb +40 -0
- data/app/views/pager_tree/integrations/channel/slack/v3/_form_options.html.erb +34 -0
- data/app/views/pager_tree/integrations/channel/slack/v3/_show_options.html.erb +40 -0
- data/app/views/pager_tree/integrations/cronitor/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/cronitor/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/datadog/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/datadog/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/dead_mans_snitch/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/dead_mans_snitch/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/elast_alert/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/elast_alert/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/form/v3/_form_options.html.erb +64 -0
- data/app/views/pager_tree/integrations/form/v3/_show_options.html.erb +122 -0
- data/app/views/pager_tree/integrations/freshdesk/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/freshdesk/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/freshservice/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/freshservice/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/grafana/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/grafana/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/healthchecks/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/healthchecks/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/honeybadger/v3/_form_options.html.erb +7 -0
- data/app/views/pager_tree/integrations/honeybadger/v3/_show_options.html.erb +12 -0
- data/app/views/pager_tree/integrations/hyperping/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/hyperping/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/jira_server/v3/_form_options.html.erb +7 -0
- data/app/views/pager_tree/integrations/jira_server/v3/_show_options.html.erb +12 -0
- data/app/views/pager_tree/integrations/jotform/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/jotform/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/kapacitor/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/kapacitor/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/logic_monitor/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/logic_monitor/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/mattermost/outgoing_webhook/v3/_form_options.html.erb +7 -0
- data/app/views/pager_tree/integrations/mattermost/outgoing_webhook/v3/_show_options.html.erb +12 -0
- data/app/views/pager_tree/integrations/new_relic/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/new_relic/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/outgoing_webhook/v3/_form_options.html.erb +12 -4
- data/app/views/pager_tree/integrations/outgoing_webhook/v3/_show_options.html.erb +20 -2
- data/app/views/pager_tree/integrations/pingdom/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/pingdom/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/prometheus/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/prometheus/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/prtg/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/prtg/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/server_guard24/v3/_form_options.html.erb +7 -0
- data/app/views/pager_tree/integrations/server_guard24/v3/_show_options.html.erb +12 -0
- data/app/views/pager_tree/integrations/site24x7/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/site24x7/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/solar_winds/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/solar_winds/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/stackdriver/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/stackdriver/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/status_cake/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/status_cake/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/twilio/incoming_sms/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/twilio/incoming_sms/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/typeform/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/typeform/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/uptime/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/uptime/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/uptime_robot/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/uptime_robot/v3/_show_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/webhook/v3/_form_options.html.erb +15 -0
- data/app/views/pager_tree/integrations/webhook/v3/_show_options.html.erb +26 -0
- data/app/views/pager_tree/integrations/zendesk/v3/_form_options.html.erb +0 -0
- data/app/views/pager_tree/integrations/zendesk/v3/_show_options.html.erb +0 -0
- data/config/locales/en.yml +83 -23
- data/lib/generators/integration/integration_generator.rb +2 -1
- data/lib/generators/integration/templates/model.rb.tt +16 -6
- data/lib/pager_tree/integrations/version.rb +1 -1
- metadata +121 -3
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<div class="sm:col-span-2">
|
|
2
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
3
|
+
<%= t("activerecord.attributes.pager_tree/integrations/honeybadger/v3.option_token") %>
|
|
4
|
+
</dt>
|
|
5
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
6
|
+
<div class="flex items-center gap-2">
|
|
7
|
+
<p class="text-sm truncate">
|
|
8
|
+
<%= mask integration.option_token %>
|
|
9
|
+
</p>
|
|
10
|
+
</div>
|
|
11
|
+
</dd>
|
|
12
|
+
</div>
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-4">
|
|
2
|
+
<div class="form-group">
|
|
3
|
+
<%= form.check_box :option_issue_updated, class: "form-checkbox mr-1" %>
|
|
4
|
+
<%= form.label :option_issue_updated, class: "inline-block" %>
|
|
5
|
+
<p class="form-hint"><%== t(".option_issue_updated_hint_html") %></p>
|
|
6
|
+
</div>
|
|
7
|
+
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<div class="sm:col-span-2">
|
|
2
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
3
|
+
<%= t("activerecord.attributes.pager_tree/integrations/jira_server/v3.option_issue_updated") %>
|
|
4
|
+
</dt>
|
|
5
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
6
|
+
<div class="flex items-center gap-2">
|
|
7
|
+
<p class="text-sm truncate">
|
|
8
|
+
<%= render partial: "shared/components/badge_enabled", locals: { enabled: integration.option_issue_updated } %>
|
|
9
|
+
</p>
|
|
10
|
+
</div>
|
|
11
|
+
</dd>
|
|
12
|
+
</div>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<div class="sm:col-span-2">
|
|
2
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
3
|
+
<%= t("activerecord.attributes.pager_tree/integrations/mattermost/outgoing_webhook/v3.option_token") %>
|
|
4
|
+
</dt>
|
|
5
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
6
|
+
<div class="flex items-center gap-2">
|
|
7
|
+
<p class="text-sm truncate">
|
|
8
|
+
<%= mask integration.option_token %>
|
|
9
|
+
</p>
|
|
10
|
+
</div>
|
|
11
|
+
</dd>
|
|
12
|
+
</div>
|
|
File without changes
|
|
File without changes
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
%>
|
|
33
33
|
<% opts.each do |opt| %>
|
|
34
34
|
<div class="form-group">
|
|
35
|
-
<%= form.
|
|
36
|
-
<%= form.
|
|
37
|
-
<p class="form-hint"><%== t(".option_#{opt.to_s}_hint_html") %></p>
|
|
35
|
+
<%= form.check_box "option_#{opt.to_s}".to_sym, class: "form-checkbox mr-1" %>
|
|
36
|
+
<%= form.label "option_#{opt.to_s}".to_sym, class: "inline-block" %>
|
|
37
|
+
<p class="form-hint"><%== t("pager_tree.integrations.common.option_#{opt.to_s}_hint_html") %></p>
|
|
38
38
|
</div>
|
|
39
39
|
<% end %>
|
|
40
40
|
|
|
@@ -47,4 +47,12 @@
|
|
|
47
47
|
<%= tag.div class: "h-96", data: {code_editor_target: "editor"} do %><%= form.object.option_template %><% end %>
|
|
48
48
|
<p class="form-hint"><%== t(".option_template_hint_html") %></p>
|
|
49
49
|
<% end %>
|
|
50
|
-
|
|
50
|
+
|
|
51
|
+
<%= tag.div class: "form-group", data: {controller: "code-editor", code_editor_language_value: "yaml", code_editor_read_only_value: false } do %>
|
|
52
|
+
<%= form.label :option_outgoing_rules, t("pager_tree.integrations.common.option_outgoing_rules") %>
|
|
53
|
+
<%= form.hidden_field :option_outgoing_rules, class: "form-control", data: {code_editor_target: "form"} %>
|
|
54
|
+
<%= tag.div class: "h-96", data: {code_editor_target: "editor"} do %><%= form.object.option_outgoing_rules %><% end %>
|
|
55
|
+
<p class="form-hint"><%== t("pager_tree.integrations.common.option_outgoing_rules_hint_html") %></p>
|
|
56
|
+
<% end %>
|
|
57
|
+
</div>
|
|
58
|
+
|
|
@@ -52,10 +52,28 @@
|
|
|
52
52
|
<% opts.each do |opt| %>
|
|
53
53
|
<div class="sm:col-span-1">
|
|
54
54
|
<dt class="text-sm font-medium text-gray-500">
|
|
55
|
-
<%= t("activerecord.attributes.pager_tree/integrations/
|
|
55
|
+
<%= t("activerecord.attributes.pager_tree/integrations/integration.option_#{opt.to_s}") %>
|
|
56
56
|
</dt>
|
|
57
57
|
<dd class="mt-1 text-sm text-gray-900">
|
|
58
58
|
<%= render partial: "shared/components/badge_enabled", locals: { enabled: integration.send("option_#{opt.to_s}") } %>
|
|
59
59
|
</dd>
|
|
60
60
|
</div>
|
|
61
|
-
<% end %>
|
|
61
|
+
<% end %>
|
|
62
|
+
|
|
63
|
+
<div class="sm:col-span-1">
|
|
64
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
65
|
+
<%= t("activerecord.attributes.pager_tree/integrations/outgoing_webhook/v3.option_template") %>
|
|
66
|
+
</dt>
|
|
67
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
68
|
+
<%= render partial: "shared/components/badge_enabled", locals: { enabled: integration.option_template.present? } %>
|
|
69
|
+
</dd>
|
|
70
|
+
</div>
|
|
71
|
+
|
|
72
|
+
<div class="sm:col-span-1">
|
|
73
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
74
|
+
<%= t("pager_tree.integrations.common.option_outgoing_rules") %>
|
|
75
|
+
</dt>
|
|
76
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
77
|
+
<%= render partial: "shared/components/badge_enabled", locals: { enabled: integration.option_outgoing_rules.present? } %>
|
|
78
|
+
</dd>
|
|
79
|
+
</div>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-4">
|
|
2
|
+
<div class="form-group">
|
|
3
|
+
<%= form.check_box :option_resolve_warn, class: "form-checkbox mr-1" %>
|
|
4
|
+
<%= form.label :option_resolve_warn, class: "inline-block" %>
|
|
5
|
+
<p class="form-hint"><%== t(".option_resolve_warn_hint_html") %></p>
|
|
6
|
+
</div>
|
|
7
|
+
</div>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<div class="sm:col-span-2">
|
|
2
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
3
|
+
<%= t("activerecord.attributes.pager_tree/integrations/server_guard24/v3.option_resolve_warn") %>
|
|
4
|
+
</dt>
|
|
5
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
6
|
+
<div class="flex items-center gap-2">
|
|
7
|
+
<p class="text-sm truncate">
|
|
8
|
+
<%= render partial: "shared/components/badge_enabled", locals: { enabled: integration.option_resolve_warn } %>
|
|
9
|
+
</p>
|
|
10
|
+
</div>
|
|
11
|
+
</dd>
|
|
12
|
+
</div>
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<div class="grid grid-cols-1 gap-4">
|
|
2
|
+
<div class="form-group">
|
|
3
|
+
<%= form.label :option_token %>
|
|
4
|
+
<%= form.text_field :option_token, class: "form-control" %>
|
|
5
|
+
<p class="form-hint"><%== t(".option_token_hint_html") %></p>
|
|
6
|
+
</div>
|
|
7
|
+
</div>
|
|
8
|
+
|
|
9
|
+
<div class="grid grid-cols-1 md:grid-cols-3 gap-4">
|
|
10
|
+
<div class="form-group">
|
|
11
|
+
<%= form.check_box :option_capture_additional_data, class: "form-checkbox mr-1" %>
|
|
12
|
+
<%= form.label :option_capture_additional_data, class: "inline-block" %>
|
|
13
|
+
<p class="form-hint"><%== t(".option_capture_additional_data_hint_html") %></p>
|
|
14
|
+
</div>
|
|
15
|
+
</div>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<div class="sm:col-span-2">
|
|
2
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
3
|
+
<%= t("activerecord.attributes.pager_tree/integrations/webhook/v3.option_token") %>
|
|
4
|
+
</dt>
|
|
5
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
6
|
+
<div class="flex items-center gap-2">
|
|
7
|
+
<p class="text-sm truncate">
|
|
8
|
+
<%= mask integration.option_token %>
|
|
9
|
+
</p>
|
|
10
|
+
</div>
|
|
11
|
+
</dd>
|
|
12
|
+
</div>
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
<div class="sm:col-span-1">
|
|
16
|
+
<dt class="text-sm font-medium text-gray-500">
|
|
17
|
+
<%= t("activerecord.attributes.pager_tree/integrations/webhook/v3.option_capture_additional_data") %>
|
|
18
|
+
</dt>
|
|
19
|
+
<dd class="mt-1 text-sm text-gray-900">
|
|
20
|
+
<div class="flex items-center gap-2">
|
|
21
|
+
<p class="text-sm truncate">
|
|
22
|
+
<%= render partial: "shared/components/badge_enabled", locals: { enabled: integration.option_capture_additional_data } %>
|
|
23
|
+
</p>
|
|
24
|
+
</div>
|
|
25
|
+
</dd>
|
|
26
|
+
</div>
|
|
File without changes
|
|
File without changes
|
data/config/locales/en.yml
CHANGED
|
@@ -4,14 +4,45 @@ en:
|
|
|
4
4
|
common:
|
|
5
5
|
default: "default"
|
|
6
6
|
none: "none"
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
option_outgoing_rules: "Outgoing Rules"
|
|
8
|
+
option_outgoing_rules_hint_html: Outgoing Rules <a href='https://pagertree.com/knowledge-base/outgoing-webhooks/#rules' target='_blank'>(see docs)</a> for details.
|
|
9
|
+
option_incoming_webhook_url_hint_html: "URL to POST to"
|
|
10
|
+
option_alert_created_hint_html: "Send when the alert is created (before its routed)"
|
|
11
|
+
option_alert_open_hint_html: "Send when the alert is marked open (it has been routed)"
|
|
12
|
+
option_alert_acknowledged_hint_html: "Send when a user has acknowledged the alert"
|
|
13
|
+
option_alert_rejected_hint_html: "Send when a user has rejected the alert"
|
|
14
|
+
option_alert_timeout_hint_html: "Send when the alert has timed out a layer"
|
|
15
|
+
option_alert_resolved_hint_html: "Send when the alert is marked resolved"
|
|
16
|
+
option_alert_dropped_hint_html: "Send when the alert is dropped"
|
|
17
|
+
option_alert_handoff_hint_html: "Send when the alert has been handed off"
|
|
18
|
+
option_template_hint_html: "A handlebars template describing the body that should be posted. See <a href='https://pagertree.com/knowledge-base/outgoing-webhooks/#custom-format' target='_blank'>docs</a> for details."
|
|
19
|
+
option_send_linked_hint_html: "Send linked data (source, source_log, user, team)"
|
|
10
20
|
email:
|
|
11
21
|
v3:
|
|
12
22
|
form_options:
|
|
13
23
|
option_allow_spam_hint_html: "Allow emails marked as SPAM to create alerts"
|
|
14
24
|
option_dedup_threads_hint_html: "Ignore emails from same thread (ex: Prevents new alerts for replys on emails (aka: RE:RE:RE...))"
|
|
25
|
+
form:
|
|
26
|
+
v3:
|
|
27
|
+
form_options:
|
|
28
|
+
option_form_title_hint_html: "The form title (top of web browser bar)"
|
|
29
|
+
option_form_header_hint_html: "The form header (top of the page, in bold)"
|
|
30
|
+
option_form_instructions_hint_html: "Instructions for the user. Be clear and concise"
|
|
31
|
+
option_form_footer_text_hint_html: "The text in the footer (ex: Company Name)"
|
|
32
|
+
option_form_footer_link_hint_html: "URL the footer text should link to (ex: https://company.com)"
|
|
33
|
+
option_form_logo_hint_html: "A logo image to be used at the top of the form (ex: Company Logo)"
|
|
34
|
+
option_form_email_required_hint_html: "Should the email field be required to submit?"
|
|
35
|
+
option_form_phone_required_hint_html: "Should the phone field be required to submit?"
|
|
36
|
+
option_form_description_required_hint_html: "Should the description field be required to submit?"
|
|
37
|
+
option_form_urgency_required_hint_html: "Should the urgency field be required to submit?"
|
|
38
|
+
honeybadger:
|
|
39
|
+
v3:
|
|
40
|
+
form_options:
|
|
41
|
+
option_token_hint_html: "The Honeybadger-Token header can be used to authenticate requests from Honeybadger servers (optional)"
|
|
42
|
+
jira_server:
|
|
43
|
+
v3:
|
|
44
|
+
form_options:
|
|
45
|
+
option_issue_updated_hint_html: "Create alert on the jira:issue_updated event? (only one alert per unique issue)"
|
|
15
46
|
live_call_routing:
|
|
16
47
|
twilio:
|
|
17
48
|
v3:
|
|
@@ -28,39 +59,36 @@ en:
|
|
|
28
59
|
option_force_input_hint_html: "Force the caller to select a team (even if the integration only has one team)"
|
|
29
60
|
option_record_hint_html: "Record a voicemail when no one acknowledges the call"
|
|
30
61
|
option_record_emails_list_hint_html: "List of email addresses to notify when a voicemail has been recorded"
|
|
62
|
+
mattermost:
|
|
63
|
+
outgoing_webhook:
|
|
64
|
+
v3:
|
|
65
|
+
form_options:
|
|
66
|
+
option_token_hint_html: "The token can be used to authenticate requests from Mattermost servers (optional)"
|
|
31
67
|
outgoing_webhook:
|
|
32
68
|
v3:
|
|
33
69
|
form_options:
|
|
34
70
|
option_webhook_url_hint_html: "URL to POST to"
|
|
35
71
|
option_username_hint_html: "Basic auth username (optional)"
|
|
36
72
|
option_password_hint_html: "Basic auth password (optional)"
|
|
37
|
-
option_alert_created_hint_html: "Send when the alert is created (before its routed)"
|
|
38
|
-
option_alert_open_hint_html: "Send when the alert is marked open (it has been routed)"
|
|
39
|
-
option_alert_acknowledged_hint_html: "Send when a user has acknowledged the alert"
|
|
40
|
-
option_alert_rejected_hint_html: "Send when a user has rejected the alert"
|
|
41
|
-
option_alert_timeout_hint_html: "Send when the alert has timed out a layer"
|
|
42
|
-
option_alert_resolved_hint_html: "Send when the alert is marked resolved"
|
|
43
|
-
option_alert_dropped_hint_html: "Send when the alert is dropped"
|
|
44
|
-
option_alert_handoff_hint_html: "Send when the alert has been handed off"
|
|
45
73
|
option_template_hint_html: "A handlebars template describing the body that should be posted. See <a href='https://pagertree.com/knowledge-base/outgoing-webhooks/#custom-format' target='_blank'>docs</a> for details."
|
|
46
|
-
|
|
74
|
+
server_guard24:
|
|
75
|
+
v3:
|
|
76
|
+
form_options:
|
|
77
|
+
option_resolve_warn_hint_html: "Resolve the alert when <code>'check_result' === 'WARNING'</code>"
|
|
78
|
+
webhook:
|
|
79
|
+
v3:
|
|
80
|
+
form_options:
|
|
81
|
+
option_token_hint_html: "The PagerTree-Token header can be used to authenticate requests (optional)"
|
|
82
|
+
option_capture_additional_data_hint_html: "Capture additional data from the webhook (optional)"
|
|
47
83
|
# SCAFFOLD_INTEGRATION
|
|
48
84
|
|
|
49
85
|
|
|
50
86
|
activerecord:
|
|
51
87
|
attributes:
|
|
52
88
|
"pager_tree/integrations/integration":
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
option_api_key: "API Key"
|
|
57
|
-
"pager_tree/integrations/email/v3":
|
|
58
|
-
option_allow_spam: "Allow Spam"
|
|
59
|
-
option_dedup_threads: "Dedup Threads"
|
|
60
|
-
"pager_tree/integrations/outgoing_webhook/v3":
|
|
61
|
-
option_webhook_url: "URL"
|
|
62
|
-
option_username: "Username"
|
|
63
|
-
option_password: "Password"
|
|
89
|
+
option_title_template_enabled: "Title Template"
|
|
90
|
+
option_description_template_enabled: "Description Template"
|
|
91
|
+
option_incoming_webhook_url: "URL"
|
|
64
92
|
option_alert_created: "alert.created"
|
|
65
93
|
option_alert_open: "alert.open"
|
|
66
94
|
option_alert_acknowledged: "alert.acknowledged"
|
|
@@ -69,6 +97,33 @@ en:
|
|
|
69
97
|
option_alert_resolved: "alert.resolved"
|
|
70
98
|
option_alert_dropped: "alert.dropped"
|
|
71
99
|
option_alert_handoff: "alert.handoff"
|
|
100
|
+
option_outgoing_rules: "Outgoing Rules"
|
|
101
|
+
"pager_tree/integrations/apex_ping/v3":
|
|
102
|
+
option_api_key: "API Key"
|
|
103
|
+
"pager_tree/integrations/email/v3":
|
|
104
|
+
option_allow_spam: "Allow Spam"
|
|
105
|
+
option_dedup_threads: "Dedup Threads"
|
|
106
|
+
"pager_tree/integrations/form/v3":
|
|
107
|
+
option_form_title: "Form Title"
|
|
108
|
+
option_form_header: "Form Header"
|
|
109
|
+
option_form_instructions: "Instructions"
|
|
110
|
+
option_form_footer_text: "Footer Text"
|
|
111
|
+
option_form_footer_link: "Footer URL"
|
|
112
|
+
option_form_logo: "Logo"
|
|
113
|
+
option_form_email_required: "Email Required?"
|
|
114
|
+
option_form_phone_required: "Phone Required?"
|
|
115
|
+
option_form_description_required: "Description Required?"
|
|
116
|
+
option_form_urgency_required: "Urgency Required?"
|
|
117
|
+
"pager_tree/integrations/honeybadger/v3":
|
|
118
|
+
option_token: "Honeybadger Token"
|
|
119
|
+
"pager_tree/integrations/jira_server/v3":
|
|
120
|
+
option_issue_updated: "Trigger on issue.updated event"
|
|
121
|
+
"pager_tree/integrations/mattermost/outgoing_webhook/v3":
|
|
122
|
+
option_token: "Mattermost Token"
|
|
123
|
+
"pager_tree/integrations/outgoing_webhook/v3":
|
|
124
|
+
option_webhook_url: "URL"
|
|
125
|
+
option_username: "Username"
|
|
126
|
+
option_password: "Password"
|
|
72
127
|
option_template: "JSON Template"
|
|
73
128
|
option_send_linked: "Send Linked"
|
|
74
129
|
"pager_tree/integrations/live_call_routing/twilio/v3":
|
|
@@ -84,4 +139,9 @@ en:
|
|
|
84
139
|
option_force_input: "Force Caller Input"
|
|
85
140
|
option_record: "Voicemail"
|
|
86
141
|
option_record_emails_list: "Voicemail Emails"
|
|
142
|
+
"pager_tree/integrations/server_guard24/v3":
|
|
143
|
+
option_resolve_warn: "Resolve on Warning"
|
|
144
|
+
"pager_tree/integrations/webhook/v3":
|
|
145
|
+
option_token: "PagerTree Token"
|
|
146
|
+
option_capture_additional_data: "Capture Additional Data"
|
|
87
147
|
# SCAFFOLD_ACTIVE_RECORD
|
|
@@ -9,6 +9,7 @@ class IntegrationGenerator < Rails::Generators::NamedBase
|
|
|
9
9
|
end
|
|
10
10
|
|
|
11
11
|
def inject_locales
|
|
12
|
-
puts "IMPORTANT: Ensure you add your translations to config/locales/en.yml"
|
|
12
|
+
puts "IMPORTANT (1): Ensure you add your translations to config/locales/en.yml"
|
|
13
|
+
puts "IMPORTANT (2): Ensure you add your test fixtures to test/fixtures/pager_tree/integration/integrations.yml"
|
|
13
14
|
end
|
|
14
15
|
end
|
|
@@ -2,16 +2,16 @@ module PagerTree::Integrations
|
|
|
2
2
|
class <%= class_name %> < Integration
|
|
3
3
|
# TODO: Add options that are relevant to your integration
|
|
4
4
|
OPTIONS = [
|
|
5
|
-
{key: :api_key, type: :string, default: nil},
|
|
5
|
+
# {key: :api_key, type: :string, default: nil},
|
|
6
6
|
]
|
|
7
7
|
store_accessor :options, *OPTIONS.map { |x| x[:key] }.map(&:to_s), prefix: "option"
|
|
8
8
|
|
|
9
9
|
# TODO - add some validations for your options
|
|
10
|
-
validates :option_api_key, presence: true
|
|
10
|
+
# validates :option_api_key, presence: true
|
|
11
11
|
|
|
12
12
|
# TODO - add defaults for your options
|
|
13
13
|
after_initialize do
|
|
14
|
-
self.option_api_key ||= nil
|
|
14
|
+
# self.option_api_key ||= nil
|
|
15
15
|
end
|
|
16
16
|
|
|
17
17
|
# TODO: Does this integration support incoming requests?
|
|
@@ -21,7 +21,7 @@ module PagerTree::Integrations
|
|
|
21
21
|
|
|
22
22
|
# TODO: Does this integration support outgoing events?
|
|
23
23
|
def adapter_supports_outgoing?
|
|
24
|
-
|
|
24
|
+
false
|
|
25
25
|
end
|
|
26
26
|
|
|
27
27
|
# TODO: can requests from this integration be deferred? most integrations should be 'true'
|
|
@@ -43,8 +43,8 @@ module PagerTree::Integrations
|
|
|
43
43
|
# TODO: Implement your transform
|
|
44
44
|
def adapter_process_create
|
|
45
45
|
Alert.new(
|
|
46
|
-
title:
|
|
47
|
-
|
|
46
|
+
title: _title,
|
|
47
|
+
description: _description,
|
|
48
48
|
thirdparty_id: adapter_thirdparty_id,
|
|
49
49
|
dedup_keys: [adapter_thirdparty_id],
|
|
50
50
|
additional_data: _additional_datums
|
|
@@ -53,6 +53,16 @@ module PagerTree::Integrations
|
|
|
53
53
|
|
|
54
54
|
private
|
|
55
55
|
|
|
56
|
+
# TODO: Implement title
|
|
57
|
+
def _title
|
|
58
|
+
adapter_incoming_request_params.dig("title")
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# TODO: Implement description
|
|
62
|
+
def _description
|
|
63
|
+
adapter_incoming_request_params.dig("description")
|
|
64
|
+
end
|
|
65
|
+
|
|
56
66
|
# TODO: Implement any additional data that should be shown in the alert with high priority (be picky as to 'very important' information)
|
|
57
67
|
def _additional_datums
|
|
58
68
|
[
|