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

from __future__ import annotations
from .v3_auth_accesstokendata import (
    V3AuthAccessTokenData,
    V3AuthAccessTokenDataTypedDict,
)
import pydantic
from squadcast_sdk.types import BaseModel
from squadcast_sdk.utils import FieldMetadata, HeaderMetadata
from typing_extensions import Annotated, TypedDict


AUTH_GET_ACCESS_TOKEN_OP_SERVERS = [
    # US Authentication
    "https://auth.squadcast.com",
    # EU Authentication
    "https://auth.eu.squadcast.com",
]


class AuthGetAccessTokenRequestTypedDict(TypedDict):
    x_refresh_token: str
    r"""(Required) Send your refresh token obtained from Squadcast web application."""


class AuthGetAccessTokenRequest(BaseModel):
    x_refresh_token: Annotated[
        str,
        pydantic.Field(alias="X-Refresh-Token"),
        FieldMetadata(header=HeaderMetadata(style="simple", explode=False)),
    ]
    r"""(Required) Send your refresh token obtained from Squadcast web application."""


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

    data: V3AuthAccessTokenDataTypedDict
    r"""Access token response returned by the OAuth endpoint."""


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

    data: V3AuthAccessTokenData
    r"""Access token response returned by the OAuth endpoint."""
