Discord.Net.Labs.WebSocket
2.3.9-dev
See the version list below for details.
dotnet add package Discord.Net.Labs.WebSocket --version 2.3.9-dev
NuGet\Install-Package Discord.Net.Labs.WebSocket -Version 2.3.9-dev
<PackageReference Include="Discord.Net.Labs.WebSocket" Version="2.3.9-dev" />
paket add Discord.Net.Labs.WebSocket --version 2.3.9-dev
#r "nuget: Discord.Net.Labs.WebSocket, 2.3.9-dev"
// Install Discord.Net.Labs.WebSocket as a Cake Addin #addin nuget:?package=Discord.Net.Labs.WebSocket&version=2.3.9-dev&prerelease // Install Discord.Net.Labs.WebSocket as a Cake Tool #tool nuget:?package=Discord.Net.Labs.WebSocket&version=2.3.9-dev&prerelease
Discord.Net Labs
Join our Discord server for support using labs
This repo is a custom fork of Discord.Net that introduces the newest features of discord for testing and experimenting. Nothing here is guaranteed to work but you are more than welcome to submit bugs in the issues tabs
Known issues
Labs will not work with Playwo's InteractivityAddon. The reason is that his package depends on the base discord.net lib, you can get around this by cloning his repo and building it with discord.net labs instead of discord.net.
How to use
Setting up labs in your project is really simple, here's how to do it:
- Remove Discord.Net from your project
- Add Discord.Net Labs nuget to your project
- Enjoy!
Branches
Dev
The main branch we pull off of to introduce new features into, the dev branch is the same as Discord.Nets dev branch
Interactions
This branch is for anything todo with Discord Interactions, such as Slash commands and Message Components. This branch is stable enough to use but does not contain all the features of interactions.
SlashCommandService
This branch is on pause and does not work currently, Once everything is stable with the Interaction branch we will continue working on a slash command service for it.
web/SlashCommandService
webmilio's spin on the SlashCommandService branch, again the state of this is unknown.
Message Components
So, you want to use Message components? Well you're in luck! Below is a quick overview of how to use them
Listening for button presses
// Subscribe to the InteractionCreated event
client.InteractionCreated += Client_InteractionCreated;
...
private async Task Client_InteractionCreated(SocketInteraction arg)
{
// If the type of the interaction is a message component
if(arg.Type == Discord.InteractionType.MessageComponent)
{
// parse the args
var parsedArg = (SocketMessageComponent)arg;
// respond with the update message response type. This edits the original message if you have set AlwaysAcknowledgeInteractions to false.
await parsedArg.RespondAsync($"Clicked {parsedArg.Data.CustomId}!", type: InteractionResponseType.UpdateMessage);
}
}
Sending messages with buttons
Theres a new field in all SendMessageAsync
functions that takes in a MessageComponent
, you can use it like so:
var builder = new ComponentBuilder().WithButton("Hello!", ButtonStyle.Primary, customId: "id_1");
await Context.Channel.SendMessageAsync("Test buttons!", component: builder.Build());
Slash commands
Slash command example how to's can be found here. If you want to read some code using slash commands, you can do that here
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 is compatible. |
.NET Framework | net461 is compatible. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETFramework 4.6.1
- Discord.Net.Labs.Core (>= 2.3.9-pre)
- Discord.Net.Labs.Rest (>= 2.3.9-pre)
-
.NETStandard 2.0
- Discord.Net.Labs.Core (>= 2.3.9-pre)
- Discord.Net.Labs.Rest (>= 2.3.9-pre)
-
.NETStandard 2.1
- Discord.Net.Labs.Core (>= 2.3.9-pre)
- Discord.Net.Labs.Rest (>= 2.3.9-pre)
NuGet packages (4)
Showing the top 4 NuGet packages that depend on Discord.Net.Labs.WebSocket:
Package | Downloads |
---|---|
Discord.Net.Labs
An experimental fork of Discord.NET that adds all the new discord features to play around with! This metapackage includes all of the optional Discord.Net Labs components. |
|
Discord.Net.Labs.Interactions
A Discord.Net Labs extension adding support for Application Commands. |
|
Fergun.Interactive.Labs
An addon that adds interactive functionality to commands. This is a fork of Discord.InteractivityAddon that adds several features like more customization and support for interactions. |
|
Discord.InteractivityAddon.Labs
This package is an Addon for Discord.Net. It provides basic and advanced interactivity features for your Discord Bot. Moreover it includes support for any command framework. |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated | |
---|---|---|---|
3.6.1 | 25,545 | 12/24/2021 | |
3.6.0 | 1,164 | 12/24/2021 | |
3.5.0 | 2,799 | 12/15/2021 | |
3.4.9 | 5,750 | 12/6/2021 | |
3.4.8 | 5,832 | 12/4/2021 | |
3.4.7 | 3,738 | 11/28/2021 | |
3.4.6 | 1,042 | 11/27/2021 | |
3.4.5 | 886 | 11/27/2021 | |
3.4.4 | 1,009 | 11/27/2021 | |
3.4.3 | 1,027 | 11/27/2021 | |
3.4.2 | 3,238 | 11/26/2021 | |
3.4.1 | 2,497 | 11/26/2021 | |
3.4.0 | 2,554 | 11/26/2021 | |
3.3.3 | 1,482 | 11/23/2021 | |
3.3.2 | 1,358 | 11/21/2021 | |
3.3.1 | 1,533 | 11/21/2021 | |
3.3.0 | 1,778 | 11/19/2021 | |
3.2.0 | 2,661 | 11/9/2021 | |
3.1.7 | 3,823 | 10/20/2021 | |
3.1.6 | 1,704 | 10/15/2021 | |
3.1.5 | 1,009 | 10/15/2021 | |
3.1.4 | 2,643 | 10/13/2021 | |
3.1.2 | 1,729 | 10/12/2021 | |
3.1.1 | 3,631 | 9/23/2021 | |
3.1.0 | 2,281 | 9/21/2021 | |
3.0.4 | 1,508 | 9/15/2021 | |
3.0.3 | 3,649 | 9/13/2021 | |
3.0.2 | 4,095 | 8/25/2021 | |
3.0.1 | 913 | 8/25/2021 | |
3.0.1-pre | 1,799 | 8/8/2021 | |
3.0.0 | 2,157 | 8/24/2021 | |
3.0.0-pre | 499 | 8/5/2021 | |
2.4.9 | 2,161 | 7/18/2021 | |
2.4.8 | 1,918 | 7/17/2021 | |
2.4.7 | 1,051 | 7/15/2021 | |
2.4.6 | 1,530 | 7/11/2021 | |
2.4.5 | 2,605 | 7/7/2021 | |
2.4.4 | 999 | 7/6/2021 | |
2.4.3 | 1,003 | 7/5/2021 | |
2.4.2 | 1,023 | 7/4/2021 | |
2.4.1 | 1,060 | 7/3/2021 | |
2.4.0 | 1,030 | 7/3/2021 | |
2.3.9-pre | 450 | 6/1/2021 | |
2.3.9-dev | 436 | 7/2/2021 | |
2.3.8 | 1,519 | 5/30/2021 | |
2.3.7 | 1,067 | 5/30/2021 | |
2.3.6 | 1,060 | 5/30/2021 | |
2.3.5 | 1,022 | 5/29/2021 | |
2.3.5-dev | 425 | 5/29/2021 | |
2.3.4 | 981 | 5/28/2021 | |
2.3.3 | 905 | 5/28/2021 | |
2.3.1 | 969 | 5/27/2021 |