Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

integrations: Add incoming webhook macro to relevant docs.

David Rosa620854d437cb
diff --git a/static/images/integrations/bot_types.png b/static/images/integrations/bot_types.png
deleted file mode 100644
index d819311707d..00000000000
Binary files a/static/images/integrations/bot_types.png and /dev/null differ
diff --git a/static/images/integrations/bot_types_incoming_webhook.png b/static/images/integrations/bot_types_incoming_webhook.png
new file mode 100644
index 00000000000..14eb37ebd39
Binary files /dev/null and b/static/images/integrations/bot_types_incoming_webhook.png differ
diff --git a/templates/zerver/help/include/create-a-bot.md b/templates/zerver/help/include/create-an-incoming-webhook.md
similarity index 70%
rename from templates/zerver/help/include/create-a-bot.md
rename to templates/zerver/help/include/create-an-incoming-webhook.md
index c8000e37c47..696c63c1b89 100644
--- a/templates/zerver/help/include/create-a-bot.md
+++ b/templates/zerver/help/include/create-an-incoming-webhook.md
@@ -2,4 +2,4 @@
{{ integration_display_name }}. Make sure that you select
**Incoming webhook** as the **Bot type**:
-![](/static/images/integrations/bot_types.png)
+![](/static/images/integrations/bot_types_incoming_webhook.png)
diff --git a/templates/zerver/help/include/create-bot-construct-url.md b/templates/zerver/help/include/create-bot-construct-url.md
index c85f09545f7..72b125dc842 100644
--- a/templates/zerver/help/include/create-bot-construct-url.md
+++ b/templates/zerver/help/include/create-bot-construct-url.md
@@ -1,4 +1,4 @@
-{!create-a-bot.md!}
+{!create-an-incoming-webhook.md!}
Construct the URL for the {{ integration_display_name }}
bot using the bot's API key and the desired stream name:
diff --git a/templates/zerver/integrations/asana.md b/templates/zerver/integrations/asana.md
index 2664e3a3536..aa417acd110 100644
--- a/templates/zerver/integrations/asana.md
+++ b/templates/zerver/integrations/asana.md
@@ -2,11 +2,7 @@ Get Zulip notifications for your Asana projects via Zapier!
1. {!create-stream.md!}
-1. Next, on your {{ settings_html|safe }}, create a bot for Asana.
- Construct the URL for the Asana bot using the bot API key and
- stream name, like so:
-
- `{{ api_url }}/v1/external/zapier?api_key=abcdefgh&stream=asana`
+1. {!create-bot-construct-url.md!}
1. Start by setting up a [Zapier](https://zapier.com/) account.
diff --git a/templates/zerver/integrations/capistrano.md b/templates/zerver/integrations/capistrano.md
index 158118a19fb..fb16384291f 100644
--- a/templates/zerver/integrations/capistrano.md
+++ b/templates/zerver/integrations/capistrano.md
@@ -1,6 +1,6 @@
Get Zulip notifications for your Capistrano deploys!
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
1. {!download-python-bindings.md!}
diff --git a/templates/zerver/integrations/codebase.md b/templates/zerver/integrations/codebase.md
index 75f6bf384dd..2cd864bff00 100644
--- a/templates/zerver/integrations/codebase.md
+++ b/templates/zerver/integrations/codebase.md
@@ -5,7 +5,7 @@ Get Codebase notifications in Zulip!
updates. We recommend naming the streams `codebase` and `tickets`, respectively.
After creating these streams, make sure to subscribe all interested parties.
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
1. {!download-python-bindings.md!}
diff --git a/templates/zerver/integrations/discourse.md b/templates/zerver/integrations/discourse.md
index 78e968f342c..730efbca027 100644
--- a/templates/zerver/integrations/discourse.md
+++ b/templates/zerver/integrations/discourse.md
@@ -1,9 +1,4 @@
-1. On your {{ settings_html|safe }},
- [create a bot](/help/add-a-bot-or-integration) for
- {{ integration_display_name }}. Make sure that you select
- **Incoming webhook** as the **Bot type**:
-
- ![Bot types](/static/images/integrations/bot_types.png)
+1. {!create-an-incoming-webhook.md!}
The API keys for "Incoming webhook" bots are limited to only
sending messages via webhooks. Thus, this bot type lessens
diff --git a/templates/zerver/integrations/git.md b/templates/zerver/integrations/git.md
index ba6117ee574..059c4bc1a9e 100644
--- a/templates/zerver/integrations/git.md
+++ b/templates/zerver/integrations/git.md
@@ -1,6 +1,6 @@
Get Zulip notifications for your Git repositories!
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
1. {!download-python-bindings.md!}
diff --git a/templates/zerver/integrations/jenkins.md b/templates/zerver/integrations/jenkins.md
index 9f1bd3244c0..2dec12a828c 100644
--- a/templates/zerver/integrations/jenkins.md
+++ b/templates/zerver/integrations/jenkins.md
@@ -1,6 +1,6 @@
1. {!create-stream.md!}
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
1. Install the "Zulip" plugin by going to
**Manage Jenkins > Manage Plugins > Available**,
diff --git a/templates/zerver/integrations/nagios.md b/templates/zerver/integrations/nagios.md
index 50673fa31dc..671eb0b186e 100644
--- a/templates/zerver/integrations/nagios.md
+++ b/templates/zerver/integrations/nagios.md
@@ -2,8 +2,7 @@
1. {!download-python-bindings.md!}
-1. Next, on your {{ settings_html|safe }}, create a bot for
- {{ integration_display_name }}.
+1. {!create-an-incoming-webhook.md!}
1. Next, open `integrations/nagios/zuliprc.example` in your favorite
editor, and change the following lines to specify the email address
diff --git a/templates/zerver/integrations/twitter.md b/templates/zerver/integrations/twitter.md
index 8dc0b89fd00..75be962cb1c 100644
--- a/templates/zerver/integrations/twitter.md
+++ b/templates/zerver/integrations/twitter.md
@@ -4,12 +4,7 @@ important topics in real time.
1. {!create-stream.md!}
-1. Next, on your {{ settings_html|safe }},
- [create a bot](/help/add-a-bot-or-integration) for
- {{ integration_display_name }}. Make sure that you select
- **Incoming webhook** as the **Bot type**:
-
- ![Bot types](/static/images/integrations/bot_types.png)
+1. {!create-an-incoming-webhook.md!}
The API keys for "Incoming webhook" bots are limited to only
sending messages via webhooks. Thus, this bot type lessens
diff --git a/zerver/webhooks/beanstalk/doc.md b/zerver/webhooks/beanstalk/doc.md
index d6d54e1806c..5faa9a68dd9 100644
--- a/zerver/webhooks/beanstalk/doc.md
+++ b/zerver/webhooks/beanstalk/doc.md
@@ -2,7 +2,7 @@ Zulip supports both SVN and Git notifications from Beanstalk.
1. {!create-stream.md!}
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
{!webhook-url-with-bot-email.md!}
{!git-append-branches.md!}
diff --git a/zerver/webhooks/buildbot/doc.md b/zerver/webhooks/buildbot/doc.md
index 67af3be505e..5ddd75057a3 100644
--- a/zerver/webhooks/buildbot/doc.md
+++ b/zerver/webhooks/buildbot/doc.md
@@ -6,7 +6,7 @@ Get Zulip notifications for your Buildbot builds!
1. {!create-stream.md!}
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
1. Edit the Buildbot configuration file to add a new Zulip reporter
([or follow the steps listed here][1]):
diff --git a/zerver/webhooks/deskdotcom/doc.md b/zerver/webhooks/deskdotcom/doc.md
index 5dbd825b8af..a50adea8545 100644
--- a/zerver/webhooks/deskdotcom/doc.md
+++ b/zerver/webhooks/deskdotcom/doc.md
@@ -3,8 +3,7 @@
Keep in mind you still need to create the stream first even
if you are using this recommendation.
-1. Next, on your {{ settings_html|safe }}, create a bot and
- note its email and API key.
+1. {!create-an-incoming-webhook.md!}
1. Next, in Desk.com, open your **Admin** view via the top-left
dropdown. In the **Admin** view, click on **Apps**, then
diff --git a/zerver/webhooks/dialogflow/doc.md b/zerver/webhooks/dialogflow/doc.md
index 3cdc3408f0f..aeedfb25358 100644
--- a/zerver/webhooks/dialogflow/doc.md
+++ b/zerver/webhooks/dialogflow/doc.md
@@ -1,17 +1,16 @@
-Get personal message notifications in Zulip for the results of your Dialogflow queries!
+Get personal message notifications in Zulip for the results of your
+Dialogflow queries!
1. {!create-stream.md!}
-1. Next, on your {{ settings_html|safe }}, [create a bot](/help/add-a-bot-or-integration) for
- {{ integration_display_name }}. Make sure that you select
- **Incoming webhook** as the **Bot type**.
+1. {!create-an-incoming-webhook.md!}
The API key for an incoming webhook bot cannot be used to read messages out
of Zulip. Thus, using an incoming webhook bot lowers the security risk of
exposing the bot's API key to a third-party service.
- Construct the URL for the Dialogflow bot using the bot's API key and your Zulip email.
- The webhook URL should look like:
+ Construct the URL for the Dialogflow bot using the bot's API key and your
+ Zulip email. The webhook URL should look like:
`{{api_url}}?api_key=BOT'S_API_KEY&[email protected]`
diff --git a/zerver/webhooks/homeassistant/doc.md b/zerver/webhooks/homeassistant/doc.md
index fc070017f87..0f299bbc9cf 100644
--- a/zerver/webhooks/homeassistant/doc.md
+++ b/zerver/webhooks/homeassistant/doc.md
@@ -1,7 +1,6 @@
1. {!create-stream.md!}
-1. Next, on your {{ settings_html|safe }}, create a bot and
- note its email and API key.
+1. {!create-an-incoming-webhook.md!}
1. In Home Assistant, you need to add the `notify` service to your
`configuration.yaml` file. This should look something like this:
diff --git a/zerver/webhooks/zapier/doc.md b/zerver/webhooks/zapier/doc.md
index 14c24708a70..ea9d7b134fd 100644
--- a/zerver/webhooks/zapier/doc.md
+++ b/zerver/webhooks/zapier/doc.md
@@ -4,7 +4,7 @@ sent by Zapier directly in Zulip.
1. {!create-stream.md!}
-1. {!create-a-bot.md!}
+1. {!create-an-incoming-webhook.md!}
1. Create an account on [Zapier](https://zapier.com).
diff --git a/zerver/webhooks/zendesk/doc.md b/zerver/webhooks/zendesk/doc.md
index ce7a7b26270..cc92fad5d7b 100644
--- a/zerver/webhooks/zendesk/doc.md
+++ b/zerver/webhooks/zendesk/doc.md
@@ -1,6 +1,6 @@
1. {!create-stream.md!}
-1. Next, on your {{ settings_html|safe }}, create a bot.
+1. {!create-an-incoming-webhook.md!}
1. Construct a webhook URL like the following: