Choose your setup
Decide whether to run Remedia inside your Node.js process or on a separate server, and which packages to install.
Choose where audio will be processed, then install the packages for that setup. Both modes use your existing Discord Gateway connection and accept media selected by your application.
Embedded or remote
| Embedded | Remote | |
|---|---|---|
| Where audio is processed | Inside your Node.js process | On a remedia-server process, possibly another machine |
| You install | @remedia/node (or @remedia/client with an embedded node) | remedia-server on the audio host, @remedia/client in your bot |
| FFmpeg 9 needed on | The machine running your bot | The machine running remedia-server |
| Good for | One bot process, simplest setup, local development | Several bots or nodes, keeping audio load off the bot process |
| Start with | Embedded quickstart | Remote quickstart |
A bot that only talks to remote servers needs no FFmpeg and no native addon. FFmpeg is required only where audio is actually decoded.
Which packages do I need?
| Package | Install it when |
|---|---|
@remedia/node | You embed the engine and want the lowest-level Node.js API. |
@remedia/client | You want one API for embedded nodes, remote nodes, or both. It is the usual choice for remote servers and for bots that may move between modes. |
remedia-server | You run a standalone audio server. It is a binary from the installer, not an npm package. |
@remedia/plugin-host | You build your own plugin service that produces audio or answers application-defined operations. Most bots do not need this. |
You can mix them. A RemediaClient can hold an embedded node and several remote nodes, and keeps
each Discord guild on the node it was first assigned to.
Not sure?
Start with an embedded node for one bot process. The client SDK can later add remote nodes to the same node list.
Application responsibilities
- Select authorized media URLs, files, or plugin operations. Provider search and extraction belong to your application.
- Authenticate the Discord Gateway client, send Gateway payloads, and forward incoming dispatches.
- Maintain the queue and decide how to restore it after a process restart.
The remote server exposes Remedia's own RPC protocol. Lavalink clients cannot connect directly.