# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from typing import List, Optional

from pydantic import Field as FieldInfo

from ...._models import BaseModel
from .pyos_hold_seat import PyosHoldSeat
from .price_type_selection import PriceTypeSelection
from .customers.ticket_type import TicketType

__all__ = ["PostHoldInputBody"]


class PostHoldInputBody(BaseModel):
    agent_payment_reference: Optional[str] = FieldInfo(alias="agentPaymentReference", default=None)
    """
    A unique string to identify the booking within a payment on-account retailer's
    internal system
    """

    apply_rewards_credit: Optional[bool] = FieldInfo(alias="applyRewardsCredit", default=None)

    hold_type: Optional[TicketType] = FieldInfo(alias="holdType", default=None)
    """Type of the tickets (Lottery, Rush and Regular tickets)"""

    num_tickets: Optional[int] = FieldInfo(alias="numTickets", default=None)

    provider: Optional[int] = None
    """Numeric identifier for a resource"""

    provider_params: Optional[str] = FieldInfo(alias="providerParams", default=None)
    """
    Some server information necessary to hold seats. This is generally a stringified
    json blob.
    """

    seats: Optional[List[PyosHoldSeat]] = None
    """The list of seats to be held for the customer."""

    section: Optional[int] = None
    """Numeric identifier for a resource"""

    should_override_ticket_protection_plan: Optional[bool] = FieldInfo(
        alias="shouldOverrideTicketProtectionPlan", default=None
    )
    """
    If true, the hold will not be linked to the show's/rules ticketProtectionPlan
    but the configured alternative
    """

    showtime: Optional[int] = None
    """Numeric identifier for a resource"""

    tickets_by_price_type: Optional[List[PriceTypeSelection]] = FieldInfo(alias="ticketsByPriceType", default=None)

    use_unified_checkout: Optional[bool] = FieldInfo(alias="useUnifiedCheckout", default=None)
