wxc_sdk.telephony.location package
- class wxc_sdk.telephony.location.CallingLineId(*, name: str | None = None, phoneNumber: str | None = None)[source]
Bases:
ApiModelLocation calling line information.
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
- name: str | None
Group calling line ID name. By default it will be org name. when updating the name make sure to also include the phone number
- phone_number: str | None
Directory Number / Main number in E164 Forma
- class wxc_sdk.telephony.location.PSTNConnection(*, type: RouteType, id: str)[source]
Bases:
ApiModelConnection details
Create a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
- id: str
A unique identifier of route type.
- class wxc_sdk.telephony.location.TelephonyLocation(*, id: str | None = None, name: str | None = None, announcementLanguage: str | None = None, callingLineId: CallingLineId | None = None, connection: PSTNConnection | None = None, externalCallerIdName: str | None = None, userLimit: int | None = None, pAccessNetworkInfo: str | None = None, outsideDialDigit: str | None = None, routingPrefix: str | None = None, defaultDomain: str | None = None, subscriptionStatus: str | None = None)[source]
Bases:
ApiModelCreate a new model by parsing and validating input data from keyword arguments.
Raises ValidationError if the input data cannot be parsed to form a valid model.
- location_id: str | None
A unique identifier for the location.
- name: str | None
The name of the location.
- announcement_language: str | None
Location’s phone announcement language.
- calling_line_id: CallingLineId | None
Location calling line information.
- connection: PSTNConnection | None
Connection details are only returned for local PSTN types of TRUNK or ROUTE_GROUP.
- external_caller_id_name: str | None
External Caller ID Name value. Unicode characters.
- user_limit: int | None
Limit on the number of people at the location, Read-Only.
- p_access_network_info: str | None
Location Identifier.
- outside_dial_digit: str | None
Must dial to reach an outside line, default is None.
- routing_prefix: str | None
Must dial a prefix when calling between locations having same extension within same location.
- default_domain: str | None
IP Address, hostname, or domain, Read-Only
- subscription_status: str | None
- class wxc_sdk.telephony.location.TelephonyLocationApi(session: wxc_sdk.rest.RestSession)[source]
Bases:
ApiChild- intercept: LocationInterceptApi
call intercept settings
- internal_dialing: InternalDialingApi
internal dialing settings
- moh: LocationMoHApi
moh settings
- number: LocationNumbersApi
number settings
- voicemail: LocationVoicemailSettingsApi
Location VM settings (only enable/disable transcription for now)
- receptionist_contacts_directory: ReceptionistContactsDirectoryApi
Receptionist contacts directories
- base = 'telephony/config/locations'
- generate_password(location_id: str, generate: list[str] | None = None, org_id: str | None = None)[source]
Generates an example password using the effective password settings for the location. If you don’t specify anything in the generate field or don’t provide a request body, then you will receive a SIP password by default.
It’s used while creating a trunk and shouldn’t be used anywhere else.
Generating an example password requires a full or write-only administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
location_id (str) – Location for which example password has to be generated.
generate (list[str]) – password settings array.
org_id (str) – Organization to which location belongs.
- Returns:
new password
- Return type:
str
- validate_extensions(location_id: str, extensions: list[str], org_id: str | None = None) ValidateExtensionsResponse[source]
Validate extensions for a specific location.
Validating extensions requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
location_id (str) – Validate extensions for this location.
extensions (list[str]) – Array of extensions that will be validated.
org_id (str) – Validate extensions for this organization.
- Returns:
Validation result
- Return type:
- details(location_id: str, org_id: str | None = None) TelephonyLocation[source]
Shows Webex Calling details for a location, by ID.
Specify the location ID in the locationId parameter in the URI.
Searching and viewing location in your organization requires an administrator auth token with the spark-admin:telephony_config_read scope.
- Parameters:
location_id (str) – Retrieve Webex Calling location attributes for this location.
org_id (str) – Retrieve Webex Calling location attributes for this organization.
- Returns:
Webex Calling details for location
- Return type:
- update(location_id: str, settings: TelephonyLocation, org_id: str | None = None)[source]
Update Webex Calling details for a location, by ID.
Specify the location ID in the locationId parameter in the URI.
Modifying the connection via API is only supported for the local PSTN types of TRUNK and ROUTE_GROUP.
Updating a location in your organization requires an administrator auth token with the spark-admin:telephony_config_write scope.
Example :
api.telephony.location.update(location_id=location_id, settings=TelephonyLocation( calling_line_id=CallingLineId( phone_number=tn), routing_prefix=routing_prefix, outside_dial_digit='9'))
- Parameters:
location_id (str) – Updating Webex Calling location attributes for this location.
settings (
TelephonyLocation) – settings to updateorg_id (str) – Updating Webex Calling location attributes for this organization.
- Returns:
- change_announcement_language(location_id: str, language_code: str, agent_enabled: bool | None = None, service_enabled: bool | None = None, org_id: str | None = None)[source]
Change Announcement Language
Change announcement language for the given location.
Change announcement language for current people/workspaces and/or existing feature configurations. This does not change the default announcement language which is applied to new users/workspaces and new feature configurations.
Changing announcement language for the given location requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
location_id (str) – Change announcement language for this location.
language_code (str) – Language code.
agent_enabled (bool) – Set to true to change announcement language for existing people and workspaces.
service_enabled (bool) – Set to true to change announcement language for existing feature configurations.
org_id (str) – Change announcement language for this organization.
- device_settings(location_id: str, org_id: str | None = None) DeviceCustomization[source]
Get device override settings for a location.
This requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
location_id (str) – Unique identifier for the location
org_id (str) – Settings on the device in this organization
- Returns:
device customization response
- Return type:
Submodules
- wxc_sdk.telephony.location.intercept module
- wxc_sdk.telephony.location.internal_dialing module
- wxc_sdk.telephony.location.moh module
- wxc_sdk.telephony.location.numbers module
- wxc_sdk.telephony.location.receptionist_contacts module
- wxc_sdk.telephony.location.vm module