"""PROSEC Schemas — aligned with SITAR OpenAPI ProsecResponse."""

from typing import Optional
from pydantic import BaseModel, ConfigDict, Field


class ProsecResponse(BaseModel):
    """PROSEC (Programa de Promoción Sectorial)."""

    FRACCION: Optional[str] = Field("", max_length=10)
    ARTICULO: Optional[str] = Field("", max_length=3)
    SECTOR: Optional[str] = Field("", max_length=6)
    TASATXT: Optional[str] = Field("", max_length=19)
    TASANUM: Optional[str] = Field(default="0")
    TIPOTASA: Optional[int] = Field(default=0)
    DOF: Optional[str] = Field("", max_length=8)
    OBSERVACION: Optional[str] = ""
    NICO: Optional[str] = Field("", max_length=2)
    SYSID: int

    model_config = ConfigDict(from_attributes=True)
