""" Options: Date: 2024-12-23 11:31:54 Version: 8.0 Tip: To override a DTO option, remove "#" prefix before updating BaseUrl: https://consumer-api.brovs.com #GlobalNamespace: ConsumerApi #AddServiceStackTypes: True #AddResponseStatus: False #AddImplicitVersion: #AddDescriptionAsComments: True IncludeTypes: ReferBusinessLinkUsedRequest.* #ExcludeTypes: #DefaultImports: datetime,decimal,marshmallow.fields:*,servicestack:*,typing:*,dataclasses:dataclass/field,dataclasses_json:dataclass_json/LetterCase/Undefined/config,enum:Enum/IntEnum #DataClass: #DataClassJson: """ import datetime import decimal from marshmallow.fields import * from servicestack import * from typing import * from dataclasses import dataclass, field from dataclasses_json import dataclass_json, LetterCase, Undefined, config from enum import Enum, IntEnum # module ConsumerApi @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class ReferBusinessUser: first_name: Optional[str] = None last_name: Optional[str] = None profile_photo_url: Optional[str] = None @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class ReferredPlace: id: int = 0 guid: Optional[str] = None name: Optional[str] = None logo_url: Optional[str] = None image_url: Optional[str] = None class ReferBusinessState(str, Enum): SIGN_IN_TO_SEE = 'SignInToSee' AVAILABLE = 'Available' CAN_NOT_REFER_YOURSELF = 'CanNotReferYourself' ALREADY_CLAIMED_BY_YOU = 'AlreadyClaimedByYou' ALREADY_CLAIMED_BY_SOMEONE_ELSE = 'AlreadyClaimedBySomeoneElse' EXPIRED = 'Expired' @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class ReferBusinessLinkUsedResponse: referring_user: Optional[ReferBusinessUser] = None referred_place: Optional[ReferredPlace] = None expires_at: Optional[datetime.datetime] = None state: Optional[ReferBusinessState] = None # @Route("/share/refer-business-link-used", "POST") @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class ReferBusinessLinkUsedRequest(IReturn[ReferBusinessLinkUsedResponse], IPost): refer_business_token: Optional[str] = None