# This file was auto-generated by Fern from our API Definition.

import typing

import pydantic
import typing_extensions
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from ...core.serialization import FieldMetadata


class StatisticsVendorQueryRecord(UniversalBaseModel):
    stat_x: typing_extensions.Annotated[
        str, FieldMetadata(alias="statX"), pydantic.Field(alias="statX", description="Statistical grouping identifier")
    ]
    active: int = pydantic.Field()
    """
    Number of active transactions
    """

    active_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="activeVolume"),
        pydantic.Field(alias="activeVolume", description="Volume of active transactions"),
    ]
    sent_to_approval: typing_extensions.Annotated[
        int,
        FieldMetadata(alias="sentToApproval"),
        pydantic.Field(alias="sentToApproval", description="Number of transactions sent to approval"),
    ]
    sent_to_approval_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="sentToApprovalVolume"),
        pydantic.Field(alias="sentToApprovalVolume", description="Volume of transactions sent to approval"),
    ]
    to_approval: typing_extensions.Annotated[
        int,
        FieldMetadata(alias="toApproval"),
        pydantic.Field(alias="toApproval", description="Number of transactions to approval"),
    ]
    to_approval_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="toApprovalVolume"),
        pydantic.Field(alias="toApprovalVolume", description="Volume of transactions to approval"),
    ]
    approved: int = pydantic.Field()
    """
    Number of approved transactions
    """

    approved_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="approvedVolume"),
        pydantic.Field(alias="approvedVolume", description="Volume of approved transactions"),
    ]
    disapproved: int = pydantic.Field()
    """
    Number of disapproved transactions
    """

    disapproved_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="disapprovedVolume"),
        pydantic.Field(alias="disapprovedVolume", description="Volume of disapproved transactions"),
    ]
    cancelled: int = pydantic.Field()
    """
    Number of cancelled transactions
    """

    cancelled_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="cancelledVolume"),
        pydantic.Field(alias="cancelledVolume", description="Volume of cancelled transactions"),
    ]
    in_transit: typing_extensions.Annotated[
        int,
        FieldMetadata(alias="inTransit"),
        pydantic.Field(alias="inTransit", description="Number of transactions in transit"),
    ]
    in_transit_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="inTransitVolume"),
        pydantic.Field(alias="inTransitVolume", description="Volume of transactions in transit"),
    ]
    paid: int = pydantic.Field()
    """
    Number of paid transactions
    """

    paid_volume: typing_extensions.Annotated[
        float,
        FieldMetadata(alias="paidVolume"),
        pydantic.Field(alias="paidVolume", description="Volume of paid transactions"),
    ]

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True)  # type: ignore # Pydantic v2
    else:

        class Config:
            frozen = True
            smart_union = True
            extra = pydantic.Extra.allow
