Automated Action d340d37ac9 Create Small Business Inventory Management System API
- Set up project structure with FastAPI and SQLite
- Create database models for inventory management
- Set up SQLAlchemy and Alembic for database migrations
- Create initial database migrations
- Implement CRUD operations for products, categories, suppliers
- Implement stock movement tracking and inventory management
- Add authentication and user management
- Add API endpoints for all entities
- Add health check endpoint
- Update README with project information and usage instructions
2025-05-23 11:56:20 +00:00

24 lines
628 B
Python

from pydantic_settings import BaseSettings
from pathlib import Path
class Settings(BaseSettings):
API_V1_STR: str = "/api/v1"
PROJECT_NAME: str = "Small Business Inventory Management System"
# Security
SECRET_KEY: str = "09d25e094faa6ca2556c818166b7a9563b93f7099f6f0f4caa6cf63b88e8d3e7"
ALGORITHM: str = "HS256"
ACCESS_TOKEN_EXPIRE_MINUTES: int = 30
# Database
DB_DIR: Path = Path("/app") / "storage" / "db"
class Config:
case_sensitive = True
settings = Settings()
# Create database directory if it doesn't exist
settings.DB_DIR.mkdir(parents=True, exist_ok=True)