from typing import Optional, List
from api_validations.core_validations import BaseModelRegular
from api_validations.validations_request import (
    PydanticBaseModel,
)


class CheckEndpointAccess(BaseModelRegular):
    endpoint: str


class InsertEndpointAccess(PydanticBaseModel):
    duty_uu_id: str
    endpoint_restriction_list_uu_ids: list


class UpdateEndpointAccess(PydanticBaseModel):
    endpoint_restriction_uu_id: Optional[str] = None
    deleted: Optional[bool] = None
    active: Optional[bool] = None
    is_confirmed: Optional[bool] = None


class UpdateEndpointAccessList(PydanticBaseModel):
    endpoint_restriction_list: List[UpdateEndpointAccess]
