"""Pydantic schemas for env management endpoints.""" import uuid from pydantic import BaseModel, Field class EnvInspectRequest(BaseModel): """Request body for env inspect endpoint.""" tenant_id: uuid.UUID = Field(..., description="UUID of the tenant") path: str = Field( ..., min_length=1, description="Path to .env file (e.g., /opt/letsbe/env/chatwoot.env)" ) keys: list[str] | None = Field( None, description="Optional list of specific keys to inspect" ) class EnvUpdateRequest(BaseModel): """Request body for env update endpoint.""" tenant_id: uuid.UUID = Field(..., description="UUID of the tenant") path: str = Field( ..., min_length=1, description="Path to .env file (e.g., /opt/letsbe/env/chatwoot.env)" ) updates: dict[str, str] | None = Field( None, description="Key-value pairs to set or update" ) remove_keys: list[str] | None = Field( None, description="Keys to remove from the env file" )