Automatically Publish YouTube Videos to Discord with a Simple Youtube Bot Setup

WpScriptly on Discord
WpScriptly on Discord

I needed a way to automatically publish videos from YouTube to our Discord server. So, I went to https://top.gg/ and found a YouTube bot that does exactly what I need. Now, whenever our fearless YouTuber at Profane Productions (@ProfaneProductions">https://www.youtube.com/@ProfaneProductions) posts a video, it will automatically appear in our Discord channel. I reached out to one of the developers of the bot, Dewaldsch, and he guided me through the setup process. Below, you’ll find the commands and steps to configure the bot for your Discord server.

Update:

Dewaldsch reports: Just remember if you have the /notify servermessage set that sets all the message to same if you then use /nofy list and slect the edit custom message button it overwrites the one set in the command /notify servermessage

Example:

YouTube Bot Tutorial

First, invite the bot to your server using this link:
Invite YouTube Bot <-link to the Youtube bot discord

The YouTube Bot will not add a YouTube channel if it doesn’t have the correct channel permissions. As a result, it will not notify you about the newest video from the YouTube channel.

Make sure to give the bot the following channel permissions:

  • View Channel
  • Read Messages
  • Send Messages
  • Embed Links
  • Mention @everyone, @here, and all roles

Setting Channel Permissions:

  1. Open the channel settings by clicking the gear icon next to the channel name (near the “Invite People” icon).
  2. Select “Permissions.”
  3. Under “Advanced Permissions,” click the plus icon.
  4. Choose the YouTube bot (make sure it’s the one with the YouTube logo) and assign the necessary permissions.

To add a YouTube channel, use the following command:

/notify add
  1. Select the Discord location where you want to receive notifications.
  2. A popup will ask you to enter the YouTube channel URL. You can also input the channel name.

If you need to find the YouTube channel ID, you can use this website:
YouTube Channel ID Finder

Input the channel in this format:

https://www.youtube.com/channel/ID

List of Commands:

General Commands:

  • /invite – Get a link to invite the bot to your server.
  • /support – Get a link to the bot support server.
  • /ping – Check the bot’s current ping.
  • /stats – Display statistics about the bot.
  • /premium – Learn more about the YouTube Bot’s premium plans, which allow you to follow more YouTube channels.

YouTube Commands:

  • /video <video_id|videoURL|search> – Get information about a video using the video ID, URL, or a search term.
  • /channel <channel_id|channelURL|search> – Get information about a YouTube channel using the channel ID, URL, or search term.
  • /playlist <playlist_id|playlistURL|search> – Get information about a playlist.
  • /random [keyword] – Generate a random YouTube video using a randomly selected keyword or your own keyword.
  • /trending – Display a list of trending videos on YouTube.
  • /watch <#VoiceChannel> – Start a YouTube watch party in the selected voice channel.

Notifier Commands & Info:

  • /notify list – Display all channels you’ve set up for notifications and manage them (edit or delete).
  • /notify add – Add a YouTube channel to get notified when a new video is uploaded.
  • /notify reset – Remove all YouTube channels from your notification list.

Customizing Upload Messages:
You can edit the upload message for each channel by clicking “Edit Message” under /notify list. You can use the following placeholders in your custom message:

  • {title} – Displays the title of the video.
  • {url} – Displays the shortened URL of the video.
  • {url-long} / {urllong} / {longurl} – Displays the full URL of the video.
  • {channel} / {channelname} – Displays the name of the YouTube channel.
  • {channelurl} – Displays the URL of the YouTube channel.
  • {everyone} – Pings @everyone.

Note:
To ping a role in your custom message, first type the role in a new message like this:

\@RoleName

Copy the formatted role tag (e.g., <@&809077615948333077>) and paste it into your custom message.


Use this website to find the channel ID for new @username-formatted channels:
YouTube Channel ID and Username Converter


YouTubeBot Help | General

General commands and information about the bot:

  • /help [category] – Get a list of commands, optionally filtered by category.
  • /invite – Get a link to invite the bot to your server.
  • /support – Get a link to the support server.
  • /ping – Check the bot’s current ping.
  • /stats – View the bot’s statistics.
  • /policy – Read the bot’s privacy policy.
  • /premium – Learn more about premium plans.

YouTubeBot Help | YouTube

Commands for YouTube Data Fetching:

  • /video <video_id|videoURL|search> – Get information about a video.
  • /channel <channel_id|channelURL|search> – Get information about a channel.
  • /playlist <playlist_id|playlistURL|search> – Get information about a playlist.
  • /random [keyword] – Get a random video, optionally using a keyword.
  • /trending – Display a list of trending videos.
  • /watch <#VoiceChannel> – Start a watch-together party in a voice channel.

YouTubeBot Help | Notifier

Notifier commands for managing notifications and settings:

  • /notify list – View your current subscriptions.
  • /notify add <discord channel> – Add a new subscription for a YouTube channel.
  • /notify reset – Reset your subscriptions.
  • /notify placeholders – View a list of available placeholders.
  • /notify servermessage – Manage your server-wide custom message.

Dewaldsch
Support Team Leader at YT Bot <- Big thanks to D for the help!!

Notes:

Wp Scriptly

This basic script, CSS style, and plugin are designed to function optimally assuming minimal interference from your theme or other plugins. If conflicts occur or further customization is needed, additional adjustments may be necessary. Please note that this script, CSS style, or plugin must be used AS IS.

Wp Scriptly

Newsletter Signup

WP Scriptly Newsletter

The WpScriptly Monthly newsletter offers top insights for WordPress pros: new scripts, plugins, resources, tips, tools, updates, and more every month.
*Wp Scriptly will not share or sell your name and email adress to anyone!

Comments: