Skip to content

Quick start

By the end of this page your wisp answers /spin in your own server with a card. You need a Woosh account, a server you run (make one in the app if you have none), and for C# the .NET 8 SDK or later, or for TypeScript Node 22.18 or later.

Go to developer.woosh.no, sign in with your Woosh account and press Make a wisp.

  • Name: what people see on its lines, such as lucky. It is a username, so nobody else, person or wisp, can hold it.
  • Description: what it does, in a sentence or two. Admins read it before they add your wisp.
  • What it does: tick Post and Commands. That is all a wisp that answers commands needs.

Press Make the wisp. Its page shows its id and its secret. Copy the secret now and keep it somewhere safe: Woosh shows it once. Lost or leaked, reset it on the same page.

On your wisp’s page, copy its Install link and open it. Woosh shows what your wisp asks for in plain words. Pick your server and press Add to server. Your wisp is now a member there, with the Wisp mark beside its name, offline until it runs.

Make a project and add the library:

Terminal window
dotnet new console -n Lucky
cd Lucky
dotnet add package Woosh.Wisp

Add a file, Slots.cs. A command is a method with [Command]:

Slots.cs
using Woosh.Wisp;
public sealed class Slots
{
private static readonly string[] Reels = ["🍒", "🍋", "🔔", "💎"];
[Command("spin", "Spin the reels")]
public Task Spin(CommandRun run, [Option("Coins to bet")] int bet = 10)
{
string[] spin = [Pick(), Pick(), Pick()];
var won = spin.Distinct().Count() == 1;
var card = new Card(won ? "#22c55e" : "#f97316")
.Title($"{run.User} bets {bet}")
.Row(spin.Select(Cell.Emoji));
return run.AnswerAsync(won
? card.Text($"Jackpot! {bet * 10} coins.", tone: Tone.Good)
: card.Text("No win this time."));
}
private static string Pick() => Reels[Random.Shared.Next(Reels.Length)];
}

Replace everything in Program.cs with:

Program.cs
using Woosh.Wisp;
// Reads WISP_ID and WISP_SECRET from the environment.
await using var wisp = WispClient.FromEnvironment();
wisp.AddCommands(new Slots());
await wisp.RunAsync(); // until you press Ctrl+C

Give it the id and secret from step 1, and start it:

Terminal window
WISP_ID=<id> WISP_SECRET=<secret> dotnet run

In PowerShell:

Terminal window
$env:WISP_ID="<id>"; $env:WISP_SECRET="<secret>"; dotnet run

Your wisp shows as online in your server.

In a channel of your server, type /spin. The picker offers it, with its bet. Run it, and the card appears in the channel, with your name and “used /spin” above it. Your wisp told Woosh about /spin itself when it started, so the commands people see are always the ones your code answers.

Keep the secret out of your code and out of your repository. In a real project, keep it in configuration (Hosting your wisp).

© 2026 Woosh AS. All rights reserved.