Drako Development
  • 🤖Our Bots
    • Drako Bot
      • Getting Started
      • Addon System
      • Twitch Announcements
      • Ticket System
        • Getting Started
        • Dashboard
          • Dashboard Addons
          • Nginx Configuration
        • Priority System
        • Working Hours
      • Reaction Roles
      • Music
      • Custom Commands
  • 👾Misc
    • MongoDB Setup
    • Premium Addons
      • Product Panel
      • Sticky Messages
      • Application System
  • 📰Terms and Conditions
    • Terms and Conditions
    • Privacy Policy
Powered by GitBook
On this page
  1. Our Bots
  2. Drako Bot
  3. Ticket System

Dashboard

Configuring the ticket dashboard

Overview The Drako Bot dashboard provides a powerful interface for managing your Discord bot. This guide will walk you through the setup and configuration process.

Prerequisites Before configuring the dashboard, ensure you have:

  • Node.js installed (v18.20.6)

  • Access to your Discord server with administrator permissions

Basic Configuration

Step 1: Discord Application Setup

  1. Go to the Discord Developer Portal

  2. Select your application (Bot)

  3. Navigate to the OAuth2 section

  4. Add a redirect URL:

    • For production: http://IP:PORT/api/auth/callback

    • For local development: http://localhost:PORT/api/auth/callback

    • Make sure to replace IP & PORT with actual values.

  5. Copy your Client ID and Client Secret from the OAuth2 page.

Step 2: Dashboard Configuration

In your config.yml file, configure the following settings:

Dashboard:
  Enabled: true
  ClientID: "YOUR_CLIENT_ID"
  ClientSecret: "YOUR_CLIENT_SECRET"
  Url: "http://IP:PORT" # Use http://localhost:PORT for local development
  Port: 7000
  Auth:
    JWTSecret: "YOUR_SECURE_JWT_SECRET"

Important: The Url should not include /api/auth/callback

Replace the placeholders with your actual values:

  • YOUR_CLIENT_ID: Your Discord application's Client ID

  • YOUR_CLIENT_SECRET: Your Discord application's Client Secret

  • YOUR_SECURE_JWT_SECRET: A secure random string for JWT token encryption

Step 3: Permissions Configuration

Configure role-based access control in your config.yml:

Permissions:
  Dashboard:
    Login: ["ROLE_ID_1", "ROLE_ID_2"] # Roles that can access the dashboard
    Usage: ["ROLE_ID_1"] # Roles that can view analytics
    Settings: ["ROLE_ID_1"] # Roles that can modify settings
    Embed: ["ROLE_ID_1"] # Roles that can use the embed builder
    Suggestions: ["ROLE_ID_1"] # Roles that can manage suggestions

Note: Login & pages won't be available if roles are not configured.


Advanced Configuration

Custom Navigation

You can customize the dashboard's navigation menu through the settings page:

  1. Access the dashboard settings

  2. Navigate to Navigation Settings

  3. Add custom links with:

    • Name: Display name

    • URL: Target URL

    • Icon: FontAwesome icon name

    • External: Toggle for external links

Appearance Settings

Customize the dashboard's appearance:

  1. Access dashboard settings

  2. Navigate to Dashboard Settings

  3. Configure:

    • Navigation Name: Brand name in the sidebar

    • Tab Name: Browser tab title

    • Favicon: Custom favicon URL


Security Considerations

JWT Secret

  • Use a strong, random string for JWTSecret

  • Minimum recommended length: 32 characters

  • Keep this secret secure and never share it


Troubleshooting

Common Issues

Cannot Access Dashboard

  • Verify the correct port is open

  • Check if the Discord application OAuth2 settings are correct

  • Ensure the user has the required role

Authentication Errors

  • Verify ClientID and ClientSecret are correct

Important: If you receive AuthError: Authentication failed your client ID or secret is incorrect.

  • Check if the redirect URL matches exactly

  • Ensure JWTSecret is properly set

  • Ensure that the URL has no leading /, such as http://localhost:3000/

Example: URLs should always be filled in as Url: "http://localhost:3000" and not "http://localhost:3000/"

Permission Issues

  • Verify role IDs are correct

  • Check if roles are properly assigned

  • Ensure the bot has necessary permissions

PreviousGetting StartedNextDashboard Addons

Last updated 2 months ago

🤖