/* Options: Date: 2025-12-06 09:34:06 SwiftVersion: 6.0 Version: 8.80 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://api.dev.dynamics.trendsic.com //BaseClass: //AddModelExtensions: True //AddServiceStackTypes: True //MakePropertiesOptional: True IncludeTypes: Messages.* //ExcludeTypes: //ExcludeGenericBaseTypes: False //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True //InitializeCollections: True //TreatTypesAsStrings: //DefaultImports: Foundation,ServiceStack */ import Foundation import ServiceStack // @Route("/v1/Messages", "GET,POST,PUT,DELETE,OPTIONS") // @Route("/v1/Messages/{Id}", "GET,POST,PUT,DELETE,OPTIONS") public class Messages : MessageObject, IReturn { public typealias Return = MessagesResponse public var apiKey:String? required public init(){ super.init() } private enum CodingKeys : String, CodingKey { case apiKey } required public init(from decoder: Decoder) throws { try super.init(from: decoder) let container = try decoder.container(keyedBy: CodingKeys.self) apiKey = try container.decodeIfPresent(String.self, forKey: .apiKey) } public override func encode(to encoder: Encoder) throws { try super.encode(to: encoder) var container = encoder.container(keyedBy: CodingKeys.self) if apiKey != nil { try container.encode(apiKey, forKey: .apiKey) } } } public class MessagesResponse : Codable { public var responseStatus:ResponseStatus? public var messages:[MessageObject] = [] required public init(){} } public class MessageObject : Codable { public var id:String? public var message:String? required public init(){} }