npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

vcyaudio

v1.0.1

Published

High-performance Universal Audio Engine for Discord Bots

Readme

🔊 vcyaudio

High-Performance Universal Audio Extractor Engine for Node.js

Powered by Golang | Zero-FFmpeg Transcoding | Optimized for Discord Bots


📖 Overview

vcyaudio is a high-efficiency audio extraction module utilizing a bridge architecture between Golang and Node.js. Specifically designed for Discord music bots that require high speed, low CPU usage, and native Opus support without the need for external FFmpeg transcoding.


🚀 Key Features

| Feature | Description | |---------|-------------| | ⚡ Golang Core | Utilizes a high-speed Go execution binary to handle heavy scraping and URL decryption | | 🔇 Zero-FFmpeg | Specifically extracts WebM Opus format (Google itag 251). Audio can be played natively in Discord without re-encoding | | 📡 Universal Router | Supports YouTube direct links & search queries, Spotify & TIDAL with metadata fallback | | 📜 Smart Playlist | YouTube playlist extraction (up to 50 tracks) with "Lazy Loading" schema | | 📉 Low Resource | Zero disk usage (no temporary files) and minimal RAM footprint on your VPS |


🏗 System Architecture

The module operates by spawning a lightweight Go binary in the background. Node.js sends instructions via CLI arguments, and Go returns a clean JSON object through Standard Output (stdout).

┌─────────────┐     CLI Args      ┌─────────────┐
│  Node.js    │ ────────────────► │  Go Binary  │
│  (vcyaudio) │                   │  (Extractor)│
└─────────────┘                   └─────────────┘
       ▲                                  │
       │         JSON (stdout)            │
       └──────────────────────────────────┘

📦 Installation

Prerequisites

  • Node.js (v14 or higher)
  • Go 1.19+ (for building binaries)

Setup

# Navigate to vcyaudio directory
cd vcyaudio

# Install dependencies
npm install

# Build binaries for Windows & Linux
npm run build:all

# Link the module globally
npm link

Connect to Your Bot

# Navigate to your bot project
cd ../your-bot-folder

# Link vcyaudio to your project
npm link vcyaudio

📖 Usage Guide

1. Single Track Extraction / Text Search

Ideal for commands like !play <title/link>:

const vcyaudio = require('vcyaudio');
const { createAudioResource, StreamType } = require('@discordjs/voice');

async function playMusic(urlOrText) {
    const result = await vcyaudio.getStream(urlOrText);

    if (result.status === 'success') {
        // Play directly WITHOUT FFmpeg
        const resource = createAudioResource(result.stream_url, {
            inputType: StreamType.WebmOpus,
        });
        
        console.log(`Now playing: ${result.title}`);
        return resource;
    }
}

2. Playlist Handling (Lazy Loading)

Use this to prevent the bot from hanging when processing hundreds of tracks at once:

const result = await vcyaudio.getStream("https://youtube.com/playlist?list=...");

if (result.type === 'playlist') {
    console.log(`Playlist Name: ${result.playlist_name}`);
    
    // Iterate through track titles to add to your queue
    result.tracks.forEach(track => {
        const query = track.query; // e.g., "Song Title - Artist"
        myBotQueue.push(query); 
    });
}

🛠 JSON Response Schema

Every request returns an object with the following structure:

| Key | Type | Description | |-----|------|-------------| | status | string | "success" or "error" | | type | string | "track" or "playlist" | | title | string | Song title or Playlist name | | stream_url | string | Direct audio link (only for type: track) | | tracks | array | List of song objects (only for type: playlist) | | message | string | Error message if the status fails |


🖥 OS Support

vcyaudio automatically detects the operating system and runs the appropriate binary located in the bin/ folder:

| OS | Binary | Architecture | |----|--------|--------------| | Windows | vcyaudio-win.exe | amd64 | | Linux | vcyaudio-linux | amd64 |


🛠 Maintenance

If YouTube updates its system and extraction fails, simply update the Go dependencies and recompile:

# Update Go dependencies
go get -u github.com/kkdai/youtube/v2

# Rebuild all binaries
npm run build:all

📂 Project Structure

vcyaudio/
├── bin/                    # Compiled Go binaries
│   ├── vcyaudio-linux
│   └── vcyaudio-win.exe
├── src/                    # Go source code
│   ├── main.go
│   ├── go.mod
│   └── go.sum
├── index.js                # Node.js entry point
├── package.json
└── README.md

⚠️ Important Notes

  • This module is designed for educational and personal use
  • Ensure compliance with YouTube's Terms of Service when using this module
  • No temporary files are created - all processing is done in-memory
  • Requires stable internet connection for audio stream extraction

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.


📄 License

This project is proprietary software developed internally by vcyanh.


👤 Author

Developed with ❤️ by Cejii (vcyanh)


📞 Support

For issues, questions, or suggestions, please open an issue on the GitHub repository.