plan: Adjust rate limits based on feedback

Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-02-10 20:26:21 +00:00
parent 8634dc0265
commit 7480c70de4
3 changed files with 5 additions and 5 deletions
+3 -3
View File
@@ -58,9 +58,9 @@ RATE_LIMITING_ENABLED=true
RATE_LIMIT_DEFAULT=100/minute
# Rate limit for file upload endpoints
# Lower limit to prevent resource exhaustion from large file uploads
# Default: 20 uploads per minute per IP/user
RATE_LIMIT_UPLOAD=20/minute
# Allows faster uploads while still preventing abuse
# Default: 10 uploads per second per IP/user (600/minute)
RATE_LIMIT_UPLOAD=10/second
# Rate limit for document processing endpoints (OCR, metadata extraction)
# These operations are resource-intensive
+1 -1
View File
@@ -224,7 +224,7 @@ class Settings(BaseSettings):
description="Default rate limit for all endpoints (format: 'count/period', e.g., '100/minute', '1000/hour').",
)
rate_limit_upload: str = Field(
default="20/minute",
default="10/second",
description="Rate limit for file upload endpoints to prevent resource exhaustion.",
)
rate_limit_process: str = Field(
+1 -1
View File
@@ -121,7 +121,7 @@ Rate limits are specified in the format `count/period`, where:
| **Variable** | **Description** | **Default** | **Applies To** |
|------------------------|----------------------------------------------------------------------|------------------|-----------------------------------------|
| `RATE_LIMIT_DEFAULT` | Default rate limit for all API endpoints | `100/minute` | Most API endpoints |
| `RATE_LIMIT_UPLOAD` | Rate limit for file upload endpoints (prevents resource exhaustion) | `20/minute` | `/api/ui-upload` and similar |
| `RATE_LIMIT_UPLOAD` | Rate limit for file upload endpoints (prevents resource exhaustion) | `10/second` | `/api/ui-upload` and similar |
| `RATE_LIMIT_PROCESS` | Rate limit for processing endpoints (OCR, metadata extraction) | `30/minute` | `/api/process`, OCR endpoints |
| `RATE_LIMIT_AUTH` | Stricter rate limit for authentication (prevents brute force) | `10/minute` | Login, authentication endpoints |