Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 

README.md

Disqord

Build Status NuGet MyGet The Lab

An asynchronous .NET Core 3.0 Discord API wrapper.

Inspired by Discord.Net, DSharpPlus, and discord.py.

Installing

Stable Disqord builds can be pulled from NuGet. For nightly builds add https://www.myget.org/F/quahu/api/v3/index.json (the nightly feed) to your project's package sources and pull from there instead.

Documentation

There's currently no official documentation for Disqord except for the bundled XML docstrings. For support you should hop in my Discord guild:

The Lab

A Simple Ping-Pong Bot Example

Typing ?ping or @YourBot ping in the chat would reply with Pong!.

using System.Threading.Tasks;
using Disqord;
using Disqord.Bot;
using Disqord.Bot.Prefixes;
using Qmmands;

namespace Example
{
    public sealed class Program
    {
        public static void Main()
        {
            var prefixProvider = new DefaultPrefixProvider()
                .AddPrefix('?')
                .AddMentionPrefix();
            using (var bot = new DiscordBot(TokenType.Bot, "token", prefixProvider))
            {
                bot.AddModule<Commands>();
                bot.Run();
            }
        }
    }

    public sealed class Commands : DiscordModuleBase
    {
        [Command("ping")]
        public Task PingAsync()
            => ReplyAsync("Pong!");
    }
}
You can’t perform that action at this time.