DEV Community

Cover image for How to get GitHub Notifications in Discord Server?
Ashik Chapagain
Ashik Chapagain

Posted on • Originally published at cb-ashik.hashnode.dev

How to get GitHub Notifications in Discord Server?

Are you interested in receiving all of your GitHub notifications on your Discord server?

Here's how to do that.

We will go over how to get GitHub notifications in Discord Server in this article. Now, let's begin.

To begin, I'm assuming you have a Discord and GitHub account.

Index

Let's start by creating a Discord Server.

Creating Discord Server

  1. In the bottom left corner, click on the + icon.
    image.png

  2. Once you've done that, click on Create My Own.
    image.png

  3. Choose For me and my friends
    image.png

  4. Now, give your server a name. After that, select Create.
    image.png

Now, the discord server is ready, if you want to get Github Notification notices delivered to a separate text channel, you may create a new one.
image.png

Now, let's create a GitHub repo.

Creating GitHub Repo

  1. Click here to create a new GitHub repo.
  2. Give your repo a name and click Create Repository. image.png

Now, our GitHub repo is also ready, now, it's time to setup our Discord server to receive GitHub notifications.

Receiving Notifications

  1. Click on the βš™οΈ icon just right of the text channel where you want to receive notifications. image.png
  2. Next, click on Integrations and then click on Create Webhook. image.png
  3. Now, a new webhook is created, if you want to change it's name, you can do so. But I'll leave it as it is. image.png
  4. Then click on Copy Webhook URL. image.png

Once the Webhook URL is copied,

  • Go to your GitHub repo and click on settings. image.png
  • Then click on Webhooks.
  • Next, click on Add webhook. image.png Then you might need to confirm your password.
  • Now add the web hook URL with /github on the end in Payload URL. image.png
  • Now, set the content type to application/json.
  • In the Which events would you like to trigger this webhook? section, select Send me everything. to receive every GitHub notification.
  • Now click on Add Webhook, and now, you can receive all GitHub notifications in your discord server .πŸ₯³πŸ₯³πŸ₯³

If everything was set up perfectly, then you should see the green tick on the webhook.
image.png

Testing

For testing, let's clone the clone and push a commit.

  1. Clone the repo
git clone https://github.com/YOUR_USERNAME/YOUR_REPO.git
Enter fullscreen mode Exit fullscreen mode
  1. Create a new random file, I will create README.md with following content.
# Testing
Enter fullscreen mode Exit fullscreen mode
  1. Run the following commands
git add .
git commit -m "Added readme.md"
git branch -M main
git push -u origin main
Enter fullscreen mode Exit fullscreen mode
  1. Now, go to your discord server and you should see something like this. image.png

Conclusion

This was a short article on how to receive GitHub notification to your Discord Server. Hope you like this article. If you got any problem or have any feedback or suggestion for me, comment it.

Connect with me:

Top comments (4)

Collapse
 
darshkul24 profile image
Darsh

Great bro

Collapse
 
chapagainashik profile image
Ashik Chapagain

Thanks

Collapse
 
darshkul24 profile image
Darsh

collab ??

Thread Thread
 
chapagainashik profile image
Ashik Chapagain

You mean to do collab with me.