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

from __future__ import annotations

from typing import Literal

import pydantic
from pydantic.functional_validators import AfterValidator
from typing_extensions import Annotated, TypedDict

from friendli_core.types import BaseModel
from friendli_core.utils import validate_const

from .audiodata import AudioData, AudioDataTypedDict


class AudioContentTypedDict(TypedDict):
    audio_url: AudioDataTypedDict
    type: Literal["audio_url"]
    r"""The type of the message content."""


class AudioContent(BaseModel):
    audio_url: AudioData

    TYPE: Annotated[
        Annotated[Literal["audio_url"], AfterValidator(validate_const("audio_url"))],
        pydantic.Field(alias="type"),
    ] = "audio_url"
    r"""The type of the message content."""
