Send event data from PostHog into the Discord server and channel of your choice.
Requirements
Using this requires either PostHog Cloud with the data pipelines add-on, or a self-hosted PostHog instance running a recent version of the Docker image.
Setup
Discord: create a webhook
- In Discord, go to the server you want to send events to.
- Click the server name in the top left and select Server Settings.
- Select Integrations, in the Apps section.
- Select Webhooks, then New Webhook.
- Give the webhook a name and pick the channel you want to send events to.
- Copy the webhook URL.
PostHog: create a destination
- Back in PostHog, click the Data pipelines tab in the left sidebar.
- Click the Destinations tab.
- Search for Discord and select the destination.
- Add your Webhook URL.
- Use the Content field to format your message. You can include any properties that exist on
event
orperson
. - Use the Filters panel to set up a query to filter the events you want to send, otherwise you'll get a firehose of all events filling your channel.
- Press Create & enable. Events will now be sent to Discord. If you'd like to send a test event to your channel, hit the Start testing button.
Configuration
Option | Description |
---|---|
Webhook URL Type: string Required: True | See this page on how to generate a Webhook URL: https://support.discord.com/hc/en-us/articles/228383668-Intro-to-Webhooks |
Content Type: string Required: True | (see https://support.discord.com/hc/en-us/articles/210298617-Markdown-Text-101-Chat-Formatting-Bold-Italic-Underline) |
FAQ
Is the source code for this destination available?
PostHog is open-source and so are all the destination on the platform. The source code is available on GitHub.
Who maintains this?
This is maintained by PostHog. If you have issues with it not functioning as intended, please let us know!
What if I have feedback on this destination?
We love feature requests and feedback. Please tell us what you think.
What if my question isn't answered above?
We love answering questions. Ask us anything via our community forum.