Moved to Community Support.
There are multiple ways you could do this, as mentioned above you can use Skript, there are also other ways you could create custom commands to display the discord link. DiscordSRV also includes this if you want to link your chat to the discord and vice versa.