A typed Lavalink client for modern music bots.

Strict typing, a clean architecture, and every layer replaceable. Nodes, players, queues, filters and storage, all documented down to the structure.

Node.js 22+ · Bun 1.3+ · Deno 2.5+

bot.tsTypeScript
import { createHoshimi, SearchSources } from 'hoshimi';​const manager = createHoshimi({  sendPayload,  defaultSearchSource: SearchSources.Spotify,  nodes: [    { host: 'localhost', port: 2333, password: 'youshallnotpass' },  ],});​const player = manager.createPlayer({ guildId, voiceId, textId });if (!player.connected) await player.connect();​const result = await player.search({  query: 'Lofi hip hop',  requester,});await player.queue.add(result.tracks[0]);await player.play();

What you get out of the box

Typed end to end
Strict TypeScript across the whole surface, with type guards where it counts. The public API reference is generated from the source, so it never drifts.
Nodes that recover
Session resumption keeps players alive through restarts and reconnects, without losing the queue or the position.
Autoplay built in
Native autoplay for YouTube and Spotify keeps the queue moving. No extra plugins to install or wire up.
Live, synced lyrics
Lyrics are a first-class feature, with time-synced updates you can show to listeners as the track plays.
REST and WebSocket
Both transports behind typed helpers, plus a granular event system that makes debugging a node straightforward.
Replace any layer
Swap nodes, players, queues and storage for your own structures. Validation stays on, so overrides can't break the rest.