Overview
The Kuest admin panel provides comprehensive tools for managing your prediction market platform. Access it at/admin (requires admin wallet authorization).
Admin Dashboard Structure
Sidebar Navigation
The admin sidebar provides access to all management sections:- General Settings: Platform identity and integrations
- Theme Settings: Visual customization
- Locales: Multi-language configuration
- Affiliate Program: Referral system management
- Market Context: AI-powered market insights
- Users: User management and statistics
- Events: Market visibility and sync control
- Categories: Tag and category management
- Create Event: Market creation interface
Admin Features
General Settings
Configure core platform settings at/admin (general settings page).
Brand Identity
Company Logo
Upload your platform logo:Supported formats:
- SVG (recommended, scalable)
- PNG, JPG, WebP (raster images)
image: Use uploaded raster imagesvg: Use SVG code (stored in database)
Company Name & Description
Set your platform identity:
- Company Name: Displayed in headers, wallet dialogs (max 80 chars)
- Company Description: Used in metadata, SEO (max 180 chars)
Community and Analytics
Google Analytics
Google Analytics
Track platform usage with Google Analytics 4:The platform automatically initializes GA4 when configured.
Discord Community
Discord Community
Link to your Discord server:Displayed in navigation and footer.
Support Link
Support Link
Configure support channel:Used in help sections and error pages.
OpenRouter Integration
Configure AI-powered features:- AI-generated resolution rules
- Automatic event translations
- Market context generation
- Content validation
Get API Key
Generate an API key at openrouter.ai/settings/keys
Configure Key
Enter your API key in the General Settings form. The platform never displays the full key after saving (shows
••••••••••••••••).Select Model
Choose your preferred model:
- Let OpenRouter decide: Automatic selection (default)
- Specific model: Choose from available models
perplexity/sonar) for best market context generation.LI.FI Integration
Configure cross-chain swap and bridge functionality:- Without API key: 200 requests per 2 hours
- With API key: 200 requests per minute (rolling 2-hour window)
Market and Fee Settings
Fee Recipient Wallet
Fee Recipient Wallet
Set the Polygon wallet address to receive transaction fees:This address receives platform fees from market trades.
Allowed Market Creators
Allowed Market Creators
Configure which wallet addresses can create markets:Important: Markets from these addresses only appear on your fork. Leave empty to show only main Kuest markets.
User Management
Manage platform users at/admin/users.
User Table
View and filter users:- Search by address or username
- Filter by admin status
- Sort by registration date, volume, trades
- View user details
User Statistics
The table displays:- Total registered users
- Active traders (users with trades)
- Total trading volume
- Admin user count
Event Management
Control market visibility and sync settings at/admin/events.
Event Table Features
Visibility Control
Show or hide events from the platform:Hidden events are not visible to users but remain in the database.
Sync Settings
Configure automatic event syncing:
Sports Finalization
Mark sports events as final:Prevents further updates to sports market scores.
Livestream URL
Add livestream links to events:Displayed on event pages for user engagement.
Auto-Deploy New Events
Toggle automatic deployment of synced events:Event Filters
Filter by:- Main category (Politics, Sports, Crypto, etc.)
- Status (active, resolved, archived, draft)
- Visibility (hidden/visible)
- Date range
- Event title
- Event slug
- Market questions
Category Management
Manage tags and categories at/admin/categories.
Category Operations
View Categories
The table displays:
- Category name and slug
- Associated main category
- Event count
- Creation date
Main Categories
Main categories organize events into broad topics:GET /admin/api/main-tags
Theme Settings
Customize platform appearance at/admin/theme.
Customization Options:
- Color schemes
- Typography
- Layout spacing
- Component styling
- Dark/light mode defaults
Locale Configuration
Manage supported languages at/admin/locales.
Features:
- Enable/disable languages
- Set default locale
- Configure locale-specific settings
- Manage translations
Affiliate Program
Configure referral system at/admin/affiliate.
Settings:
- Commission rates
- Payout thresholds
- Referral tracking
- Affiliate dashboard access
Market Context Settings
Configure AI-powered market insights at/admin/market-context.
- Market background information
- Historical data
- Related events
- AI-generated insights
Admin API Endpoints
The admin panel uses dedicated API routes:Data Tables
Admin tables use a consistent pattern:- Sortable columns
- Searchable fields
- Filterable values
- Pagination controls
- Bulk actions
- Export capabilities
Server Actions
Admin operations use Next.js server actions:- Authenticate request
- Validate input
- Perform database operation
- Invalidate relevant caches
- Return result
Security and Authorization
Admin Access Control
Admin access is controlled via environment variable:Route Protection
All admin routes are protected:Best Practices
Regular Backups
Back up your database regularly, especially before bulk operations.
Test Changes
Test admin actions on development/staging before production.
Monitor Actions
Review admin action logs in Sentry or your monitoring tool.
Limit Admin Access
Only add trusted wallet addresses to
ADMIN_WALLETS.Troubleshooting
Cannot Access Admin Panel
Issue:/admin redirects to home page.
Solution:
- Verify your wallet address is in
ADMIN_WALLETSenvironment variable - Ensure you’re connected with the correct wallet
- Check that your user record has
is_admin = truein the database - Clear browser cache and reconnect wallet
Settings Not Saving
Issue: Form submits but changes don’t persist. Solution:- Check browser console for errors
- Verify database connection
- Check server action logs
- Ensure proper permissions on storage (S3/Supabase)
- Review Sentry error logs
Slow Table Loading
Issue: Admin tables take a long time to load. Solution:- Add database indexes on frequently queried columns
- Implement pagination (already built-in)
- Use table filters to reduce result size
- Cache frequently accessed data
- Optimize database queries
Image Upload Fails
Issue: Logo or icon upload returns an error. Solution:- Check file size (recommended: < 2MB)
- Verify file format (PNG, JPG, WebP, SVG)
- Ensure S3/Supabase credentials are correct
- Check storage bucket permissions
- Verify
S3_PUBLIC_URLorSUPABASE_URLis accessible
Related Resources
Market Creation
Create and manage prediction markets
Monitoring
Track platform health and performance
Environment Config
Configure environment variables
Database Schema
Understand the database structure