Environments
Use Pydantic Settings(opens in new tab) to define project configuration as typed, validated Python. Extend Environments with the values your solution needs; they are loaded from .env.sample, .env, or process environment variables.
Example
pythonfrom pydantic import Fieldfrom longlink import Environmentsclass Env(Environments):"""Project-specific environment model."""REQUIRED: str = Field(description="Required value")OPTIONAL: str = Field(default="optional", description="Optional value")env = Env()print(env.REQUIRED)