mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
feat(voice): Add info about DAVE protocol dependencies and support (#11145)
* Add info about DAVE protocol dependencies and support Changes remade from https://github.com/discordjs/guide/pull/1630 due to project moving from that repo to this one. * remove explicit warning regarding optional dependency being optional Co-authored-by: Almeida <github@almeidx.dev> * style: format --------- Co-authored-by: Almeida <github@almeidx.dev> Co-authored-by: Jiralite <33201955+Jiralite@users.noreply.github.com>
This commit is contained in:
@@ -8,7 +8,11 @@ title: Installation
|
|||||||
|
|
||||||
### Barebones
|
### Barebones
|
||||||
|
|
||||||
To add voice functionality to your discord.js bot, you will need the `@discordjs/voice` package, as well as one of the encryption packages listed below. For example:
|
To add voice functionality to your discord.js bot, you will need the `@discordjs/voice` package. If your system does not support aes-256-gcm you also need one of the encryption packages listed below. For example:
|
||||||
|
|
||||||
|
<Callout>
|
||||||
|
You can verify aes-256-gcm support by running `require('node:crypto').getCiphers().includes('aes-256-gcm')`.
|
||||||
|
</Callout>
|
||||||
|
|
||||||
```sh tab="npm"
|
```sh tab="npm"
|
||||||
npm install @discordjs/voice
|
npm install @discordjs/voice
|
||||||
@@ -58,6 +62,15 @@ After this, you'll be able to play Ogg and WebM Opus files without any other dep
|
|||||||
- [`@noble/ciphers`](https://www.npmjs.com/package/@noble/ciphers)
|
- [`@noble/ciphers`](https://www.npmjs.com/package/@noble/ciphers)
|
||||||
- [`libsodium-wrappers`](https://www.npmjs.com/package/libsodium-wrappers)
|
- [`libsodium-wrappers`](https://www.npmjs.com/package/libsodium-wrappers)
|
||||||
|
|
||||||
|
#### DAVE Protocol Support
|
||||||
|
|
||||||
|
- [`@snazzah/davey`](https://www.npmjs.com/package/@snazzah/davey) - to enable end-to-end encryption with the DAVE protocol.
|
||||||
|
|
||||||
|
<Callout>
|
||||||
|
Some Discord clients already require the DAVE protocol for end-to-end encryption in voice chat. Ensure you have
|
||||||
|
`@snazzah/davey` installed to avoid compatibility issues.
|
||||||
|
</Callout>
|
||||||
|
|
||||||
<Callout>
|
<Callout>
|
||||||
If you are facing issues when installing these dependencies, make sure you ticked the box to install optional build
|
If you are facing issues when installing these dependencies, make sure you ticked the box to install optional build
|
||||||
tools when installing Node.js or try manually installing build tools and python: ```sh winget install "Visual Studio
|
tools when installing Node.js or try manually installing build tools and python: ```sh winget install "Visual Studio
|
||||||
@@ -91,6 +104,9 @@ Encryption Libraries
|
|||||||
FFmpeg
|
FFmpeg
|
||||||
- version: 4.2.4-1ubuntu0.1
|
- version: 4.2.4-1ubuntu0.1
|
||||||
- libopus: yes
|
- libopus: yes
|
||||||
|
|
||||||
|
DAVE Protocol
|
||||||
|
- @snazzah/davey: 0.1.6
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
*/
|
*/
|
||||||
```
|
```
|
||||||
@@ -104,3 +120,5 @@ FFmpeg
|
|||||||
- **FFmpeg**
|
- **FFmpeg**
|
||||||
- If you want to play audio from many different file types, you will need to have FFmpeg installed.
|
- If you want to play audio from many different file types, you will need to have FFmpeg installed.
|
||||||
- If `libopus` is enabled, you will be able to benefit from increased performance if real-time volume alteration is disabled.
|
- If `libopus` is enabled, you will be able to benefit from increased performance if real-time volume alteration is disabled.
|
||||||
|
- **DAVE Protocol**
|
||||||
|
- Required for enabling end-to-end encryption in voice channels.
|
||||||
|
|||||||
Reference in New Issue
Block a user