discordbot/test-bot.sh
ale 29db5a08c0
google trends
Signed-off-by: ale <ale@manalejandro.com>
2025-06-08 06:54:29 +02:00

73 lines
2.1 KiB
Bash
Executable File

#!/bin/bash
# Discord Bot Test Script
# This script demonstrates how to test the bot functionality
echo "🤖 Discord Multimedia Bot - Test Guide"
echo "======================================="
echo ""
echo "📋 Available Commands:"
echo ""
echo "1. /ping"
echo " - Tests if the bot is responsive"
echo " - Expected response: 'Pong!'"
echo ""
echo "2. /send channel:#general message:Hello World!"
echo " - Sends a message to the specified channel"
echo " - Make sure the bot has permission to send messages"
echo ""
echo "3. /search query:cats type:image count:2"
echo " - Searches for cat images"
echo " - Will display embedded images directly in Discord"
echo ""
echo "4. /search query:funny videos type:video count:3"
echo " - Searches for funny videos"
echo " - Will show video links with thumbnails"
echo ""
echo "5. /trends country:ES"
echo " - Shows current trending topics from Reddit's popular posts"
echo " - Grouped by subreddit with upvote metrics"
echo " - Direct links to Reddit discussions"
echo ""
echo "6. /download url:https://example.com/image.jpg title:Test Image"
echo " - Downloads and shares a multimedia file"
echo " - File must be under 8MB for Discord"
echo ""
echo "🔧 Bot Status:"
if pgrep -f "node index.js" > /dev/null; then
echo "✅ Bot is currently running"
echo "📊 Process ID: $(pgrep -f 'node index.js')"
else
echo "❌ Bot is not running"
echo "💡 Start with: node index.js"
fi
echo ""
echo "📁 Project Structure:"
ls -la /home/ale/projects/discord/discordbot/ | grep -E '\.(js|json|md|env)$'
echo ""
echo "🌐 Environment:"
if [ -f "/home/ale/projects/discord/discordbot/.env" ]; then
echo "✅ .env file exists"
else
echo "❌ .env file missing - create it with DISCORD_TOKEN=your_token"
fi
echo ""
echo "📦 Dependencies:"
if [ -f "/home/ale/projects/discord/discordbot/package.json" ]; then
echo "✅ package.json exists"
echo "📋 Installed packages:"
cd /home/ale/projects/discord/discordbot && npm list --depth=0 2>/dev/null | grep -E '(discord.js|dotenv|google-it|node-fetch)'
else
echo "❌ package.json missing"
fi