/* Options: Date: 2024-05-19 20:00:32 Version: 6.40 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://evovoice.io //Package: //AddServiceStackTypes: True //AddResponseStatus: False //AddImplicitVersion: //AddDescriptionAsComments: True IncludeTypes: BuyPhoneNumber.* //ExcludeTypes: //InitializeCollections: True //TreatTypesAsStrings: //DefaultImports: java.math.*,java.util.*,net.servicestack.client.*,com.google.gson.annotations.*,com.google.gson.reflect.* */ import java.math.* import java.util.* import net.servicestack.client.* import com.google.gson.annotations.* import com.google.gson.reflect.* /** * Buys the specified phone number */ @Route(Path="/endpoints/phone-numbers", Verbs="POST") @Api(Description="Buys the specified phone number") open class BuyPhoneNumber : IReturn, IPost { /** * The ID of the account to associate the number with */ @ApiMember(Description="The ID of the account to associate the number with") var accountId:String? = null /** * The ID of the customer to associate this number with */ @ApiMember(Description="The ID of the customer to associate this number with") var customerId:String? = null /** * The number to buy/create */ @ApiMember(Description="The number to buy/create") var number:String? = null /** * Is this number virtual? If so we will not buy but just create an entry */ @ApiMember(Description="Is this number virtual? If so we will not buy but just create an entry") var isVirtualPhoneNumber:Boolean? = null /** * Is this a fax number? */ @ApiMember(Description="Is this a fax number?") var isFaxNumber:Boolean? = null /** * The address SID to associate with the phone number */ @ApiMember(Description="The address SID to associate with the phone number") var addressSid:String? = null /** * The list of tags to associate with the new endpoint */ @ApiMember(Description="The list of tags to associate with the new endpoint") var tagIds:ArrayList = ArrayList() /** * Data values for this endpoint */ @ApiMember(Description="Data values for this endpoint") @SerializedName("data") var Data:Struct? = null /** * Specify the flow to use */ @ApiMember(Description="Specify the flow to use") var flowId:String? = null /** * The flow params */ @ApiMember(Description="The flow params") var flowParams:Struct? = null companion object { private val responseType = EndpointInfo::class.java } override fun getResponseType(): Any? = BuyPhoneNumber.responseType } open class EndpointInfo : EntityInfo() { /** * The account ID this endpoint is associated with */ @ApiMember(Description="The account ID this endpoint is associated with") var accountId:String? = null /** * The name of the account this endpoint is associated with */ @ApiMember(Description="The name of the account this endpoint is associated with") var accountName:String? = null /** * The ID of the customer this endpoint is associated with */ @ApiMember(Description="The ID of the customer this endpoint is associated with") var customerId:String? = null /** * The name of the customer this endpoint is associated with */ @ApiMember(Description="The name of the customer this endpoint is associated with") var customerName:String? = null /** * The third party reference ID for the endpoint */ @ApiMember(Description="The third party reference ID for the endpoint") var referenceId:String? = null /** * The breadcrumb to the customer for this endpoint */ @ApiMember(Description="The breadcrumb to the customer for this endpoint") var customerBreadcrumb:ArrayList = ArrayList() /** * The display name of the endpoint */ @ApiMember(Description="The display name of the endpoint") var displayName:String? = null /** * The type of endpoint */ @ApiMember(Description="The type of endpoint") @SerializedName("type") var Type:EndpointTypes? = null /** * Extra info for this endpoint (typically to show in grid) */ @ApiMember(Description="Extra info for this endpoint (typically to show in grid)") var extraInformation:String? = null /** * The ID of the flow to use for voice */ @ApiMember(Description="The ID of the flow to use for voice") var flowId:String? = null /** * The name of the flow to use for voice */ @ApiMember(Description="The name of the flow to use for voice") var flowName:String? = null /** * The params for the voice flow */ @ApiMember(Description="The params for the voice flow") var flowParams:Struct? = null /** * Whether to use a single flow always or use scheduled flow system */ @ApiMember(Description="Whether to use a single flow always or use scheduled flow system") var flowSchedule:EndpointFlowSchedules? = null /** * This endpoint's schedule */ @ApiMember(Description="This endpoint's schedule") var schedule:Schedule? = null /** * The list of scheduled flows when using scheduling */ @ApiMember(Description="The list of scheduled flows when using scheduling") var scheduledFlows:ArrayList = ArrayList() /** * Disable SMS */ @ApiMember(Description="Disable SMS") var disableSms:Boolean? = null /** * Set this to true to prevent Evo Voice from overriding the 10DLC / SMS settings for this number */ @ApiMember(Description="Set this to true to prevent Evo Voice from overriding the 10DLC / SMS settings for this number") var useExternal10DlcCampaign:Boolean? = null /** * Is this a virtual phone number? */ @ApiMember(Description="Is this a virtual phone number?") var isVirtualPhoneNumber:Boolean? = null /** * Is caller ID verified for this virtual number? */ @ApiMember(Description="Is caller ID verified for this virtual number?") var isCallerIdVerified:Boolean? = null /** * The verification code for this number */ @ApiMember(Description="The verification code for this number") var callerIdVerificationCode:String? = null /** * The phone number */ @ApiMember(Description="The phone number") var phoneNumber:String? = null /** * The Sid of the phone number */ @ApiMember(Description="The Sid of the phone number") var phoneNumberSid:String? = null /** * The caller ID Name (CNAM) for the phone number */ @ApiMember(Description="The caller ID Name (CNAM) for the phone number") var callerIdName:String? = null /** * The address SID associated with the phone number */ @ApiMember(Description="The address SID associated with the phone number") var addressSid:String? = null /** * Do not touch this phone number - for BYOA accounts */ @ApiMember(Description="Do not touch this phone number - for BYOA accounts") var doNotTouchPhoneNumber:Boolean? = null /** * Is this number enrolled in a 10DLC messaging service campaign */ @ApiMember(Description="Is this number enrolled in a 10DLC messaging service campaign") var isEnrolledIn10DlcService:Boolean? = null /** * Whether we look up caller ID or not */ @ApiMember(Description="Whether we look up caller ID or not") var enableCallerIdLookup:Boolean? = null /** * The email address of the user */ @ApiMember(Description="The email address of the user") var userEmailAddress:String? = null /** * The Twilio Region for the SIP endpoint */ @ApiMember(Description="The Twilio Region for the SIP endpoint") var sipRegion:TwilioSipRegions? = null /** * The Twilio Sid of the credentials for Sip */ @ApiMember(Description="The Twilio Sid of the credentials for Sip") var sipCredentialSid:String? = null /** * The Twilio SIP user name */ @ApiMember(Description="The Twilio SIP user name") var sipUserName:String? = null /** * The Twilio SIP password */ @ApiMember(Description="The Twilio SIP password") var sipPassword:String? = null /** * The SIP domain */ @ApiMember(Description="The SIP domain") var sipDomain:String? = null /** * Is emergency calling enabled on this number? */ @ApiMember(Description="Is emergency calling enabled on this number?") var enableEmergencyCalling:Boolean? = null /** * The SID of the emergency address for this number */ @ApiMember(Description="The SID of the emergency address for this number") var emergencyAddressSid:String? = null /** * The ID of the phone number to use for emergency dialing */ @ApiMember(Description="The ID of the phone number to use for emergency dialing") var emergencyPhoneNumberId:String? = null /** * The current agent state of this user endpoint */ @ApiMember(Description="The current agent state of this user endpoint") var agentState:AgentStates? = null /** * The current agent state reason of this user endpoint */ @ApiMember(Description="The current agent state reason of this user endpoint") var agentStateReason:AgentStateReasons? = null /** * The mode for this user */ @ApiMember(Description="The mode for this user") var userMode:UserModes? = null /** * The ID of the file to use for voicemail greeting */ @ApiMember(Description="The ID of the file to use for voicemail greeting") var voicemailGreetingId:String? = null /** * The endpoint's data */ @ApiMember(Description="The endpoint's data") @SerializedName("data") var Data:Struct? = null /** * The email address for email endpoints */ @ApiMember(Description="The email address for email endpoints") var emailAddress:String? = null /** * The first name of the user (for user endpoints) */ @ApiMember(Description="The first name of the user (for user endpoints)") var userFirstName:String? = null /** * The last name of the user (for user endpoints) */ @ApiMember(Description="The last name of the user (for user endpoints)") var userLastName:String? = null /** * The URL of an image for this user's avatar */ @ApiMember(Description="The URL of an image for this user's avatar") var avatarUrl:String? = null /** * Does this user have manager role? */ @ApiMember(Description="Does this user have manager role?") var managerRole:UserManagerRoles? = null /** * The list of dashboard permissions for when the manager role is custom */ @ApiMember(Description="The list of dashboard permissions for when the manager role is custom") var dashboardPermissions:ArrayList = ArrayList() /** * The type of visibility this user has to their own fields */ @ApiMember(Description="The type of visibility this user has to their own fields") var myFieldPermissions:UserDataFieldModes? = null /** * The type of visibility this user has to customer fields */ @ApiMember(Description="The type of visibility this user has to customer fields") var customerFieldPermissions:UserDataFieldModes? = null /** * The type of visibility this user has to other user fields */ @ApiMember(Description="The type of visibility this user has to other user fields") var otherUserFieldPermissions:UserDataFieldModes? = null /** * The type of visibility this user has to other endpoint fields */ @ApiMember(Description="The type of visibility this user has to other endpoint fields") var otherEndpointFieldPermissions:UserDataFieldModes? = null /** * The name of this endpoint (for bots etc.) */ @ApiMember(Description="The name of this endpoint (for bots etc.)") var name:String? = null /** * The list of tags for this endpoint */ @ApiMember(Description="The list of tags for this endpoint") var tags:ArrayList = ArrayList() /** * The list of action URLs */ @ApiMember(Description="The list of action URLs") var actionUrls:ArrayList = ArrayList() /** * The list of members in this team */ @ApiMember(Description="The list of members in this team") var teamMemberIds:ArrayList = ArrayList() /** * Visibility of this user/team in contact lists */ @ApiMember(Description="Visibility of this user/team in contact lists") var contactListVisibility:CustomerVisibility? = null /** * The list of contacts personal to this user */ @ApiMember(Description="The list of contacts personal to this user") var contacts:ArrayList = ArrayList() /** * The documo ID for this number */ @ApiMember(Description="The documo ID for this number") var documoId:String? = null /** * Integration data for this endpoint */ @ApiMember(Description="Integration data for this endpoint") var integrationData:EntityIntegrationData? = null /** * Settings for third party phone system */ @ApiMember(Description="Settings for third party phone system") var thirdPartyPhoneSystemSettings:ThirdPartyPhoneSystemSettings? = null /** * Should this user override the parent customer's app settings */ @ApiMember(Description="Should this user override the parent customer's app settings") var overrideAppSettings:Boolean? = null /** * App / Portal settings for this user */ @ApiMember(Description="App / Portal settings for this user") var appSettings:AppSettings? = null } enum class ActionUrlHttpMethods { Get, Post, } open class Struct : HashMap() { } open class AppSettings { var enablePhoneNumberManagement:Boolean? = null var enableDeviceManagement:Boolean? = null var enableDialer:Boolean? = null var enableCallHistory:Boolean? = null var showFileNameInMessageCenter:Boolean? = null var chakraTheme:String? = null var customCss:String? = null var pageTitle:String? = null var stringMappings:String? = null var logoutUrl:String? = null var portMyNumberUrl:String? = null } enum class UserModes { SoftPhone, Sip, Flow, DataOnly, ThirdParty, } enum class EndpointFlowSchedules { Always, Scheduled, Simple, } open class ScheduledFlow { var stateName:String? = null var flowId:String? = null var flowParams:Struct? = null } enum class TwilioSipRegions { NorthAmericaVirginia, NorthAmericaOregon, EuropeIreland, EuropeFrankfurt, AsiaPacificSingapore, AsiaPacificTokyo, AsiaPacificSydney, SouthAmericaSanPaolo, } enum class UserManagerRoles { None, Manager, VoicemailAndCallHistory, Custom, } enum class DashboardPermissions { ViewFiles, ViewNotifications, ViewSessions, ViewEndpoints, ViewReports, ViewCustomers, ViewFlows, } enum class UserDataFieldModes { Hidden, ReadOnly, ReadWrite, } enum class CustomerVisibility { None, CurrentCustomer, CurrentAndChildCustomers, } open class EndpointActionUrl { var id:String? = null var url:String? = null var method:ActionUrlHttpMethods? = null } open class EndpointContact { var id:String? = null var displayName:String? = null var address:String? = null } open class ThirdPartyPhoneSystemSettings { @SerializedName("type") var Type:ThirdPartyPhoneSystemTypes? = null var sipSettings:ThirdPartySipSettings? = null var demoSettings:ThirdPartyDemoSettings? = null } enum class EndpointTypes { PhoneNumber, User, FaxNumber, EmailAddress, Unused1, Unused2, Unused3, Unused4, Unused5, Team, } enum class AgentStates { Unknown, Ready, NotReady, LoggedOut, WrapUp, Outgoing, Other, } open class Tag { var id:String? = null var name:String? = null var color:TagColors? = null } open class EntityInfo { /** * The ID of the object */ @ApiMember(Description="The ID of the object") var id:String? = null /** * The date the object was created */ @ApiMember(Description="The date the object was created") var dateCreated:String? = null /** * The date the object was last modified */ @ApiMember(Description="The date the object was last modified") var dateLastModified:String? = null /** * The user that created this object */ @ApiMember(Description="The user that created this object") var createdBy:String? = null /** * The user that last modified this object */ @ApiMember(Description="The user that last modified this object") var lastModifiedBy:String? = null } open class CustomerBreadcrumb { var id:String? = null var name:String? = null } enum class AgentStateReasons { Unknown, SetByUser, MissedCall, SetBySystem, } open class EntityIntegrationData : HashMap() { } open class Value { var boolValue:Boolean? = null var stringValue:String? = null var numberValue:Double? = null var listValue:ArrayList = ArrayList() var structValue:Struct? = null } enum class ThirdPartyPhoneSystemTypes { Demo, Sip, } open class ThirdPartySipSettings { var accounts:ArrayList = ArrayList() } open class ThirdPartyDemoSettings { var extension:String? = null } enum class TagColors { Magenta, Red, Volcano, Orange, Gold, Lime, Green, Cyan, Blue, GeekBlue, Purple, } open class IntegrationData { var thirdPartyId:String? = null } open class ThirdPartySipAccountSettings { var number:String? = null var agent:String? = null var authName:String? = null var userName:String? = null var displayName:String? = null var password:String? = null var userDomain:String? = null var registrationExpires:Int? = null var transportType:TransportTypes? = null var localIP:String? = null var localPort:Int? = null var sipServer:String? = null var sipServerPort:Int? = null var outboundServer:String? = null var outboundServerPort:Int? = null var stunServer:String? = null var stunPort:Int? = null var audioPlaybackDeviceName:String? = null var audioRecordingDeviceName:String? = null var audioCodecs:ArrayList = ArrayList() var dtmfMethod:DtmfMethods? = null } enum class TransportTypes { Udp, Tls, Tcp, Pers, } enum class AudioCodecTypes(val value:Int) { Pcmu(0), Gsm(3), Pcma(8), G722(9), G729(18), Ilbc(97), Amr(98), Amrwb(99), Speex(100), Dtmf(101), Speexwb(102), Isacwb(103), Isacswb(104), Opus(105), G7221(121), None(-1), } enum class DtmfMethods { RfC2833, Info, } open class Schedule { var timeZoneId:String? = null var inherit:Boolean? = null var forceClosed:Boolean? = null var rules:ArrayList = ArrayList() var defaultState:String? = null }