| GET | /portal/users |
|---|
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
class SortOrders(str, Enum):
ASCEND = 'Ascend'
DESCEND = 'Descend'
T = TypeVar('T')
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ListRequest(Generic[T], IReturn[ListResponse[T]], IGet):
# @ApiMember(Description="The page of data to retrieve")
page: int = 0
"""
The page of data to retrieve
"""
# @ApiMember(Description="If you want all objects to be returned. This should be used with care")
all: bool = False
"""
If you want all objects to be returned. This should be used with care
"""
# @ApiMember(Description="The number per page to retrieve")
count_per_page: int = 0
"""
The number per page to retrieve
"""
# @ApiMember(Description="Specific IDs")
specific_ids: Optional[List[str]] = None
"""
Specific IDs
"""
# @ApiMember(Description="Specify a sort field")
sort_field: Optional[str] = None
"""
Specify a sort field
"""
# @ApiMember(Description="Specify a sort order")
sort_order: Optional[SortOrders] = None
"""
Specify a sort order
"""
# @ApiMember(Description="Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array")
simplified_paging: bool = False
"""
Disables total / page counts - improves performance. Returns only data. If there is no more data, Items will be empty array
"""
@staticmethod
def response_type(): return ListResponse[T]
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EntityInfo:
# @ApiMember(Description="The ID of the object")
id: Optional[str] = None
"""
The ID of the object
"""
# @ApiMember(Description="The date the object was created")
date_created: Optional[str] = None
"""
The date the object was created
"""
# @ApiMember(Description="The date the object was last modified")
date_last_modified: Optional[str] = None
"""
The date the object was last modified
"""
# @ApiMember(Description="The user that created this object")
created_by: Optional[str] = None
"""
The user that created this object
"""
# @ApiMember(Description="The user that last modified this object")
last_modified_by: Optional[str] = None
"""
The user that last modified this object
"""
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class CustomerBreadcrumb:
id: Optional[str] = None
name: Optional[str] = None
class EndpointTypes(str, Enum):
PHONE_NUMBER = 'PhoneNumber'
USER = 'User'
FAX_NUMBER = 'FaxNumber'
EMAIL_ADDRESS = 'EmailAddress'
UNUSED_1 = 'Unused_1'
UNUSED_2 = 'Unused_2'
UNUSED_3 = 'Unused_3'
UNUSED_4 = 'Unused_4'
UNUSED_5 = 'Unused_5'
TEAM = 'Team'
ASSISTANT = 'Assistant'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Value:
bool_value: Optional[bool] = None
string_value: Optional[str] = None
number_value: Optional[float] = None
list_value: Optional[List[Struct]] = None
struct_value: Optional[Struct] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Struct(Dict[str,Value]):
pass
class EndpointFlowSchedules(str, Enum):
ALWAYS = 'Always'
SCHEDULED = 'Scheduled'
SIMPLE = 'Simple'
class SimpleSchedulingRuleTypes(str, Enum):
ALWAYS = 'Always'
CUSTOMER_STATE = 'CustomerState'
TIME = 'Time'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ScheduleDay:
offset: int = 0
day_of_week: Optional[DayOfWeek] = None
class SchedulingRuleFrequency(str, Enum):
NONE = 'None'
SECONDLY = 'Secondly'
MINUTELY = 'Minutely'
HOURLY = 'Hourly'
DAILY = 'Daily'
WEEKLY = 'Weekly'
MONTHLY = 'Monthly'
YEARLY = 'Yearly'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class SchedulingRule:
id: Optional[str] = None
name: Optional[str] = None
priority: int = 0
state: Optional[str] = None
source: Optional[str] = None
condition: Optional[str] = None
simple_rule_type: Optional[SimpleSchedulingRuleTypes] = None
customer_state: Optional[str] = None
flow_id: Optional[str] = None
flow_params: Optional[Struct] = None
is_all_day: bool = False
start_date: Optional[str] = None
start_time: Optional[str] = None
end_time: Optional[str] = None
by_set_position: Optional[List[int]] = None
by_month: Optional[List[int]] = None
by_week_no: Optional[List[int]] = None
by_year_day: Optional[List[int]] = None
by_month_day: Optional[List[int]] = None
by_day: Optional[List[ScheduleDay]] = None
by_hour: Optional[List[int]] = None
by_minute: Optional[List[int]] = None
interval: int = 0
count: int = 0
until_date: Optional[str] = None
frequency: Optional[SchedulingRuleFrequency] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Schedule:
time_zone_id: Optional[str] = None
inherit: bool = False
force_closed: bool = False
rules: Optional[List[SchedulingRule]] = None
default_state: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ScheduledFlow:
state_name: Optional[str] = None
flow_id: Optional[str] = None
flow_params: Optional[Struct] = None
class TwilioSipRegions(str, Enum):
NORTH_AMERICA_VIRGINIA = 'NorthAmericaVirginia'
NORTH_AMERICA_OREGON = 'NorthAmericaOregon'
EUROPE_IRELAND = 'EuropeIreland'
EUROPE_FRANKFURT = 'EuropeFrankfurt'
ASIA_PACIFIC_SINGAPORE = 'AsiaPacificSingapore'
ASIA_PACIFIC_TOKYO = 'AsiaPacificTokyo'
ASIA_PACIFIC_SYDNEY = 'AsiaPacificSydney'
SOUTH_AMERICA_SAN_PAOLO = 'SouthAmericaSanPaolo'
class AgentStates(str, Enum):
UNKNOWN = 'Unknown'
READY = 'Ready'
NOT_READY = 'NotReady'
LOGGED_OUT = 'LoggedOut'
WRAP_UP = 'WrapUp'
OUTGOING = 'Outgoing'
OTHER = 'Other'
class AgentStateReasons(str, Enum):
UNKNOWN = 'Unknown'
SET_BY_USER = 'SetByUser'
MISSED_CALL = 'MissedCall'
SET_BY_SYSTEM = 'SetBySystem'
class UserModes(str, Enum):
SOFT_PHONE = 'SoftPhone'
SIP = 'Sip'
FLOW = 'Flow'
DATA_ONLY = 'DataOnly'
THIRD_PARTY = 'ThirdParty'
class UserManagerRoles(str, Enum):
NONE = 'None'
MANAGER = 'Manager'
VOICEMAIL_AND_CALL_HISTORY = 'VoicemailAndCallHistory'
CUSTOM = 'Custom'
class UserManagerAccess(str, Enum):
READ_ONLY = 'ReadOnly'
READ_WRITE = 'ReadWrite'
READ_WRITE_DELETE = 'ReadWriteDelete'
class DashboardPermissions(str, Enum):
VIEW_FILES = 'ViewFiles'
VIEW_NOTIFICATIONS = 'ViewNotifications'
VIEW_SESSIONS = 'ViewSessions'
VIEW_ENDPOINTS = 'ViewEndpoints'
VIEW_REPORTS = 'ViewReports'
VIEW_CUSTOMERS = 'ViewCustomers'
VIEW_FLOWS = 'ViewFlows'
VIEW_CALL_CENTER = 'ViewCallCenter'
class UserDataFieldModes(str, Enum):
HIDDEN = 'Hidden'
READ_ONLY = 'ReadOnly'
READ_WRITE = 'ReadWrite'
class TagColors(str, Enum):
MAGENTA = 'Magenta'
RED = 'Red'
VOLCANO = 'Volcano'
ORANGE = 'Orange'
GOLD = 'Gold'
LIME = 'Lime'
GREEN = 'Green'
CYAN = 'Cyan'
BLUE = 'Blue'
GEEK_BLUE = 'GeekBlue'
PURPLE = 'Purple'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Tag:
id: Optional[str] = None
name: Optional[str] = None
color: Optional[TagColors] = None
class ActionUrlHttpMethods(str, Enum):
GET = 'GET'
POST = 'POST'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EndpointActionUrl:
id: Optional[str] = None
url: Optional[str] = None
method: Optional[ActionUrlHttpMethods] = None
class CustomerVisibility(str, Enum):
NONE = 'None'
CURRENT_CUSTOMER = 'CurrentCustomer'
CURRENT_AND_CHILD_CUSTOMERS = 'CurrentAndChildCustomers'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EndpointContact:
id: Optional[str] = None
display_name: Optional[str] = None
address: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class IntegrationData:
third_party_id: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EntityIntegrationData(Dict[str,IntegrationData]):
pass
class ThirdPartyPhoneSystemTypes(str, Enum):
DEMO = 'Demo'
SIP = 'Sip'
class TransportTypes(str, Enum):
UDP = 'UDP'
TLS = 'TLS'
TCP = 'TCP'
PERS = 'PERS'
class AudioCodecTypes(IntEnum):
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
class DtmfMethods(str, Enum):
RF_C2833 = 'RFC2833'
INFO = 'INFO'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ThirdPartySipAccountSettings:
number: Optional[str] = None
agent: Optional[str] = None
auth_name: Optional[str] = None
user_name: Optional[str] = None
display_name: Optional[str] = None
password: Optional[str] = None
user_domain: Optional[str] = None
registration_expires: int = 0
transport_type: Optional[TransportTypes] = None
local_i_p: Optional[str] = None
local_port: int = 0
sip_server: Optional[str] = None
sip_server_port: int = 0
outbound_server: Optional[str] = None
outbound_server_port: int = 0
stun_server: Optional[str] = None
stun_port: int = 0
audio_playback_device_name: Optional[str] = None
audio_recording_device_name: Optional[str] = None
audio_codecs: Optional[List[AudioCodecTypes]] = None
dtmf_method: Optional[DtmfMethods] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ThirdPartySipSettings:
accounts: Optional[List[ThirdPartySipAccountSettings]] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ThirdPartyDemoSettings:
extension: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ThirdPartyPhoneSystemSettings:
type: Optional[ThirdPartyPhoneSystemTypes] = None
sip_settings: Optional[ThirdPartySipSettings] = None
demo_settings: Optional[ThirdPartyDemoSettings] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AppSettings:
enable_phone_number_management: bool = False
enable_device_management: bool = False
enable_dialer: bool = False
enable_call_history: bool = False
enable_assistants: bool = False
show_file_name_in_message_center: bool = False
chakra_theme: Optional[str] = None
custom_css: Optional[str] = None
page_title: Optional[str] = None
string_mappings: Optional[str] = None
logout_url: Optional[str] = None
port_my_number_url: Optional[str] = None
class AssistantTunings(str, Enum):
ACCURACY = 'Accuracy'
SPEED = 'Speed'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AssistantWord:
word: Optional[str] = None
pronounced: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AssistantLink:
url: Optional[str] = None
description: Optional[str] = None
class AssistantTransferTypes(str, Enum):
BLIND = 'Blind'
SUPERVISED = 'Supervised'
MESSAGES_ONLY = 'MessagesOnly'
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AssistantTakeMessageField:
name: Optional[str] = None
description: Optional[str] = None
required: bool = False
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AssistantContact:
name: Optional[str] = None
phone_number: Optional[str] = None
transfer_type: Optional[AssistantTransferTypes] = None
about: Optional[str] = None
email_address: Optional[str] = None
take_message_fields: Optional[List[AssistantTakeMessageField]] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AssistantIntegration:
uri: Optional[str] = None
http_method: Optional[str] = None
auth_token: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AssistantSettings:
company_name: Optional[str] = None
greeting: Optional[str] = None
company_information: Optional[str] = None
custom_prompt: Optional[str] = None
voice: Optional[str] = None
voice_style: Optional[str] = None
tuning: Optional[AssistantTunings] = None
words: Optional[List[AssistantWord]] = None
links: Optional[List[AssistantLink]] = None
contacts: Optional[List[AssistantContact]] = None
integrations: Optional[List[AssistantIntegration]] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EmbedSettings:
enabled: bool = False
allowed_hosts: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class EndpointInfo(EntityInfo):
# @ApiMember(Description="The account ID this endpoint is associated with")
account_id: Optional[str] = None
"""
The account ID this endpoint is associated with
"""
# @ApiMember(Description="The name of the account this endpoint is associated with")
account_name: Optional[str] = None
"""
The name of the account this endpoint is associated with
"""
# @ApiMember(Description="The ID of the customer this endpoint is associated with")
customer_id: Optional[str] = None
"""
The ID of the customer this endpoint is associated with
"""
# @ApiMember(Description="The name of the customer this endpoint is associated with")
customer_name: Optional[str] = None
"""
The name of the customer this endpoint is associated with
"""
# @ApiMember(Description="The third party reference ID for the endpoint")
reference_id: Optional[str] = None
"""
The third party reference ID for the endpoint
"""
# @ApiMember(Description="The breadcrumb to the customer for this endpoint")
customer_breadcrumb: Optional[List[CustomerBreadcrumb]] = None
"""
The breadcrumb to the customer for this endpoint
"""
# @ApiMember(Description="The display name of the endpoint")
display_name: Optional[str] = None
"""
The display name of the endpoint
"""
# @ApiMember(Description="The type of endpoint")
type: Optional[EndpointTypes] = None
"""
The type of endpoint
"""
# @ApiMember(Description="Extra info for this endpoint (typically to show in grid)")
extra_information: Optional[str] = None
"""
Extra info for this endpoint (typically to show in grid)
"""
# @ApiMember(Description="The ID of the flow to use for voice")
flow_id: Optional[str] = None
"""
The ID of the flow to use for voice
"""
# @ApiMember(Description="The name of the flow to use for voice")
flow_name: Optional[str] = None
"""
The name of the flow to use for voice
"""
# @ApiMember(Description="The params for the voice flow")
flow_params: Optional[Struct] = None
"""
The params for the voice flow
"""
# @ApiMember(Description="Whether to use a single flow always or use scheduled flow system")
flow_schedule: Optional[EndpointFlowSchedules] = None
"""
Whether to use a single flow always or use scheduled flow system
"""
# @ApiMember(Description="This endpoint's schedule")
schedule: Optional[Schedule] = None
"""
This endpoint's schedule
"""
# @ApiMember(Description="The list of scheduled flows when using scheduling")
scheduled_flows: Optional[List[ScheduledFlow]] = None
"""
The list of scheduled flows when using scheduling
"""
# @ApiMember(Description="Disable SMS")
disable_sms: bool = False
"""
Disable SMS
"""
# @ApiMember(Description="Set this to true to prevent Evo Voice from overriding the 10DLC / SMS settings for this number")
use_external10_dlc_campaign: bool = False
"""
Set this to true to prevent Evo Voice from overriding the 10DLC / SMS settings for this number
"""
# @ApiMember(Description="Is this a virtual phone number?")
is_virtual_phone_number: bool = False
"""
Is this a virtual phone number?
"""
# @ApiMember(Description="Is caller ID verified for this virtual number?")
is_caller_id_verified: bool = False
"""
Is caller ID verified for this virtual number?
"""
# @ApiMember(Description="The verification code for this number")
caller_id_verification_code: Optional[str] = None
"""
The verification code for this number
"""
# @ApiMember(Description="The phone number")
phone_number: Optional[str] = None
"""
The phone number
"""
# @ApiMember(Description="The Sid of the phone number")
phone_number_sid: Optional[str] = None
"""
The Sid of the phone number
"""
# @ApiMember(Description="The caller ID Name (CNAM) for the phone number")
caller_id_name: Optional[str] = None
"""
The caller ID Name (CNAM) for the phone number
"""
# @ApiMember(Description="The address SID associated with the phone number")
address_sid: Optional[str] = None
"""
The address SID associated with the phone number
"""
# @ApiMember(Description="Do not touch this phone number - for BYOA accounts")
do_not_touch_phone_number: bool = False
"""
Do not touch this phone number - for BYOA accounts
"""
# @ApiMember(Description="Is this number enrolled in a 10DLC messaging service campaign")
is_enrolled_in10_dlc_service: bool = False
"""
Is this number enrolled in a 10DLC messaging service campaign
"""
# @ApiMember(Description="Whether we look up caller ID or not")
enable_caller_id_lookup: bool = False
"""
Whether we look up caller ID or not
"""
# @ApiMember(Description="The email address of the user")
user_email_address: Optional[str] = None
"""
The email address of the user
"""
# @ApiMember(Description="The Twilio Region for the SIP endpoint")
sip_region: Optional[TwilioSipRegions] = None
"""
The Twilio Region for the SIP endpoint
"""
# @ApiMember(Description="The Twilio Sid of the credentials for Sip")
sip_credential_sid: Optional[str] = None
"""
The Twilio Sid of the credentials for Sip
"""
# @ApiMember(Description="The Twilio SIP user name")
sip_user_name: Optional[str] = None
"""
The Twilio SIP user name
"""
# @ApiMember(Description="The Twilio SIP password")
sip_password: Optional[str] = None
"""
The Twilio SIP password
"""
# @ApiMember(Description="The SIP domain")
sip_domain: Optional[str] = None
"""
The SIP domain
"""
# @ApiMember(Description="Is emergency calling enabled on this number?")
enable_emergency_calling: bool = False
"""
Is emergency calling enabled on this number?
"""
# @ApiMember(Description="The SID of the emergency address for this number")
emergency_address_sid: Optional[str] = None
"""
The SID of the emergency address for this number
"""
# @ApiMember(Description="The ID of the phone number to use for emergency dialing")
emergency_phone_number_id: Optional[str] = None
"""
The ID of the phone number to use for emergency dialing
"""
# @ApiMember(Description="The current agent state of this user endpoint")
agent_state: Optional[AgentStates] = None
"""
The current agent state of this user endpoint
"""
# @ApiMember(Description="The current agent state reason of this user endpoint")
agent_state_reason: Optional[AgentStateReasons] = None
"""
The current agent state reason of this user endpoint
"""
# @ApiMember(Description="The mode for this user")
user_mode: Optional[UserModes] = None
"""
The mode for this user
"""
# @ApiMember(Description="The ID of the file to use for voicemail greeting")
voicemail_greeting_id: Optional[str] = None
"""
The ID of the file to use for voicemail greeting
"""
# @ApiMember(Description="The endpoint's data")
data: Optional[Struct] = None
"""
The endpoint's data
"""
# @ApiMember(Description="The email address for email endpoints")
email_address: Optional[str] = None
"""
The email address for email endpoints
"""
# @ApiMember(Description="The first name of the user (for user endpoints)")
user_first_name: Optional[str] = None
"""
The first name of the user (for user endpoints)
"""
# @ApiMember(Description="The last name of the user (for user endpoints)")
user_last_name: Optional[str] = None
"""
The last name of the user (for user endpoints)
"""
# @ApiMember(Description="The URL of an image for this user's avatar")
avatar_url: Optional[str] = None
"""
The URL of an image for this user's avatar
"""
# @ApiMember(Description="Does this user have manager role?")
manager_role: Optional[UserManagerRoles] = None
"""
Does this user have manager role?
"""
# @ApiMember(Description="The read/write/delete access that the user has in the dashboard")
manager_access: Optional[UserManagerAccess] = None
"""
The read/write/delete access that the user has in the dashboard
"""
# @ApiMember(Description="The list of dashboard permissions for when the manager role is custom")
dashboard_permissions: Optional[List[DashboardPermissions]] = None
"""
The list of dashboard permissions for when the manager role is custom
"""
# @ApiMember(Description="The type of visibility this user has to their own fields")
my_field_permissions: Optional[UserDataFieldModes] = None
"""
The type of visibility this user has to their own fields
"""
# @ApiMember(Description="The type of visibility this user has to customer fields")
customer_field_permissions: Optional[UserDataFieldModes] = None
"""
The type of visibility this user has to customer fields
"""
# @ApiMember(Description="The type of visibility this user has to other user fields")
other_user_field_permissions: Optional[UserDataFieldModes] = None
"""
The type of visibility this user has to other user fields
"""
# @ApiMember(Description="The type of visibility this user has to other endpoint fields")
other_endpoint_field_permissions: Optional[UserDataFieldModes] = None
"""
The type of visibility this user has to other endpoint fields
"""
# @ApiMember(Description="The name of this endpoint (for bots etc.)")
name: Optional[str] = None
"""
The name of this endpoint (for bots etc.)
"""
# @ApiMember(Description="The list of tags for this endpoint")
tags: Optional[List[Tag]] = None
"""
The list of tags for this endpoint
"""
# @ApiMember(Description="The list of action URLs")
action_urls: Optional[List[EndpointActionUrl]] = None
"""
The list of action URLs
"""
# @ApiMember(Description="The list of members in this team")
team_member_ids: Optional[List[str]] = None
"""
The list of members in this team
"""
# @ApiMember(Description="Visibility of this user/team in contact lists")
contact_list_visibility: Optional[CustomerVisibility] = None
"""
Visibility of this user/team in contact lists
"""
# @ApiMember(Description="The list of contacts personal to this user")
contacts: Optional[List[EndpointContact]] = None
"""
The list of contacts personal to this user
"""
# @ApiMember(Description="The documo ID for this number")
documo_id: Optional[str] = None
"""
The documo ID for this number
"""
# @ApiMember(Description="Integration data for this endpoint")
integration_data: Optional[EntityIntegrationData] = None
"""
Integration data for this endpoint
"""
# @ApiMember(Description="Settings for third party phone system")
third_party_phone_system_settings: Optional[ThirdPartyPhoneSystemSettings] = None
"""
Settings for third party phone system
"""
# @ApiMember(Description="Should this user override the parent customer's app settings")
override_app_settings: bool = False
"""
Should this user override the parent customer's app settings
"""
# @ApiMember(Description="App / Portal settings for this user")
app_settings: Optional[AppSettings] = None
"""
App / Portal settings for this user
"""
# @ApiMember(Description="Configuration for the AI assistant")
assistant_settings: Optional[AssistantSettings] = None
"""
Configuration for the AI assistant
"""
# @ApiMember(Description="Configuration for the embed")
embed_settings: Optional[EmbedSettings] = None
"""
Configuration for the embed
"""
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AppGetUsers(ListRequest[EndpointInfo]):
account_id: Optional[str] = None
customer_id: Optional[str] = None
user_mode: Optional[UserModes] = None
name: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BillingItem:
base_cost: float = 0.0
raw_unit_multiplier: float = 0.0
unit_cost: float = 0.0
allowance: int = 0
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BillingSettings:
base: Optional[BillingItem] = None
local_numbers: Optional[BillingItem] = None
toll_free_numbers: Optional[BillingItem] = None
inbound_voice_calls: Optional[BillingItem] = None
outbound_voice_calls: Optional[BillingItem] = None
inbound_faxes: Optional[BillingItem] = None
outbound_faxes: Optional[BillingItem] = None
inbound_sms_messages: Optional[BillingItem] = None
outbound_sms_messages: Optional[BillingItem] = None
ai_insights: Optional[BillingItem] = None
ai_live_minutes: Optional[BillingItem] = None
ai_messages: Optional[BillingItem] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class AccountInfo(EntityInfo):
# @ApiMember(Description="The name of this account")
name: Optional[str] = None
"""
The name of this account
"""
# @ApiMember(Description="The ID of this account's parent")
parent_account_id: Optional[str] = None
"""
The ID of this account's parent
"""
# @ApiMember(Description="The twilio account SID")
twilio_account_sid: Optional[str] = None
"""
The twilio account SID
"""
# @ApiMember(Description="The ancestors of this account. Useful for breadcrumbs")
ancestor_ids: Optional[List[str]] = None
"""
The ancestors of this account. Useful for breadcrumbs
"""
# @ApiMember(Description="The max number of phone numbers this account can have")
max_phone_numbers: int = 0
"""
The max number of phone numbers this account can have
"""
# @ApiMember(Description="This account is BYOA")
is_b_y_o_a: bool = False
"""
This account is BYOA
"""
# @ApiMember(Description="TrustHub Profile Sid")
trust_hub_profile_sid: Optional[str] = None
"""
TrustHub Profile Sid
"""
# @ApiMember(Description="The ID of the logo file")
logo_id: Optional[str] = None
"""
The ID of the logo file
"""
# @ApiMember(Description="The URI of the logo file")
logo_uri: Optional[str] = None
"""
The URI of the logo file
"""
# @ApiMember(Description="The billing settings for this account")
billing_settings: Optional[BillingSettings] = None
"""
The billing settings for this account
"""
T = TypeVar('T')
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class ListResponse(Generic[T]):
# @ApiMember(Description="The items")
items: Optional[List[AccountInfo]] = None
"""
The items
"""
# @ApiMember(Description="The total number of items")
total_count: int = 0
"""
The total number of items
"""
# @ApiMember(Description="The total number of pages")
total_pages: int = 0
"""
The total number of pages
"""
# @ApiMember(Description="Are there more pages of items? Used with simplified paging")
has_more_pages: bool = False
"""
Are there more pages of items? Used with simplified paging
"""
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /portal/users HTTP/1.1 Host: evovoice.io Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
items:
[
{
accountId: String,
accountName: String,
customerId: String,
customerName: String,
referenceId: String,
customerBreadcrumb:
[
{
id: String,
name: String
}
],
displayName: String,
type: PhoneNumber,
extraInformation: String,
flowId: String,
flowName: String,
flowSchedule: Always,
schedule:
{
timeZoneId: String,
inherit: False,
forceClosed: False,
rules:
[
{
id: String,
name: String,
priority: 0,
state: String,
source: String,
condition: String,
simpleRuleType: Always,
customerState: String,
flowId: String,
isAllDay: False,
startDate: String,
startTime: String,
endTime: String,
bySetPosition:
[
0
],
byMonth:
[
0
],
byWeekNo:
[
0
],
byYearDay:
[
0
],
byMonthDay:
[
0
],
byDay:
[
{
offset: 0,
dayOfWeek: Sunday
}
],
byHour:
[
0
],
byMinute:
[
0
],
interval: 0,
count: 0,
untilDate: String,
frequency: None
}
],
defaultState: String
},
scheduledFlows:
[
{
stateName: String,
flowId: String
}
],
disableSms: False,
useExternal10DlcCampaign: False,
isVirtualPhoneNumber: False,
isCallerIdVerified: False,
callerIdVerificationCode: String,
phoneNumber: String,
phoneNumberSid: String,
callerIdName: String,
addressSid: String,
doNotTouchPhoneNumber: False,
isEnrolledIn10DlcService: False,
enableCallerIdLookup: False,
userEmailAddress: String,
sipRegion: NorthAmericaVirginia,
sipCredentialSid: String,
sipUserName: String,
sipPassword: String,
sipDomain: String,
enableEmergencyCalling: False,
emergencyAddressSid: String,
emergencyPhoneNumberId: String,
agentState: Unknown,
agentStateReason: Unknown,
userMode: SoftPhone,
voicemailGreetingId: String,
emailAddress: String,
userFirstName: String,
userLastName: String,
avatarUrl: String,
managerRole: None,
managerAccess: ReadOnly,
dashboardPermissions:
[
ViewFiles
],
myFieldPermissions: Hidden,
customerFieldPermissions: Hidden,
otherUserFieldPermissions: Hidden,
otherEndpointFieldPermissions: Hidden,
name: String,
tags:
[
{
id: String,
name: String,
color: Magenta
}
],
actionUrls:
[
{
id: String,
url: String,
method: GET
}
],
teamMemberIds:
[
String
],
contactListVisibility: None,
contacts:
[
{
id: String,
displayName: String,
address: String
}
],
documoId: String,
integrationData:
{
String:
{
thirdPartyId: String
}
},
thirdPartyPhoneSystemSettings:
{
type: Demo,
sipSettings:
{
accounts:
[
{
number: String,
agent: String,
authName: String,
userName: String,
displayName: String,
password: String,
userDomain: String,
registrationExpires: 0,
transportType: UDP,
localIP: String,
localPort: 0,
sipServer: String,
sipServerPort: 0,
outboundServer: String,
outboundServerPort: 0,
stunServer: String,
stunPort: 0,
audioPlaybackDeviceName: String,
audioRecordingDeviceName: String,
audioCodecs:
[
PCMU
],
dtmfMethod: RFC2833
}
]
},
demoSettings:
{
extension: String
}
},
overrideAppSettings: False,
appSettings:
{
enablePhoneNumberManagement: False,
enableDeviceManagement: False,
enableDialer: False,
enableCallHistory: False,
enableAssistants: False,
showFileNameInMessageCenter: False,
chakraTheme: String,
customCss: String,
pageTitle: String,
stringMappings: String,
logoutUrl: String,
portMyNumberUrl: String
},
assistantSettings:
{
companyName: String,
greeting: String,
companyInformation: String,
customPrompt: String,
voice: String,
voiceStyle: String,
tuning: Accuracy,
words:
[
{
word: String,
pronounced: String
}
],
links:
[
{
url: String,
description: String
}
],
contacts:
[
{
name: String,
phoneNumber: String,
transferType: Blind,
about: String,
emailAddress: String,
takeMessageFields:
[
{
name: String,
description: String,
required: False
}
]
}
],
integrations:
[
{
uri: String,
httpMethod: String,
authToken: String
}
]
},
embedSettings:
{
enabled: False,
allowedHosts: String
},
id: String,
dateCreated: String,
dateLastModified: String,
createdBy: String,
lastModifiedBy: String
}
],
totalCount: 0,
totalPages: 0,
hasMorePages: False
}