Getting started
This guide takes an approved Weeble project from an empty folder to its first running command.
Install Weeble Workspace
Install Weeble Workspace from the VS Code Marketplace. Its extension ID is Weeble.weeble.
VS Code normally updates extensions automatically. If an update is waiting, open Extensions, select Weeble Workspace, and choose Update or Reload.
Connect a deployment
Open an empty folder in VS Code.
Open the Command Palette.
Run Weeble: Sign In and approve the authorization in your browser.
Run Weeble: Select Deployment.
Choose the deployment you want to edit.
The extension downloads its source and creates local editor-support files. Selecting another deployment replaces only the files managed by the previous selection.
Write the first command
The Weeble SDK is available through the global discord and weeble namespaces.
const commands = discord.commands.create({ prefixes: ["!"] });
commands.prefix(
{
name: "ping",
description: "Check whether the bot is online",
},
async (message) => {
await message.reply("pong");
},
);
Deploy
Select the rocket button in the editor title bar or the Weeble view.
Enter a short release note.
Keep the Weeble output channel open while the build runs.
A successful deployment reports each stage:
Deployment started for main
Workspace changes · 1 added · 0 modified · 0 deleted
Building main…
Bundle completed in 1.2 s · 0 warnings
Publishing revision…
Published revision 1
Activating revision 1…
Deployment completed in 2.1 s
The output channel reports each deployment stage and the revision that became active.
Each successful publish creates an immutable revision. Activation makes that revision receive new Discord events.
Test and inspect
Run !ping in Discord. If the bot does not reply:
Open Debugging and check the runtime logs.
Confirm the deployment is active.
Check that the bot can read the channel and send messages.
For prefix commands, confirm the Message Content intent is enabled for the bot.
Continue with npm packages or deployments and revisions.