/* Options: Date: 2025-12-06 07:25:52 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: AgentContractRequest.* //ExcludeTypes: //ExcludeGenericBaseTypes: False //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True //InitializeCollections: True //TreatTypesAsStrings: //DefaultImports: Foundation,ServiceStack */ import Foundation import ServiceStack // @Route("/v1/AgentContract", "PUT,OPTIONS") // @Route("/v1/AgentContract/{AgentId}", "GET") public class AgentContractRequest : IReturn, Codable { public typealias Return = AgentContractResponse public var agentContract:[AgentContractExtended] = [] public var agentId:Int? required public init(){} } public class AgentContractResponse : Codable { public var responseStatus:ResponseStatus? public var agentContract:[AgentContractExtended] = [] required public init(){} } public class AgentRegistrationTemp : Codable { public var agentRegistrationTempId:Int? public var applicationId:String? public var company:String? public var ein:String? public var firstName:String? public var middleName:String? public var lastName:String? public var address1:String? public var address2:String? public var city:String? public var state:String? public var zip:String? public var email:String? public var homePhone:String? public var cellPhone:String? public var workPhone:String? public var agreeToDisclosures:Bool? public var agreeToDate:Date? public var paidDate:Date? public var agentNumber:String? public var upline1Name:String? public var upline1:Int? public var upline2Name:String? public var upline2:Int? public var recruitedBy:String? public var createdDate:Date? public var dob:Date? public var ssn:String? public var password:String? public var upline1Percent:Double? public var upline2Percent:Double? public var agentId:Int? public var accountName:String? public var accountType:String? public var accountNumber:String? public var accountRouting:String? public var w9_1:String? public var w9_2:String? public var w9_3_1:String? public var w9_3_2:String? public var w9_3_3:String? public var w9_3_4:String? public var w9_3_5:String? public var w9_3_6:String? public var w9_3_7:String? public var w9_3_8:String? public var w9_4_1:String? public var w9_4_2:String? public var w9_5:String? public var w9_6:String? public var w9_7:String? public var isSecurityLicensed:Bool? public var securityLicense:String? public var position:String? public var school:String? public var district:String? public var storeName:String? required public init(){} } public class AgentRegistrationAnswer : Codable { public var agentRegistrationTempId:Int? public var questionId:Int? public var answerYN:Bool? public var answerText:String? public var dateCreated:Date? required public init(){} } public class AgentStateLicense : Codable { public var agentRegistrationTempId:Int? public var state:String? public var licenseNum:String? required public init(){} } public class AgentContractExtended : Agent { public var agentContractId:Int? public var afAgreementReceivedDate:Date? public var directDepositReceivedDate:Date? public var dotNETCompleteDate:Date? public var associateAppUploadedDate:Date? public var lswContractLinkSentDate:Date? public var lswContractDoneDate:Date? public var lswLifeAgentCode:String? public var lswAnnuityAgentCode:String? public var lswWebsiteUserId:String? public var amlCompletedDate:Date? public var stateAnnuityTrainingCompletedDate:Date? public var lswProductTrainingCompletedDate:Date? public var eoExpirationDate:Date? public var sureLCLinkSentDate:Date? public var aeContractDoneDate:Date? public var aeAgentCode:String? public var mgaNorthAmericanContractSentDate:Date? public var mgaNorthAmericanAgentCode:String? public var americoContractDoneDate:Date? public var americoAgentCode:String? public var midlandContractDoneDate:Date? public var midlandAgentCode:String? public var jacksonContractDoneDate:Date? public var jacksonAgentCode:String? public var voyaContractDoneDate:Date? public var voyaAgentCode:String? public var horaceMannContractDoneDate:Date? public var horaceMannAgentCode:String? public var greatAmericanContractDoneDate:Date? public var greatAmericanAgentCode:String? public var mutualOfOmahaContractDoneDate:Date? public var mutualOfOmahaAgentCode:String? public var allanzContractDoneDate:Date? public var allanzAgentCode:String? public var fgContractDoneDate:Date? public var fgAgentCode:String? public var residentLicenseState:String? public var residentLicenseNumber:String? public var residentLicenseExpirationDate:Date? public var contractingComplete:Date? public var packageMailed:Date? public var trackingNum:String? public var protectiveContractDoneDate:Date? public var protectiveCode:String? public var atheneContractDoneDate:Date? public var atheneCode:String? public var forestersContractDoneDate:Date? public var forestersCode:String? public var achName:String? public var achNumber:String? public var achRouting:String? public var achAccountType:String? public var w9_1:String? public var w9_2:String? public var w9_3_1:String? public var w9_3_2:String? public var w9_3_3:String? public var w9_3_4:String? public var w9_3_5:String? public var w9_3_6:String? public var w9_3_7:String? public var w9_3_8:String? public var w9_4_1:String? public var w9_4_2:String? public var w9_5:String? public var w9_6:String? public var w9_7:String? public var agentRegistration:AgentRegistrationTemp? public var agentRegistrationAnswers:[AgentRegistrationQuestionAnswer] = [] public var agentStateLicenses:[AgentStateLicense] = [] public var contactCount:Int? public var payChexId:String? public var agentLevelLocked:Bool? public var securityLicense:String? required public init(){ super.init() } private enum CodingKeys : String, CodingKey { case agentContractId case afAgreementReceivedDate case directDepositReceivedDate case dotNETCompleteDate case associateAppUploadedDate case lswContractLinkSentDate case lswContractDoneDate case lswLifeAgentCode case lswAnnuityAgentCode case lswWebsiteUserId case amlCompletedDate case stateAnnuityTrainingCompletedDate case lswProductTrainingCompletedDate case eoExpirationDate case sureLCLinkSentDate case aeContractDoneDate case aeAgentCode case mgaNorthAmericanContractSentDate case mgaNorthAmericanAgentCode case americoContractDoneDate case americoAgentCode case midlandContractDoneDate case midlandAgentCode case jacksonContractDoneDate case jacksonAgentCode case voyaContractDoneDate case voyaAgentCode case horaceMannContractDoneDate case horaceMannAgentCode case greatAmericanContractDoneDate case greatAmericanAgentCode case mutualOfOmahaContractDoneDate case mutualOfOmahaAgentCode case allanzContractDoneDate case allanzAgentCode case fgContractDoneDate case fgAgentCode case residentLicenseState case residentLicenseNumber case residentLicenseExpirationDate case contractingComplete case packageMailed case trackingNum case protectiveContractDoneDate case protectiveCode case atheneContractDoneDate case atheneCode case forestersContractDoneDate case forestersCode case achName case achNumber case achRouting case achAccountType case w9_1 case w9_2 case w9_3_1 case w9_3_2 case w9_3_3 case w9_3_4 case w9_3_5 case w9_3_6 case w9_3_7 case w9_3_8 case w9_4_1 case w9_4_2 case w9_5 case w9_6 case w9_7 case agentRegistration case agentRegistrationAnswers case agentStateLicenses case contactCount case payChexId case agentLevelLocked case securityLicense } required public init(from decoder: Decoder) throws { try super.init(from: decoder) let container = try decoder.container(keyedBy: CodingKeys.self) agentContractId = try container.decodeIfPresent(Int.self, forKey: .agentContractId) afAgreementReceivedDate = try container.decodeIfPresent(Date.self, forKey: .afAgreementReceivedDate) directDepositReceivedDate = try container.decodeIfPresent(Date.self, forKey: .directDepositReceivedDate) dotNETCompleteDate = try container.decodeIfPresent(Date.self, forKey: .dotNETCompleteDate) associateAppUploadedDate = try container.decodeIfPresent(Date.self, forKey: .associateAppUploadedDate) lswContractLinkSentDate = try container.decodeIfPresent(Date.self, forKey: .lswContractLinkSentDate) lswContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .lswContractDoneDate) lswLifeAgentCode = try container.decodeIfPresent(String.self, forKey: .lswLifeAgentCode) lswAnnuityAgentCode = try container.decodeIfPresent(String.self, forKey: .lswAnnuityAgentCode) lswWebsiteUserId = try container.decodeIfPresent(String.self, forKey: .lswWebsiteUserId) amlCompletedDate = try container.decodeIfPresent(Date.self, forKey: .amlCompletedDate) stateAnnuityTrainingCompletedDate = try container.decodeIfPresent(Date.self, forKey: .stateAnnuityTrainingCompletedDate) lswProductTrainingCompletedDate = try container.decodeIfPresent(Date.self, forKey: .lswProductTrainingCompletedDate) eoExpirationDate = try container.decodeIfPresent(Date.self, forKey: .eoExpirationDate) sureLCLinkSentDate = try container.decodeIfPresent(Date.self, forKey: .sureLCLinkSentDate) aeContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .aeContractDoneDate) aeAgentCode = try container.decodeIfPresent(String.self, forKey: .aeAgentCode) mgaNorthAmericanContractSentDate = try container.decodeIfPresent(Date.self, forKey: .mgaNorthAmericanContractSentDate) mgaNorthAmericanAgentCode = try container.decodeIfPresent(String.self, forKey: .mgaNorthAmericanAgentCode) americoContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .americoContractDoneDate) americoAgentCode = try container.decodeIfPresent(String.self, forKey: .americoAgentCode) midlandContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .midlandContractDoneDate) midlandAgentCode = try container.decodeIfPresent(String.self, forKey: .midlandAgentCode) jacksonContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .jacksonContractDoneDate) jacksonAgentCode = try container.decodeIfPresent(String.self, forKey: .jacksonAgentCode) voyaContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .voyaContractDoneDate) voyaAgentCode = try container.decodeIfPresent(String.self, forKey: .voyaAgentCode) horaceMannContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .horaceMannContractDoneDate) horaceMannAgentCode = try container.decodeIfPresent(String.self, forKey: .horaceMannAgentCode) greatAmericanContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .greatAmericanContractDoneDate) greatAmericanAgentCode = try container.decodeIfPresent(String.self, forKey: .greatAmericanAgentCode) mutualOfOmahaContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .mutualOfOmahaContractDoneDate) mutualOfOmahaAgentCode = try container.decodeIfPresent(String.self, forKey: .mutualOfOmahaAgentCode) allanzContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .allanzContractDoneDate) allanzAgentCode = try container.decodeIfPresent(String.self, forKey: .allanzAgentCode) fgContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .fgContractDoneDate) fgAgentCode = try container.decodeIfPresent(String.self, forKey: .fgAgentCode) residentLicenseState = try container.decodeIfPresent(String.self, forKey: .residentLicenseState) residentLicenseNumber = try container.decodeIfPresent(String.self, forKey: .residentLicenseNumber) residentLicenseExpirationDate = try container.decodeIfPresent(Date.self, forKey: .residentLicenseExpirationDate) contractingComplete = try container.decodeIfPresent(Date.self, forKey: .contractingComplete) packageMailed = try container.decodeIfPresent(Date.self, forKey: .packageMailed) trackingNum = try container.decodeIfPresent(String.self, forKey: .trackingNum) protectiveContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .protectiveContractDoneDate) protectiveCode = try container.decodeIfPresent(String.self, forKey: .protectiveCode) atheneContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .atheneContractDoneDate) atheneCode = try container.decodeIfPresent(String.self, forKey: .atheneCode) forestersContractDoneDate = try container.decodeIfPresent(Date.self, forKey: .forestersContractDoneDate) forestersCode = try container.decodeIfPresent(String.self, forKey: .forestersCode) achName = try container.decodeIfPresent(String.self, forKey: .achName) achNumber = try container.decodeIfPresent(String.self, forKey: .achNumber) achRouting = try container.decodeIfPresent(String.self, forKey: .achRouting) achAccountType = try container.decodeIfPresent(String.self, forKey: .achAccountType) w9_1 = try container.decodeIfPresent(String.self, forKey: .w9_1) w9_2 = try container.decodeIfPresent(String.self, forKey: .w9_2) w9_3_1 = try container.decodeIfPresent(String.self, forKey: .w9_3_1) w9_3_2 = try container.decodeIfPresent(String.self, forKey: .w9_3_2) w9_3_3 = try container.decodeIfPresent(String.self, forKey: .w9_3_3) w9_3_4 = try container.decodeIfPresent(String.self, forKey: .w9_3_4) w9_3_5 = try container.decodeIfPresent(String.self, forKey: .w9_3_5) w9_3_6 = try container.decodeIfPresent(String.self, forKey: .w9_3_6) w9_3_7 = try container.decodeIfPresent(String.self, forKey: .w9_3_7) w9_3_8 = try container.decodeIfPresent(String.self, forKey: .w9_3_8) w9_4_1 = try container.decodeIfPresent(String.self, forKey: .w9_4_1) w9_4_2 = try container.decodeIfPresent(String.self, forKey: .w9_4_2) w9_5 = try container.decodeIfPresent(String.self, forKey: .w9_5) w9_6 = try container.decodeIfPresent(String.self, forKey: .w9_6) w9_7 = try container.decodeIfPresent(String.self, forKey: .w9_7) agentRegistration = try container.decodeIfPresent(AgentRegistrationTemp.self, forKey: .agentRegistration) agentRegistrationAnswers = try container.decodeIfPresent([AgentRegistrationQuestionAnswer].self, forKey: .agentRegistrationAnswers) ?? [] agentStateLicenses = try container.decodeIfPresent([AgentStateLicense].self, forKey: .agentStateLicenses) ?? [] contactCount = try container.decodeIfPresent(Int.self, forKey: .contactCount) payChexId = try container.decodeIfPresent(String.self, forKey: .payChexId) agentLevelLocked = try container.decodeIfPresent(Bool.self, forKey: .agentLevelLocked) securityLicense = try container.decodeIfPresent(String.self, forKey: .securityLicense) } public override func encode(to encoder: Encoder) throws { try super.encode(to: encoder) var container = encoder.container(keyedBy: CodingKeys.self) if agentContractId != nil { try container.encode(agentContractId, forKey: .agentContractId) } if afAgreementReceivedDate != nil { try container.encode(afAgreementReceivedDate, forKey: .afAgreementReceivedDate) } if directDepositReceivedDate != nil { try container.encode(directDepositReceivedDate, forKey: .directDepositReceivedDate) } if dotNETCompleteDate != nil { try container.encode(dotNETCompleteDate, forKey: .dotNETCompleteDate) } if associateAppUploadedDate != nil { try container.encode(associateAppUploadedDate, forKey: .associateAppUploadedDate) } if lswContractLinkSentDate != nil { try container.encode(lswContractLinkSentDate, forKey: .lswContractLinkSentDate) } if lswContractDoneDate != nil { try container.encode(lswContractDoneDate, forKey: .lswContractDoneDate) } if lswLifeAgentCode != nil { try container.encode(lswLifeAgentCode, forKey: .lswLifeAgentCode) } if lswAnnuityAgentCode != nil { try container.encode(lswAnnuityAgentCode, forKey: .lswAnnuityAgentCode) } if lswWebsiteUserId != nil { try container.encode(lswWebsiteUserId, forKey: .lswWebsiteUserId) } if amlCompletedDate != nil { try container.encode(amlCompletedDate, forKey: .amlCompletedDate) } if stateAnnuityTrainingCompletedDate != nil { try container.encode(stateAnnuityTrainingCompletedDate, forKey: .stateAnnuityTrainingCompletedDate) } if lswProductTrainingCompletedDate != nil { try container.encode(lswProductTrainingCompletedDate, forKey: .lswProductTrainingCompletedDate) } if eoExpirationDate != nil { try container.encode(eoExpirationDate, forKey: .eoExpirationDate) } if sureLCLinkSentDate != nil { try container.encode(sureLCLinkSentDate, forKey: .sureLCLinkSentDate) } if aeContractDoneDate != nil { try container.encode(aeContractDoneDate, forKey: .aeContractDoneDate) } if aeAgentCode != nil { try container.encode(aeAgentCode, forKey: .aeAgentCode) } if mgaNorthAmericanContractSentDate != nil { try container.encode(mgaNorthAmericanContractSentDate, forKey: .mgaNorthAmericanContractSentDate) } if mgaNorthAmericanAgentCode != nil { try container.encode(mgaNorthAmericanAgentCode, forKey: .mgaNorthAmericanAgentCode) } if americoContractDoneDate != nil { try container.encode(americoContractDoneDate, forKey: .americoContractDoneDate) } if americoAgentCode != nil { try container.encode(americoAgentCode, forKey: .americoAgentCode) } if midlandContractDoneDate != nil { try container.encode(midlandContractDoneDate, forKey: .midlandContractDoneDate) } if midlandAgentCode != nil { try container.encode(midlandAgentCode, forKey: .midlandAgentCode) } if jacksonContractDoneDate != nil { try container.encode(jacksonContractDoneDate, forKey: .jacksonContractDoneDate) } if jacksonAgentCode != nil { try container.encode(jacksonAgentCode, forKey: .jacksonAgentCode) } if voyaContractDoneDate != nil { try container.encode(voyaContractDoneDate, forKey: .voyaContractDoneDate) } if voyaAgentCode != nil { try container.encode(voyaAgentCode, forKey: .voyaAgentCode) } if horaceMannContractDoneDate != nil { try container.encode(horaceMannContractDoneDate, forKey: .horaceMannContractDoneDate) } if horaceMannAgentCode != nil { try container.encode(horaceMannAgentCode, forKey: .horaceMannAgentCode) } if greatAmericanContractDoneDate != nil { try container.encode(greatAmericanContractDoneDate, forKey: .greatAmericanContractDoneDate) } if greatAmericanAgentCode != nil { try container.encode(greatAmericanAgentCode, forKey: .greatAmericanAgentCode) } if mutualOfOmahaContractDoneDate != nil { try container.encode(mutualOfOmahaContractDoneDate, forKey: .mutualOfOmahaContractDoneDate) } if mutualOfOmahaAgentCode != nil { try container.encode(mutualOfOmahaAgentCode, forKey: .mutualOfOmahaAgentCode) } if allanzContractDoneDate != nil { try container.encode(allanzContractDoneDate, forKey: .allanzContractDoneDate) } if allanzAgentCode != nil { try container.encode(allanzAgentCode, forKey: .allanzAgentCode) } if fgContractDoneDate != nil { try container.encode(fgContractDoneDate, forKey: .fgContractDoneDate) } if fgAgentCode != nil { try container.encode(fgAgentCode, forKey: .fgAgentCode) } if residentLicenseState != nil { try container.encode(residentLicenseState, forKey: .residentLicenseState) } if residentLicenseNumber != nil { try container.encode(residentLicenseNumber, forKey: .residentLicenseNumber) } if residentLicenseExpirationDate != nil { try container.encode(residentLicenseExpirationDate, forKey: .residentLicenseExpirationDate) } if contractingComplete != nil { try container.encode(contractingComplete, forKey: .contractingComplete) } if packageMailed != nil { try container.encode(packageMailed, forKey: .packageMailed) } if trackingNum != nil { try container.encode(trackingNum, forKey: .trackingNum) } if protectiveContractDoneDate != nil { try container.encode(protectiveContractDoneDate, forKey: .protectiveContractDoneDate) } if protectiveCode != nil { try container.encode(protectiveCode, forKey: .protectiveCode) } if atheneContractDoneDate != nil { try container.encode(atheneContractDoneDate, forKey: .atheneContractDoneDate) } if atheneCode != nil { try container.encode(atheneCode, forKey: .atheneCode) } if forestersContractDoneDate != nil { try container.encode(forestersContractDoneDate, forKey: .forestersContractDoneDate) } if forestersCode != nil { try container.encode(forestersCode, forKey: .forestersCode) } if achName != nil { try container.encode(achName, forKey: .achName) } if achNumber != nil { try container.encode(achNumber, forKey: .achNumber) } if achRouting != nil { try container.encode(achRouting, forKey: .achRouting) } if achAccountType != nil { try container.encode(achAccountType, forKey: .achAccountType) } if w9_1 != nil { try container.encode(w9_1, forKey: .w9_1) } if w9_2 != nil { try container.encode(w9_2, forKey: .w9_2) } if w9_3_1 != nil { try container.encode(w9_3_1, forKey: .w9_3_1) } if w9_3_2 != nil { try container.encode(w9_3_2, forKey: .w9_3_2) } if w9_3_3 != nil { try container.encode(w9_3_3, forKey: .w9_3_3) } if w9_3_4 != nil { try container.encode(w9_3_4, forKey: .w9_3_4) } if w9_3_5 != nil { try container.encode(w9_3_5, forKey: .w9_3_5) } if w9_3_6 != nil { try container.encode(w9_3_6, forKey: .w9_3_6) } if w9_3_7 != nil { try container.encode(w9_3_7, forKey: .w9_3_7) } if w9_3_8 != nil { try container.encode(w9_3_8, forKey: .w9_3_8) } if w9_4_1 != nil { try container.encode(w9_4_1, forKey: .w9_4_1) } if w9_4_2 != nil { try container.encode(w9_4_2, forKey: .w9_4_2) } if w9_5 != nil { try container.encode(w9_5, forKey: .w9_5) } if w9_6 != nil { try container.encode(w9_6, forKey: .w9_6) } if w9_7 != nil { try container.encode(w9_7, forKey: .w9_7) } if agentRegistration != nil { try container.encode(agentRegistration, forKey: .agentRegistration) } if agentRegistrationAnswers.count > 0 { try container.encode(agentRegistrationAnswers, forKey: .agentRegistrationAnswers) } if agentStateLicenses.count > 0 { try container.encode(agentStateLicenses, forKey: .agentStateLicenses) } if contactCount != nil { try container.encode(contactCount, forKey: .contactCount) } if payChexId != nil { try container.encode(payChexId, forKey: .payChexId) } if agentLevelLocked != nil { try container.encode(agentLevelLocked, forKey: .agentLevelLocked) } if securityLicense != nil { try container.encode(securityLicense, forKey: .securityLicense) } } } public class Agent : Codable { public var agentId:Int? public var company:String? public var agentName:String? public var firstName:String? public var lastName:String? public var middleInitial:String? public var address1:String? public var address2:String? public var city:String? public var state:String? public var zip:String? public var country:String? public var email:String? public var emailSignature:String? public var homePhone:String? public var cellPhone:String? public var workPhone:String? public var insLicensed:Bool? public var agreeToDisclosures:Bool? public var agreeToDate:Date? public var paidDate:Date? public var agentNumber:String? public var referringAgent:String? public var placementAgent:String? public var createdDate:Date? public var userId:String? public var isAgent:Bool? public var package:String? public var storeName:String? public var notes:String? public var upline1:Int? public var upline2:Int? public var upline3:Int? public var upline4:Int? public var mvpid:Int? public var avpid:Int? public var rvpid:Int? public var agentLevel:Double? public var isMVP:Bool? public var isRVP:Bool? public var isAVP:Bool? public var isAdmin:Bool? public var isBusinessCardAdmin:Bool? public var teamName:String? public var locationId:String? public var calendarId:String? public var rank:String? public var nbc:Bool? public var upline1Percent:Double? public var upline2Percent:Double? public var upline3Percent:Double? public var upline4Percent:Double? public var agentStatus:String? public var office:String? public var dob:Date? public var ssn:String? public var fax:String? public var businessEmail:String? public var modifiedDate:Date? public var modifiedBy:String? public var timeZone:String? public var leaderLocked:Bool? public var lastSubmittedBusinessDate:Date? public var gracePeriodDate:Date? public var vested:Bool? public var directPay:Date? public var directPayApprBy:String? public var factFinderBilling:Double? public var fullName:String? public var byLastName:String? public var isSecurityLicensed:Bool? public var isEncompassAdmin:Bool? public var apiKey:String? public var lastSessionId:String? public var lastLogin:Date? public var mfaActive:Bool? public var requireMFA:Bool? public var smsPhoneNumber:String? public var verifiedEmailStatus:Bool? public var verifiedCellPhoneStatus:Bool? public var schedulerUrl:String? public var queueDefaults:QueueDefault? public var roles:[String] = [] public var passwordUpdated:Bool? public var restrictToSingleSession:Bool? required public init(){} } public class AgentRegistrationQuestionAnswer : AgentRegistrationAnswer { public var details:String? public var questionType:String? public var group:String? public var indexOrder:Int? required public init(){ super.init() } private enum CodingKeys : String, CodingKey { case details case questionType case group case indexOrder } required public init(from decoder: Decoder) throws { try super.init(from: decoder) let container = try decoder.container(keyedBy: CodingKeys.self) details = try container.decodeIfPresent(String.self, forKey: .details) questionType = try container.decodeIfPresent(String.self, forKey: .questionType) group = try container.decodeIfPresent(String.self, forKey: .group) indexOrder = try container.decodeIfPresent(Int.self, forKey: .indexOrder) } public override func encode(to encoder: Encoder) throws { try super.encode(to: encoder) var container = encoder.container(keyedBy: CodingKeys.self) if details != nil { try container.encode(details, forKey: .details) } if questionType != nil { try container.encode(questionType, forKey: .questionType) } if group != nil { try container.encode(group, forKey: .group) } if indexOrder != nil { try container.encode(indexOrder, forKey: .indexOrder) } } } public class QueueDefault : Codable { public var locationId:String? public var services:[String] = [] required public init(){} }