# generated by datamodel-codegen:
#   filename:  complex_proto3.proto
#   timestamp: 2019-07-26T00:00:00+00:00

from __future__ import annotations

from datetime import timedelta
from enum import Enum
from typing import Any

from pydantic import AwareDatetime, BaseModel, ConfigDict, Field, conint


class ExampleCommonStatus(Enum):
    STATUS_UNSPECIFIED = 'STATUS_UNSPECIFIED'
    """
    Default status for proto3 compatibility.
    """
    ACTIVE = 'ACTIVE'
    """
    Active resource.
    """
    SUSPENDED = 'SUSPENDED'
    """
    Suspended resource.
    """


class ExampleCommonAddress(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    line_1: str | None = ''
    city: str | None = ''


class ExamplePublicPublicToken(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    value: str | None = ''


class ExampleShopV1OrderRole(Enum):
    ROLE_UNSPECIFIED = 'ROLE_UNSPECIFIED'
    BUYER = 'BUYER'


class ExampleShopV1OrderLineItem(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    sku: str | None = ''
    quantity: int | None = 0


class ExampleShopV1Order(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    id: str | None = ''
    """
    Stable order identifier.
    """
    double_value: float | None = 0.0
    float_value: float | None = 0.0
    int32_value: int | None = 0
    int64_value: int | None = 0
    uint32_value: conint(ge=0, le=4294967295) | None = 0
    uint64_value: conint(ge=0, le=18446744073709551615) | None = 0
    sint32_value: int | None = 0
    sint64_value: int | None = 0
    fixed32_value: conint(ge=0, le=4294967295) | None = 0
    fixed64_value: conint(ge=0, le=18446744073709551615) | None = 0
    sfixed32_value: int | None = 0
    sfixed64_value: int | None = 0
    active: bool | None = False
    payload: bytes | None = b''
    tags: list[str] | None = []
    items: dict[str, ExampleShopV1OrderLineItem] | None = Field(
        {}, validate_default=True
    )
    previous_items: list[ExampleShopV1OrderLineItem] | None = Field(
        [], validate_default=True
    )
    shipping_address: ExampleCommonAddress | None = None
    status: ExampleCommonStatus | None = 'STATUS_UNSPECIFIED'
    created_at: AwareDatetime | None = None
    ttl: timedelta | None = None
    metadata: dict[str, Any] | None = None
    arbitrary: bool | float | str | dict[str, Any] | list[Any] | None = None
    values: list[Any] | None = None
    attachment: dict[str, Any] | None = None
    update_mask: str | None = None
    optional_note: str | None = None
    public_token: ExamplePublicPublicToken | None = None
    roles: list[ExampleShopV1OrderRole] | None = []
    email: str | None = None
    """
    oneof: contact
    """
    phone: str | None = None
    """
    oneof: contact
    """


class ExampleShopV1GetOrderRequest(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    id: str | None = ''


class ExampleShopV1GetOrderResponse(BaseModel):
    model_config = ConfigDict(
        extra='forbid',
    )
    order: ExampleShopV1Order | None = None
