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

from __future__ import annotations
from .v3_analytics_analyticsresponse import (
    V3AnalyticsAnalyticsResponse,
    V3AnalyticsAnalyticsResponseTypedDict,
)
import pydantic
from squadcast_sdk.types import BaseModel
from squadcast_sdk.utils import FieldMetadata, QueryParamMetadata
from typing import Optional
from typing_extensions import Annotated, NotRequired, TypedDict


class AnalyticsGetTeamAnalyticsRequestTypedDict(TypedDict):
    owner_id: str
    from_: str
    to: str
    user_id: NotRequired[str]
    service_id: NotRequired[str]


class AnalyticsGetTeamAnalyticsRequest(BaseModel):
    owner_id: Annotated[
        str, FieldMetadata(query=QueryParamMetadata(style="form", explode=False))
    ]

    from_: Annotated[
        str,
        pydantic.Field(alias="from"),
        FieldMetadata(query=QueryParamMetadata(style="form", explode=False)),
    ]

    to: Annotated[
        str, FieldMetadata(query=QueryParamMetadata(style="form", explode=False))
    ]

    user_id: Annotated[
        Optional[str],
        FieldMetadata(query=QueryParamMetadata(style="form", explode=False)),
    ] = None

    service_id: Annotated[
        Optional[str],
        FieldMetadata(query=QueryParamMetadata(style="form", explode=False)),
    ] = None


class AnalyticsGetTeamAnalyticsResponseTypedDict(TypedDict):
    r"""The request has succeeded."""

    data: V3AnalyticsAnalyticsResponseTypedDict


class AnalyticsGetTeamAnalyticsResponse(BaseModel):
    r"""The request has succeeded."""

    data: V3AnalyticsAnalyticsResponse
