/* Options: Date: 2025-12-06 06:17:32 SwiftVersion: 5.0 Version: 8.0 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://1fetch.api.client.prod.86degrees.com //BaseClass: //AddModelExtensions: True //AddServiceStackTypes: True IncludeTypes: CheckAccount.* //ExcludeTypes: //ExcludeGenericBaseTypes: False //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True //InitializeCollections: True //TreatTypesAsStrings: //DefaultImports: Foundation,ServiceStack */ import Foundation import ServiceStack // @Route("/checkaccount", "GET") public class CheckAccount : ApiServiceRequest, IReturn, ILogRequest { public typealias Return = CheckAccountResponse required public init(){ super.init() } required public init(from decoder: Decoder) throws { try super.init(from: decoder) } public override func encode(to encoder: Encoder) throws { try super.encode(to: encoder) } } public class CheckAccountResponse : ApiServiceResponse { /** * The total monthly limit for account payments, will be negative if there is no limit */ // @ApiMember(Description="The total monthly limit for account payments, will be negative if there is no limit") public var accountLimit:Double /** * The amount that can still be used this month, will be negative if there is no account limit */ // @ApiMember(Description="The amount that can still be used this month, will be negative if there is no account limit") public var accountRemaining:Double /** * Shows if this account is allowed to place real orders or quotes */ // @ApiMember(Description="Shows if this account is allowed to place real orders or quotes") public var allowDataProcessing:Bool required public init(){ super.init() } private enum CodingKeys : String, CodingKey { case accountLimit case accountRemaining case allowDataProcessing } required public init(from decoder: Decoder) throws { try super.init(from: decoder) let container = try decoder.container(keyedBy: CodingKeys.self) accountLimit = try container.decodeIfPresent(Double.self, forKey: .accountLimit) accountRemaining = try container.decodeIfPresent(Double.self, forKey: .accountRemaining) allowDataProcessing = try container.decodeIfPresent(Bool.self, forKey: .allowDataProcessing) } public override func encode(to encoder: Encoder) throws { try super.encode(to: encoder) var container = encoder.container(keyedBy: CodingKeys.self) if accountLimit != nil { try container.encode(accountLimit, forKey: .accountLimit) } if accountRemaining != nil { try container.encode(accountRemaining, forKey: .accountRemaining) } if allowDataProcessing != nil { try container.encode(allowDataProcessing, forKey: .allowDataProcessing) } } } public class ApiServiceRequest : IServiceRequest, IHasApiKey, Codable { /** * The API Key required for authentication */ // @ApiMember(DataType="string", Description="The API Key required for authentication", IsRequired=true) public var apiKey:String required public init(){} } public protocol IServiceRequest { } public protocol IHasApiKey { var apiKey:String { get set } } public protocol ILogRequest { } public class ApiServiceResponse : IServiceResponse, Codable { /** * Information about the response. */ // @ApiMember(Description="Information about the response.", IsRequired=true) public var Description:String /** * Heading or summary of the response. */ // @ApiMember(Description="Heading or summary of the response.", IsRequired=true) public var heading:String /** * Did the intended operation for this response complete successfully? */ // @ApiMember(DataType="boolean", Description="Did the intended operation for this response complete successfully?", IsRequired=true) public var wasSuccessful:Bool required public init(){} }