26 lines
527 B
Python
26 lines
527 B
Python
|
|
from pydantic_settings import BaseSettings
|
||
|
|
|
||
|
|
|
||
|
|
class Settings(BaseSettings):
|
||
|
|
model_config = {'env_prefix': 'FP_'}
|
||
|
|
|
||
|
|
# Freepik API
|
||
|
|
freepik_api_key: str
|
||
|
|
freepik_base_url: str = 'https://api.freepik.com'
|
||
|
|
|
||
|
|
# Paths
|
||
|
|
output_dir: str = '/data/outputs'
|
||
|
|
temp_dir: str = '/data/temp'
|
||
|
|
|
||
|
|
# Limits
|
||
|
|
max_upload_size_mb: int = 50
|
||
|
|
task_poll_interval_seconds: int = 5
|
||
|
|
task_poll_timeout_seconds: int = 600
|
||
|
|
auto_cleanup_hours: int = 24
|
||
|
|
|
||
|
|
# Webhook
|
||
|
|
webhook_secret: str = ''
|
||
|
|
|
||
|
|
|
||
|
|
settings = Settings()
|