""" Options: Date: 2024-07-03 12:30:12 Version: 8.23 Tip: To override a DTO option, remove "#" prefix before updating BaseUrl: https://api.bokamera.se #GlobalNamespace: #AddServiceStackTypes: True #AddResponseStatus: False #AddImplicitVersion: #AddDescriptionAsComments: True IncludeTypes: MessageTypeQuery.* #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 @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class BaseModel: pass @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class MessageType(BaseModel): # @Required() name: Optional[str] = None # @Required() description: Optional[str] = None # @Required() max_characters: int = 0 # @Required() default_text: Optional[str] = None # @Required() send_method_id: int = 0 modified_date: Optional[datetime.datetime] = None id: int = 0 @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class MessageTypeQueryResponse: # @ApiMember(Description="The message type id") id: int = 0 """ The message type id """ # @ApiMember(Description="The message type name.") name: Optional[str] = None """ The message type name. """ # @ApiMember(Description="The message type description.") description: Optional[str] = None """ The message type description. """ # @ApiMember(Description="The maximum number of charachters that can be entered into message body using this type.") max_characters: int = 0 """ The maximum number of charachters that can be entered into message body using this type. """ # @ApiMember(Description="The default text that is always included when sending messages of this type.") default_text: Optional[str] = None """ The default text that is always included when sending messages of this type. """ # @ApiMember(Description="The send method for this type. 1 = Email, 2 = SMS.") send_method_id: int = 0 """ The send method for this type. 1 = Email, 2 = SMS. """ # @Route("/messages/templates/types", "GET") # @ApiResponse(Description="You were unauthorized to call this service", StatusCode=401) # @ValidateRequest(Validator="IsAuthenticated") @dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE) @dataclass class MessageTypeQuery(QueryDb2[MessageType, MessageTypeQueryResponse], IReturn[QueryResponse[MessageTypeQueryResponse]]): # @ApiMember(Description="The message type id.") id: Optional[int] = None """ The message type id. """ # @ApiMember(Description="The message send method id. 1 = Email, 2 = SMS") send_method_id: Optional[int] = None """ The message send method id. 1 = Email, 2 = SMS """