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

import typing

import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .env_var_response import EnvVarResponse


class EnvVarListResponse(UniversalBaseModel):
    """
    Response for listing environment variables.
    """

    env_vars: typing.List[EnvVarResponse] = pydantic.Field()
    """
    List of environment variables
    """

    state: typing.Optional[str] = pydantic.Field(default=None)
    """
    Indicates this is pending state (vs deployed). Pending = what will be used on next deploy. Deployed = what's currently running (from Version.secrets_snapshot).
    """

    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
