Examples

Practical snippets showing common tasks with teamspeak.js.

Manage Channels

This example shows how to create a permanent channel and then edit or delete it.

snippet-1.ts
const createdChannel = await query.channels.create({
  name: "New Channel",
  type: "permanent",
});
console.log("Created channel:", createdChannel);

await createdChannel.edit({ name: "Changed Name", topic: "Just chilling" });
await createdChannel.delete();