summaryrefslogtreecommitdiffstats
path: root/doc/integrations
diff options
context:
space:
mode:
authorJoramWilander <jwawilander@gmail.com>2015-10-13 11:39:56 -0400
committerJoramWilander <jwawilander@gmail.com>2015-10-13 11:39:56 -0400
commitb42d7a03c7e1ff12642ad87c103044b8f858e865 (patch)
treef3c8bbdafad607e1a49ebc869d515aeb3ab232f8 /doc/integrations
parent151b929c91e01c1ebf6c41c7c1b821153d9a29b6 (diff)
downloadchat-b42d7a03c7e1ff12642ad87c103044b8f858e865.tar.gz
chat-b42d7a03c7e1ff12642ad87c103044b8f858e865.tar.bz2
chat-b42d7a03c7e1ff12642ad87c103044b8f858e865.zip
Minor doc updates
Diffstat (limited to 'doc/integrations')
-rw-r--r--doc/integrations/webhooks/Incoming-Webhooks.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/integrations/webhooks/Incoming-Webhooks.md b/doc/integrations/webhooks/Incoming-Webhooks.md
index 45d9c7dad..6d9ce3a31 100644
--- a/doc/integrations/webhooks/Incoming-Webhooks.md
+++ b/doc/integrations/webhooks/Incoming-Webhooks.md
@@ -61,13 +61,13 @@ curl -i -X POST -d 'payload={"text": "Hello, this is some text."}' http://yourma
```
3. Build your integration in the programming language of your choice
- 1. Most integrations will be used to translate some sort of output of from another system to an appropriately formatted input that will be passed into the Mattermost webhook URL. For example, an integration could take events generated by [GitLab outgoing webhooks](http://doc.gitlab.com/ee/web_hooks/web_hooks.html) and parse them into a JSON body to post into Mattermost.
+ 1. Most integrations will be used to translate some sort of output from another system to an appropriately formatted input that will be passed into the Mattermost webhook URL. For example, an integration could take events generated by [GitLab outgoing webhooks](http://doc.gitlab.com/ee/web_hooks/web_hooks.html) and parse them into a JSON body to post into Mattermost.
1. To get the message posted into Mattermost, your integration will need to create an HTTP POST request that will submit to the incoming webhook URL you created before. The body of the request must have a `payload` that contains a JSON object that specifies a `text` parameter. For example, `payload={"text": "Hello, this is some text."}` is a valid body for a request.
2. Setup your integration running on Heroku, an AWS server or a server of your own to start sending real time updates to Mattermost channels and private groups.
Additional Notes:
-1. For the HTTP request body, if `Content-Type` is specified as `application/json` in the headers of the HTTP request then the body of the request can be direct JSON. ```{"text": "Hello, this is some text."}```
+1. For the HTTP request body, if `Content-Type` is specified as `application/json` in the headers of the HTTP request then the body of the request can be direct JSON. For example, ```{"text": "Hello, this is some text."}```
2. You can override the channel specified in the webhook definition by specifying a `channel` parameter in your payload. For example, you might have a single webhook created for _Town Square_, but you can use ```payload={"channel": "off-topic", "text": "Hello, this is some text."}``` to send a message to the _Off-Topic_ channel using the same webhook URL.