
Research
Security News
Malicious PyPI Package Exploits Deezer API for Coordinated Music Piracy
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
@moscowcity/shoukaku
Advanced tools
A stable and updated wrapper around Lavalink
The ShipGirl Project, feat Shoukaku; ⓒ Kancolle
✅ Stable
✅ Documented
✅ Updated
✅ Extendable
✅ ESM & CommonJS supported
✅ Very cute (Very Important)
Refer to /src/connectors for list of supported libraries + how to support other libraries
npm install shoukaku
npm install https://github.com/Deivu/Shoukaku.git#master
https://deivu.github.io/Shoukaku/
Initializing the library (Using Connector Discord.JS)
const { Client } = require('discord.js');
const { Shoukaku, Connectors } = require('shoukaku');
const Nodes = [{
name: 'Localhost',
url: 'localhost:6969',
auth: 'marin_kitagawa'
}];
const client = new Client();
const shoukaku = new Shoukaku(new Connectors.DiscordJS(client), Nodes);
// ALWAYS handle error, logging it will do
shoukaku.on('error', (_, error) => console.error(error));
client.login('token');
Searching and joining a channel (Async Function Implementation)
const node = shoukaku.getNode();
if (!node) return;
const result = await node.rest.resolve('scsearch:snowhalation');
if (!result?.tracks.length) return;
const metadata = result.tracks.shift();
const player = await node.joinChannel({
guildId: 'your_guild_id',
channelId: 'your_channel_id',
shardId: 0 // if unsharded it will always be zero (depending on your library implementation)
});
// player is created and ready, do your thing
Playing a track and changing a playback option (in this example, volume)
player
.playTrack({ track: metadata.track })
.setVolume(0.5);
Option | Type | Description |
---|---|---|
resume | boolean | Whether to resume a connection on disconnect to Lavalink (Server Side) (Note: DOES NOT RESUME WHEN THE LAVALINK SERVER DIES) |
resumeKey | string | Resume key for Lavalink |
resumeTimeout | number | Timeout before resuming a connection in seconds |
resumeByLibrary | boolean | Whether to resume the players by doing it in the library side (Client Side) (Note: TRIES TO RESUME REGARDLESS OF WHAT HAPPENED ON A LAVALINK SERVER) |
alwaysSendResumeKey | boolean | Disables the first time initialization tracking of nodes, and just sends the resume key always (Note: Useful for people who save their players to redis and wants to resume sessions even at first boot) |
reconnectTries | number | Number of times to try and reconnect to Lavalink before giving up |
reconnectInterval | number | Timeout before trying to reconnect in milliseconds |
restTimeout | number | Time to wait for a response from the Lavalink REST API before giving up in milliseconds |
moveOnDisconnect | boolean | Whether to move players to a different Lavalink node when a node disconnects |
userAgent | string | User Agent to use when making requests to Lavalink |
structures | Object{rest?, player?} | Custom structures for shoukaku to use |
Open a pr to add your plugin here
Name | Link | Description |
---|---|---|
..... | ........ | .......... |
Shoukaku has now official supports for plugins. However, implementing this is up to the developers that is interested on doing it
Shoukaku support modification on Rest.ts and Player.ts
To apply your plugin, put the extended classes on ShoukakuOptions.structures. Example below
const { Client } = require('discord.js');
const { Shoukaku, Rest, Connectors } = require('shoukaku');
class CustomRest extends Rest { }; // extended structure of your choice
const Nodes = [{
name: 'Localhost',
url: 'localhost:6969',
auth: 'marin_kitagawa'
}];
const ShoukakuOptions = { structures: { rest: CustomRest } } // pass the custom structure to Shoukaku
const client = new Client();
const shoukaku = new Shoukaku(new Connectors.DiscordJS(client), Nodes, ShoukakuOptions);
Support (#Development) | Lavalink
@Sāya#0113
FAQs
Forked Shoukaku module with player.info option and session dump & recovery
The npm package @moscowcity/shoukaku receives a total of 0 weekly downloads. As such, @moscowcity/shoukaku popularity was classified as not popular.
We found that @moscowcity/shoukaku demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.
Security News
Newly introduced telemetry in devenv 1.4 sparked a backlash over privacy concerns, leading to the removal of its AI-powered feature after strong community pushback.