DocsClientsConnect a board

Connect a board

Every board joins WBSKT the same way. It starts up with a name and a policy's PIN, then shows up in your console.

1. Copy a policy PIN

A policy is a group of clients (boards, scripts or apps) that share one PIN, like greenhouse or workshop. In the console, open Policies, pick one or create one, and choose Copy PIN.

K7PX…HT4R Copy

Anyone with the PIN can add clients to that policy, so keep it to yourself. If it ever leaks, choose Rotate PIN and the old one stops working.

2. Add a few lines to your code

Give your board a name you'll recognise and paste in the PIN. Start Wi‑Fi as usual and the library connects to WBSKT for you.

#include <WiFi.h>
#include <Wbskt.h>

WbsktClient wbskt("greenhouse-sensor", "your-policy-pin");

void setup() {
  WiFi.begin("home-wifi", "wifi-password");
  wbskt.begin();
}

void loop() {
  wbskt.loop();
}
using Wbskt;

await using var wbskt = new WbsktClient("greenhouse-sensor", "your-policy-pin");
await wbskt.StartAsync();
from wbskt import WbsktClient

client = WbsktClient("greenhouse-sensor", policy_pin="your-policy-pin")
client.run_forever()
In betaThe ESP32, .NET and Python libraries are all in beta. Compare the libraries

Each board needs its own name. Use the same PIN for every board in the policy.

3. Approve it

Open Clients in the console. Your board appears under its policy within a few seconds.

greenhouse-sensor
Pending
Approve

If the policy asks for approval, the board waits as Pending until you choose Approve. Policies that don't ask let new boards straight in.

Staying connected

The library reconnects by itself after a Wi‑Fi drop or a power cut. While it's offline, messages wait on the board and go out in order once it's back, each marked with the time it was made.

TipSet the policy to ask for approval while you're trying things out, so a typo in a name doesn't add a stray board.