# Discourse webhook displays private messages

**URL:** https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749
**Category:** Support
**Created:** [June 25, 2018, 11:27pm UTC](https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749 "2018-06-25T23:27:00Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![nexo](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nexo/32/106384_2.png) [@nexo](https://meta.discourse.org/u/nexo)
#### Post date: [June 25, 2018, 11:27pm UTC](https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749/1 "2018-06-25T23:27:00Z")

</div>

I chose my webhook to only push `post event` because it covers both new topics made and new posts/replies made.

The issue: it alerts everytime someone sends a private message. I know that private messages are technically a topic but shouldn’t there be a way to block that out or at least only deliver **topic** replies and creations?

 ![Capture68](https://global.discourse-cdn.com/meta/original/3X/9/2/92c3a386c39b68c21bf6c3bf5c90782c07996af3.PNG)

---

<div class="post-metadata">

### Author: ![nexo](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nexo/32/106384_2.png) [@nexo](https://meta.discourse.org/u/nexo)
#### Post date: [June 26, 2018, 7:47am UTC](https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749/2 "2018-06-26T07:47:56Z")

</div>

Also, anyone can click to view the private message even if theyre not invited to it 😓

---

<div class="post-metadata">

### Author: ![vinothkannans](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vinothkannans/32/86465_2.png) [@vinothkannans](https://meta.discourse.org/u/vinothkannans)
#### Post date: [June 26, 2018, 8:09am UTC](https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749/3 "2018-06-26T08:09:38Z")

</div>

It’s not possible to filter pm replies in post event webhooks. But you can do it via a custom plugin.

If you are not an admin and don’t have access to the PM then you can’t view the messages in it.

---

<div class="post-metadata">

### Author: ![david](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/david/32/157490_2.png) [@david](https://meta.discourse.org/u/david)
#### Post date: [June 26, 2018, 8:30am UTC](https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749/4 "2018-06-26T08:30:28Z")

</div>

> [@nexo](#):
>
> ![Capture68](https://global.discourse-cdn.com/meta/original/3X/9/2/92c3a386c39b68c21bf6c3bf5c90782c07996af3.PNG)

🤔 that screenshot looks like Discord to me. Have you thought about using the discourse-chat-integration plugin instead of webhooks? It provides loads of filtering options:

> [@Set up Discord notifications with the discourse-chat-integration plugin](https://meta.discourse.org/t/set-up-discord-notifications-using-the-discourse-chat-integration-plugin/66600):
>
> bookmark This guide explains how to configure Discord notifications for your Discourse forum using the discourse-chat-integration plugin. This plugin is included with Discourse — no separate installation is required. person_raising_hand Required user level: Administrator Set up Discord webhook Log into your Discord server Click your server name and choose “Server Settings” Click Integrations, then Webhooks. Then click Create Webhook Choose a bot name, icon…

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [July 26, 2018, 8:30am UTC](https://meta.discourse.org/t/discourse-webhook-displays-private-messages/90749/5 "2018-07-26T08:30:35Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
