Documentation Index
Fetch the complete documentation index at: https://mintlify.com/xyrapanel/panel/llms.txt
Use this file to discover all available pages before exploring further.
Overview
XyraPanel implements comprehensive rate limiting to protect the API from abuse and ensure fair resource allocation. Rate limits are enforced at both the global and per-endpoint levels.Rate Limit Configuration
Rate limiting is configured innuxt.config.ts and can be customized via environment variables.
Global Rate Limits
By default, all API endpoints have a global rate limit:.env.example
Rate Limit Drivers
XyraPanel supports two rate limit storage drivers:Redis (Recommended for Production)
- Distributed rate limiting across multiple instances
- Persistent storage
- Better performance at scale
LRU Cache (Development)
- No external dependencies
- Simple setup for development
- In-memory storage
Per-Endpoint Rate Limits
Specific endpoints have custom rate limits configured innuxt.config.ts:
Authentication Endpoints
| Endpoint | Limit | Interval | Notes |
|---|---|---|---|
/api/auth/** | 45 requests | 5 minutes | General auth operations |
/api/auth/sign-in/** | 5 requests | 10 minutes | Login attempts |
/api/auth/forget-password | 5 requests | 15 minutes | Password reset requests |
/api/auth/reset-password | 8 requests | 15 minutes | Password reset confirmations |
/api/auth/password/request | 5 requests | 15 minutes | New password request flow |
/api/auth/password/reset | 8 requests | 15 minutes | Password reset flow |
Account Management
| Endpoint | Limit | Interval | Notes |
|---|---|---|---|
/api/user/2fa/** | 8 requests | 5 minutes | Two-factor authentication |
/api/account/password/** | 8 requests | 5 minutes | Password changes |
/api/account/email | 8 requests | 5 minutes | Email updates |
/api/account/sessions/** | 15 requests | 5 minutes | Session management |
/api/account/api-keys/** | 20 requests | 5 minutes | API key management |
Server & Admin API
| Endpoint | Limit | Interval | Notes |
|---|---|---|---|
/api/admin/** | 300 requests | 1 minute | Admin operations |
/api/wings/** | 300 requests | 1 minute | Wings node communication |
/api/servers/** | 300 requests | 1 minute | Server management |
/api/client/** | 300 requests | 1 minute | Client API operations |
Rate Limit Headers
When rate limiting is enabled (headers: true), XyraPanel includes rate limit information in response headers:
Header Descriptions
X-RateLimit-Limit- Maximum number of requests allowed in the intervalX-RateLimit-Remaining- Number of requests remaining in the current intervalX-RateLimit-Reset- Unix timestamp when the rate limit resets
Rate Limit Exceeded Response
When you exceed the rate limit, you’ll receive a429 Too Many Requests error:
Example: Checking Rate Limits
Handling Rate Limits in Your Application
Respect Rate Limit Headers
Implement Exponential Backoff
Production Configuration
For production deployments, configure Redis-based rate limiting:nuxt.config.ts
Rate Limit Customization
You can customize rate limits by modifyingnuxt.config.ts:
Better Auth Rate Limiting
Better Auth provides additional rate limiting for authentication operations:server/utils/auth.ts
Monitoring Rate Limits
XyraPanel includes scheduled tasks to maintain rate limit data:Best Practices
Disabling Rate Limits (Development Only)
In development, rate limiting can be disabled:nuxt.config.ts