# This file was auto-generated by Fern from our API Definition.

from ..core.unchecked_base_model import UncheckedBaseModel
import typing
from .role9e7enum import Role9E7Enum
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2


class ProjectRole(UncheckedBaseModel):
    id: typing.Optional[int] = None
    project: int
    role: Role9E7Enum = pydantic.Field()
    """
    User role in project
    
    * `OW` - Owner
    * `AD` - Administrator
    * `MA` - Manager
    * `RE` - Reviewer
    * `AN` - Annotator
    * `DI` - Deactivated
    * `NO` - Not Activated
    """

    user: int

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True)  # type: ignore # Pydantic v2
    else:

        class Config:
            frozen = True
            smart_union = True
            extra = pydantic.Extra.allow
