Radarcord.NET
1.0.1
dotnet add package Radarcord.NET --version 1.0.1
NuGet\Install-Package Radarcord.NET -Version 1.0.1
<PackageReference Include="Radarcord.NET" Version="1.0.1" />
paket add Radarcord.NET --version 1.0.1
#r "nuget: Radarcord.NET, 1.0.1"
// Install Radarcord.NET as a Cake Addin
#addin nuget:?package=Radarcord.NET&version=1.0.1
// Install Radarcord.NET as a Cake Tool
#tool nuget:?package=Radarcord.NET&version=1.0.1
Radarcord.NET
The best way to interact with the Radarcord API with DSharpPlus and .NET!
Note
This package is used with DSharpPlus, not Discord.Net, if you want an integration with that, I'll be publishing one soon.
Compatibility
This package only supports .NET 7 at this point in time.
Please note that this package is only compatible with the specified version, and other versions of .NET may not work/have issues.
Features
- Easy to use, less pressure on working with HTTP.
- Autoposting support, keep getting your stats!
- Webhook support soon!
- Constantly maintained to keep up with the thriving .NET ecosystem!
Installation
Installation is super easy, just run the following command:
Package Manager Console (Visual Studio)
Install-Package Radarcord.NET
.NET CLI
dotnet add package Radarcord.NET
Basic Usage
using DSharpPlus;
using DSharpPlus.EventArgs;
using Radarcord;
namespace MyBot
{
public class Program
{
private RadarcordClient? radar;
public static async Task Main()
{
var program = new Program();
await program.StartBot();
}
private async Task StartBot()
{
var discord = new DiscordClient(new DiscordConfiguration()
{
Token = "YOUR_TOKEN_HERE",
TokenType = TokenType.Bot,
Intents = DiscordIntents.AllUnprivileged
});
radar = new RadarcordClient(discord, "YOUR_RADARCORD_API_TOKEN_HERE");
discord.Ready += OnClientReady;
await discord.ConnectAsync();
// Keep the program running until the user presses the keyboard interrupt keybind.
await Task.Delay(-1);
}
private Task OnClientReady(DiscordClient sender, ReadyEventArgs args)
{
Console.WriteLine("The client is ready!");
if (radar is null) return Task.CompletedTask;
// Post bot stats to Radarcord
radar.PostStatsAsync();
return Task.CompletedTask;
}
}
}
Documentation
Documentation will be coming pretty soon.
Copyright
Copyright (c) 2023 - present Yoshiboi18303.
Licensed under the MIT License
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net7.0 is compatible. 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. |
-
net7.0
- DSharpPlus (>= 4.4.2)
- Newtonsoft.Json (>= 13.0.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Fixed post bug.
Added extra XML comments.