An open API service indexing awesome lists of open source software.

https://github.com/tf2pickup-org/mumble-client

A simple mumble client for managing mumble servers
https://github.com/tf2pickup-org/mumble-client

bot mumble mumble-client mumble-server murmur nodejs

Last synced: about 1 month ago
JSON representation

A simple mumble client for managing mumble servers

Awesome Lists containing this project

README

        

mumble-client

A simple mumble client for managing mumble servers



Latest release


Test status


MIT license

### Installation

```bash
$ npm i @tf2pickup-org/mumble-client
```

### Examples

#### Connect to a mumble server

```typescript
import { Client } from '@tf2pickup-org/mumble-client';

const client = new Client({
host: 'mumble://example.com',
port: 64738,
username: 'me',
});
await client.connect();

if (client.isConnected) {
console.log(client.welcomeText);
console.log(`logged in as ${client.self.name}`);
}
```

#### List all channels

```typescript
import { type Channel } from '@tf2pickup-org/mumble-client';

function printChannel(channel: Channel, level = 0) {
if (channel.name) {
console.log(channel.name.padStart(channel.name.length + level));
}

for (const subChannel of channel.subChannels) {
printChannel(subChannel, level + 1);
}
}

printChannel(client.channels.root);
```