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

from typing import List, Optional
from typing_extensions import Literal

from pydantic import Field as FieldInfo

from ...._models import BaseModel

__all__ = ["Promotion"]


class Promotion(BaseModel):
    id: Optional[int] = None
    """Numeric identifier for a resource"""

    api_type: Optional[str] = FieldInfo(alias="_type", default=None)

    description: Optional[str] = None
    """Promotion description"""

    label: Optional[str] = None
    """Promotion label"""

    platforms: Optional[List[Literal["IOS", "ANDROID", "WEB", "API", "BACKSTAGE", "CMS"]]] = None
    """
    Contains the specific platforms valid for this promotion, it only uses
    (ios,android and web) The items are all lowercase.
    """

    title: Optional[str] = None
    """Promotion name"""

    voucher_code: Optional[str] = FieldInfo(alias="voucherCode", default=None)
    """Voucher code to be applied at checkout"""

    voucher_restrictions_message: Optional[str] = FieldInfo(alias="voucherRestrictionsMessage", default=None)
    """Message to indicate how voucherCode should be applied"""
