Menu Setup
The menu system is the heart of BarStrad-Bot. This guide covers how to configure, customize, and manage your menu files.
Menu File Structure
BarStrad-Bot uses JSON files to store menu data:
src/data/menu-items.bg.json
- Bulgarian menusrc/data/menu-items.en.json
- English menu
Basic Menu Structure
Each menu file follows this structure:
[
{
"category": "Category Name",
"icon": "🍸",
"items": [
{
"name": "Item Name",
"price": "4.00 лв.",
"icon": "🍸"
}
]
}
]
Field Descriptions
Category Object
category
(string, required): Display name for the menu categoryicon
(string, required): Emoji icon for the categoryitems
(array, required): Array of menu items in this category
Item Object
name
(string, required): Display name for the menu itemprice
(string, required): Formatted price stringicon
(string, required): Emoji icon for the item
Example Menu Configurations
Bulgarian Menu Example
[
{
"category": "Шотове",
"icon": "🍸",
"items": [
{ "name": "Текила Jose Cuervo Silver 30мл", "price": "4.00 лв.", "icon": "🍸" },
{ "name": "Текила Jose Cuervo Gold 30мл", "price": "4.50 лв.", "icon": "🍸" },
{ "name": "Aftershock 30мл", "price": "4.00 лв.", "icon": "🍸" },
{ "name": "Jagermeister 30мл", "price": "4.00 лв.", "icon": "🍸" }
]
},
{
"category": "Джин",
"icon": "🍸",
"items": [
{ "name": "Tanqueray 50мл", "price": "6.00 лв.", "icon": "🍸" },
{ "name": "Bombay Sapphire 50мл", "price": "6.50 лв.", "icon": "🍸" },
{ "name": "Hendrick's 50мл", "price": "8.00 лв.", "icon": "🍸" }
]
}
]
English Menu Example
[
{
"category": "Shots",
"icon": "🥃",
"items": [
{ "name": "Tequila Jose Cuervo Silver 30ml", "price": "4.00 лв.", "icon": "🥃" },
{ "name": "Tequila Jose Cuervo Gold 30ml", "price": "4.50 лв.", "icon": "🥃" },
{ "name": "Aftershock 30ml", "price": "4.00 лв.", "icon": "🥃" },
{ "name": "Jagermeister 30ml", "price": "4.00 лв.", "icon": "🥃" }
]
},
{
"category": "Gin",
"icon": "🍸",
"items": [
{ "name": "Tanqueray 50ml", "price": "6.00 лв.", "icon": "🍸" },
{ "name": "Bombay Sapphire 50ml", "price": "6.50 лв.", "icon": "🍸" },
{ "name": "Hendrick's 50ml", "price": "8.00 лв.", "icon": "🍸" }
]
}
]
Menu Categories
Common Bar Categories
Here are typical categories for bars and their suggested icons:
Category (EN) | Category (BG) | Icon | Description |
---|---|---|---|
Shots | Шотове | 🥃 | Shot drinks |
Gin | Джин | 🍸 | Gin-based drinks |
Whisky | Уиски | 🥃 | Whisky varieties |
Vodka | Водка | 🍸 | Vodka drinks |
Rum | Ром | 🍹 | Rum-based drinks |
Cocktails | Коктейли | 🍹 | Mixed cocktails |
Beer | Бира | 🍺 | Beer selection |
Wine | Вино | 🍷 | Wine selection |
Non-Alcoholic | Безалкохолно | 🥤 | Soft drinks |
Restaurant Categories
For restaurants, consider these categories:
Category (EN) | Category (BG) | Icon | Description |
---|---|---|---|
Appetizers | Предястия | 🥗 | Starter dishes |
Main Courses | Основни ястия | 🍽️ | Main dishes |
Desserts | Десерти | 🍰 | Sweet treats |
Soups | Супи | 🍲 | Soup varieties |
Salads | Салати | 🥗 | Fresh salads |
Pizza | Пица | 🍕 | Pizza options |
Pasta | Паста | 🍝 | Pasta dishes |
Seafood | Морски деликатеси | 🐟 | Fish and seafood |
Item Naming Conventions
Best Practices
- Be Descriptive: Include key details like size, ingredients, or preparation method
- Include Size: Specify volume (ml, cl) or weight (g, kg) where relevant
- Brand Names: Include brand names for premium products
- Consistency: Use consistent formatting across all items
Good Examples
{ "name": "Tanqueray Gin 50ml", "price": "6.00 лв.", "icon": "🍸" }
{ "name": "Grilled Salmon with Lemon", "price": "25.00 лв.", "icon": "🐟" }
{ "name": "Cappuccino (Large)", "price": "4.50 лв.", "icon": "☕" }
Avoid These
{ "name": "Gin", "price": "6.00 лв.", "icon": "🍸" } // Too vague
{ "name": "Fish", "price": "25.00 лв.", "icon": "🐟" } // Not descriptive
{ "name": "Coffee", "price": "4.50 лв.", "icon": "☕" } // Missing size
Price Formatting
Currency and Format
The current examples use Bulgarian Lev (лв.) format:
"price": "4.00 лв."
For Other Currencies
You can adapt the format for your currency:
// USD
"price": "$4.00"
// EUR
"price": "4.00 €"
// GBP
"price": "£3.50"
// Turkish Lira
"price": "45.00 ₺"
Price Range Examples
// Standard pricing
"price": "5.00 лв."
// Premium pricing
"price": "12.50 лв."
// Budget pricing
"price": "2.50 лв."
// Market price (variable)
"price": "Market Price"
// Special offers
"price": "4.00 лв. (Special)"
Icon Selection
Emoji Guidelines
- Relevant: Choose icons that represent the item or category
- Consistent: Use similar styles within categories
- Clear: Ensure icons display well on all devices
- Professional: Avoid overly playful icons for serious establishments
Recommended Icons by Category
Alcoholic Drinks:
- 🍸 Cocktails, Gin, Martinis
- 🥃 Whisky, Shots, Spirits
- 🍹 Tropical drinks, Rum cocktails
- 🍺 Beer, Lager
- 🍷 Wine, Champagne
- 🥂 Sparkling drinks, Celebrations
Food Items:
- 🍽️ Main courses, Complete meals
- 🥗 Salads, Appetizers
- 🍲 Soups, Stews
- 🍕 Pizza
- 🍝 Pasta
- 🐟 Seafood, Fish
- 🥩 Meat dishes
- 🍰 Desserts
- ☕ Coffee, Hot drinks
Non-Alcoholic:
- 🥤 Soft drinks, Sodas
- 🧃 Juices
- 🥛 Milk-based drinks
- 🫖 Tea
- ☕ Coffee
Menu Validation
JSON Syntax Validation
Ensure your JSON is valid:
# Check JSON syntax
node -e "console.log(JSON.parse(require('fs').readFileSync('src/data/menu-items.bg.json', 'utf8')))"
Required Fields Validation
Each menu item must have:
category
(string)icon
(string)items
(array)
Each item must have:
name
(string)price
(string)icon
(string)
Common Validation Errors
- Missing Commas: JSON requires commas between objects and properties
- Trailing Commas: JSON doesn't allow trailing commas
- Quote Consistency: Use double quotes, not single quotes
- Escape Characters: Properly escape special characters
Menu Management Tips
Adding New Items
- Choose appropriate category or create a new one
- Follow naming conventions established in your menu
- Use consistent price formatting
- Select appropriate icon
- Test the changes with
!menu
command
Updating Prices
- Update both language files to maintain consistency
- Use find-and-replace for bulk price updates
- Test after updates to ensure proper display
Seasonal Menus
Consider creating seasonal variations:
# Backup current menu
cp src/data/menu-items.bg.json src/data/menu-items.bg.backup.json
# Create seasonal version
cp src/data/menu-items.bg.summer.json src/data/menu-items.bg.json
Menu Analytics
Track popular items by monitoring order patterns:
- Most frequently ordered items
- Peak ordering times
- Category popularity
- Customer preferences
Troubleshooting Menu Issues
Menu Not Loading
- Check JSON syntax using online JSON validators
- Verify file paths are correct
- Check file permissions (readable by the application)
- Review console logs for specific error messages
Items Not Displaying
- Verify required fields are present
- Check for special characters that might break parsing
- Ensure consistent structure across all categories
Order Numbers Wrong
The bot auto-numbers items sequentially. If numbering seems off:
- Check item order in the JSON file
- Verify no missing items between categories
- Restart the bot to reload menu data
Need help with environment setup? See Environment Variables or check out Discord Setup.