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

from __future__ import annotations

from typing import Literal

import pydantic
from typing_extensions import Annotated, TypedDict

from friendli.types import BaseModel

B64ImageItemFormat = Literal["url", "raw", "png", "jpeg", "jpg"]
r"""The format of the generated image. One of `url(default)`, `raw`, `png`, `jpeg`, and `jpg`."""


class B64ImageItemTypedDict(TypedDict):
    b64_json: bytes
    r"""The base64-encoded JSON of the generated image."""
    format_: B64ImageItemFormat
    r"""The format of the generated image. One of `url(default)`, `raw`, `png`, `jpeg`, and `jpg`."""
    seed: int
    r"""The seed used during image generation."""


class B64ImageItem(BaseModel):
    b64_json: bytes
    r"""The base64-encoded JSON of the generated image."""

    format_: Annotated[B64ImageItemFormat, pydantic.Field(alias="format")]
    r"""The format of the generated image. One of `url(default)`, `raw`, `png`, `jpeg`, and `jpg`."""

    seed: int
    r"""The seed used during image generation."""
