"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""

from __future__ import annotations
import pydantic
from squadcast_sdk.types import BaseModel
from typing import Literal, Optional
from typing_extensions import Annotated, NotRequired, TypedDict


V4StatusPagesNewStatusPageComponentType = Literal[
    "component",
    "group",
]


class V4StatusPagesNewStatusPageComponentTypedDict(TypedDict):
    type: V4StatusPagesNewStatusPageComponentType
    name: str
    allow_subscription: bool
    description: NotRequired[str]
    service_id: NotRequired[str]


class V4StatusPagesNewStatusPageComponent(BaseModel):
    type: V4StatusPagesNewStatusPageComponentType

    name: str

    allow_subscription: Annotated[bool, pydantic.Field(alias="allowSubscription")]

    description: Optional[str] = None

    service_id: Annotated[Optional[str], pydantic.Field(alias="serviceID")] = None
