wxc_sdk.telephony.devices package
Telephony devices
- class wxc_sdk.telephony.devices.DeviceManufacturer(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- cisco = 'CISCO'
- third_party = 'THIRD_PARTY'
- class wxc_sdk.telephony.devices.DeviceManagedBy(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- cisco = 'CISCO'
- customer = 'CUSTOMER'
- partner = 'PARTNER'
- class wxc_sdk.telephony.devices.OnboardingMethod(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- mac_address = 'MAC_ADDRESS'
- activation_code = 'ACTIVATION_CODE'
- no_method = 'NONE'
- class wxc_sdk.telephony.devices.DeviceSettingsConfiguration(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- webex_calling_device_configuration = 'WEBEX_CALLING_DEVICE_CONFIGURATION'
Devices which supports Webex Calling Device Settings Configuration.
- webex_device_configuration = 'WEBEX_DEVICE_CONFIGURATION'
Devices which supports Webex Device Settings Configuration.
- webex_calling_dynamic_device_configuration = 'WEBEX_CALLING_DYNAMIC_DEVICE_CONFIGURATION'
Devices which supports Webex Calling dynamic Settings Configuration.
- none_ = 'NONE'
Devices does not support any configuration.
- class wxc_sdk.telephony.devices.SupportsLogCollection(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- none_ = 'NONE'
Devices which does not support log collection.
- cisco_prt = 'CISCO_PRT'
Devices which supports Cisco PRT log collection.
- cisco_roomos = 'CISCO_ROOMOS'
Devices which supports Cisco RoomOS log collection.
- class wxc_sdk.telephony.devices.SupportedDevice(*, model: str, displayName: str, familyDisplayName: str | None = None, type: DeviceType, manufacturer: DeviceManufacturer, managedBy: DeviceManagedBy, supportedFor: list[UserType], onboardingMethod: list[OnboardingMethod], allowConfigureLayoutEnabled: bool, numberOfLinePorts: int, kemSupportEnabled: bool, kemModuleCount: int | None = None, kemLinesSupportEnabled: bool | None = None, kemModuleType: list[str] | None = None, upgradeChannelEnabled: bool | None = None, defaultUpgradeChannel: str | None = None, additionalPrimaryLineAppearancesEnabled: bool | None = None, additionalSecondaryLineAppearancesEnabled: bool | None = None, basicEmergencyNomadicEnabled: bool | None = None, customizedBehaviorsEnabled: bool | None = None, allowConfigurePortsEnabled: bool | None = None, customizableLineLabelEnabled: bool | None = None, supportsLinePortReorderingEnabled: bool | None = None, portNumberSupportEnabled: bool | None = None, t38Enabled: bool | None = None, callDeclinedEnabled: bool | None = None, touchScreenPhone: bool | None = None, numberOfLineKeyButtons: int | None = None, deviceSettingsConfiguration: DeviceSettingsConfiguration | None = None, numberOfPrimaryDisplayConfiguredLines: int | None = None, allowHotelingHostEnabled: bool | None = None, supportsLogCollection: SupportsLogCollection | None = None, supportsApplyChangesEnabled: bool | None = None, allowConfigureLinesEnabled: bool | None = None, allowConfigurePhoneSettingsEnabled: bool | None = None, supportsHotlineEnabled: bool | None = None, supportsHotDeskOnly: bool | None = None, maxNumberOfLineAppearances: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- model: str
Model name of the device.
- display_name: str
Display name of the device.
- family_display_name: str | None
The display name of the device family.
- device_type: DeviceType
Type of the device.
- manufacturer: DeviceManufacturer
Manufacturer of the device.
- managed_by: DeviceManagedBy
Users who manage the device.
- onboarding_method: list[OnboardingMethod]
Onboarding method.
- allow_configure_layout_enabled: bool
Enables / Disables layout configuration for devices.
- number_of_line_ports: int
Number of port lines.
- kem_support_enabled: bool
Indicates whether Kem support is enabled or not.
- kem_module_count: int | None
Module count.
- kem_lines_support_enabled: bool | None
Enables / disables Kem lines support.
- kem_module_type: list[str] | None
Key expansion module type of the device.
- upgrade_channel_enabled: bool | None
Enables / Disables the upgrade channel.
- default_upgrade_channel: str | None
The default upgrade channel.
- additional_primary_line_appearances_enabled: bool | None
Enables / disables the additional primary line appearances.
- additional_secondary_line_appearances_enabled: bool | None
Enables / disables the additional shared line appearances.
- basic_emergency_nomadic_enabled: bool | None
Enables / disables Basic emergency nomadic.
- customized_behaviors_enabled: bool | None
Enables / disables customized behavior support on devices
- allow_configure_ports_enabled: bool | None
Enables / disables configuring port support on device.
- customizable_line_label_enabled: bool | None
Enables / disables customizable line label.
- supports_line_port_reordering_enabled: bool | None
Enables / disables support line port reordering.
- port_number_support_enabled: bool | None
Enables / disables port number support.
- t38_enabled: bool | None
Enables / disables T.38.
- call_declined_enabled: bool | None
Enables / disables call declined.
- touch_screen_phone: bool | None
Supports touch screen on device.
- number_of_line_key_buttons: int | None
Number of line key buttons for a device.
- device_settings_configuration: DeviceSettingsConfiguration | None
Device settings configuration.
- number_of_primary_display_configured_lines: int | None
- allow_hoteling_host_enabled: bool | None
Enables / disables hoteling host.
- supports_log_collection: SupportsLogCollection | None
Device log collection configuration.
- supports_apply_changes_enabled: bool | None
Enables / disables apply changes.
- allow_configure_lines_enabled: bool | None
Enables / disables configure lines.
- allow_configure_phone_settings_enabled: bool | None
Enables / disables configure phone settings.
- supports_hotline_enabled: bool | None
Enables / disables hotline support.
- supports_hot_desk_only: bool | None
Supports hot desk only.
- max_number_of_line_appearances: int | None
- class wxc_sdk.telephony.devices.SupportedDevices(*, upgradeChannelList: list[str] | None = None, devices: list[SupportedDevice] | None = None, **extra_data: Any)[source]
Bases:
ApiModel- upgrade_channel_list: list[str] | None
List of available upgrade channels. * STABLE - These are standard stable releases. * STABLE_DELAY - These are delayed stable releases. * PREVIEW - These are Preview/pre-release versions. * BETA - These are Beta testing versions. * TESTING - These are testing versions.
- devices: list[SupportedDevice] | None
List of supported devices.
- class wxc_sdk.telephony.devices.MemberCommon(*, id: str = None, memberType: ~wxc_sdk.common.UserType = <UserType.people: 'PEOPLE'>, firstName: str | None = None, lastName: str | None = None, phoneNumber: ~typing.Annotated[str, ~pydantic.functional_validators.BeforeValidator(func=~wxc_sdk.base.e164, json_schema_input_type=PydanticUndefined)] | None = None, extension: str | None = None, routingPrefix: str | None = None, esn: str | None = None, t38FaxCompressionEnabled: bool | None = None, lineType: ~wxc_sdk.common.PrimaryOrShared = <PrimaryOrShared.primary: 'PRIMARY'>, allowCallDeclineEnabled: bool | None = True, location: ~wxc_sdk.common.IdAndName | None = None, licenseType: ~wxc_sdk.common.UserLicenseType | None = None, **extra_data: ~typing.Any)[source]
Bases:
ApiModel- member_id: str
Unique identifier for the member.
- first_name: str | None
First name of a person or workspace.
- last_name: str | None
Last name of a person or workspace.
- phone_number: Annotated[str, BeforeValidator(func=e164, json_schema_input_type=PydanticUndefined)] | None
Phone Number of a person or workspace. In some regions phone numbers are not returned in E.164 format. This will be supported in a future update.
- extension: str | None
Extension of a person or workspace.
- routing_prefix: str | None
Routing prefix of location.
- esn: str | None
Routing prefix + extension of a person or workspace.
- t38_fax_compression_enabled: bool | None
T.38 Fax Compression setting and is available only for ATA Devices. Choose T.38 fax compression if the device requires this option. This will override user level compression options.
- line_type: PrimaryOrShared
Line type is used to differentiate Primary and SCA, at which endpoint it is assigned.
- allow_call_decline_enabled: bool | None
Set how a person’s device behaves when a call is declined. When set to true, a call decline request is extended to all the endpoints on the device. When set to false, a call decline request only declines the current endpoint.
- license_type: UserLicenseType | None
- class wxc_sdk.telephony.devices.DeviceMember(*, id: str = None, memberType: ~wxc_sdk.common.UserType = <UserType.people: 'PEOPLE'>, firstName: str | None = None, lastName: str | None = None, phoneNumber: ~typing.Annotated[str, ~pydantic.functional_validators.BeforeValidator(func=~wxc_sdk.base.e164, json_schema_input_type=PydanticUndefined)] | None = None, extension: str | None = None, routingPrefix: str | None = None, esn: str | None = None, t38FaxCompressionEnabled: bool | None = None, lineType: ~wxc_sdk.common.PrimaryOrShared = <PrimaryOrShared.primary: 'PRIMARY'>, allowCallDeclineEnabled: bool | None = True, location: ~wxc_sdk.common.IdAndName | None = None, licenseType: ~wxc_sdk.common.UserLicenseType | None = None, primaryOwner: bool = False, port: int = 1, lineWeight: int = 1, lineLabel: str | None = None, hostIP: str | None = None, remoteIP: str | None = None, hotlineEnabled: bool = False, hotlineDestination: str | None = None, **extra_data: ~typing.Any)[source]
Bases:
MemberCommon- primary_owner: bool
This field indicates whether the person or the workspace is the owner of the device, and points to a primary Line/Port of the device.
- port: int
Port number assigned to person or workspace.
- line_weight: int
Number of lines that have been configured for the person on the device. Can only be larger than one for primary owner
- line_label: str | None
Device line label.
- host_ip: str | None
Registration Host IP address for the line port.
- remote_ip: str | None
Registration Remote IP address for the line port.
- hotline_enabled: bool
Enable Hotline. Configure this line to automatically call a predefined number whenever taken off-hook. Once enabled, the line can only make calls to the predefined number set in hotlineDestination.
- hotline_destination: str | None
The preconfigured number for Hotline. Required only if hotlineEnabled is set to true.
- static from_available(available: AvailableMember) DeviceMember[source]
- class wxc_sdk.telephony.devices.DeviceMembersResponse(*, model: str, members: list[DeviceMember], maxLineCount: int, **extra_data: Any)[source]
Bases:
ApiModelGet Device Members response
- model: str
- members: list[DeviceMember]
- max_line_count: int
- class wxc_sdk.telephony.devices.AvailableMember(*, id: str = None, memberType: ~wxc_sdk.common.UserType = <UserType.people: 'PEOPLE'>, firstName: str | None = None, lastName: str | None = None, phoneNumber: ~typing.Annotated[str, ~pydantic.functional_validators.BeforeValidator(func=~wxc_sdk.base.e164, json_schema_input_type=PydanticUndefined)] | None = None, extension: str | None = None, routingPrefix: str | None = None, esn: str | None = None, t38FaxCompressionEnabled: bool | None = None, lineType: ~wxc_sdk.common.PrimaryOrShared = <PrimaryOrShared.primary: 'PRIMARY'>, allowCallDeclineEnabled: bool | None = True, location: ~wxc_sdk.common.IdAndName | None = None, licenseType: ~wxc_sdk.common.UserLicenseType | None = None, **extra_data: ~typing.Any)[source]
Bases:
MemberCommon
- class wxc_sdk.telephony.devices.MACState(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumState of the MAC address.
- available = 'AVAILABLE'
The requested MAC address is available.
The requested MAC address is unavailable.
- duplicate_in_list = 'DUPLICATE_IN_LIST'
The requested MAC address is duplicated.
- invalid = 'INVALID'
The requested MAC address is invalid.
- class wxc_sdk.telephony.devices.MACStatus(*, mac: str, state: MACState, errorCode: int | None = None, message: str | None = None, **extra_data: Any)[source]
Bases:
ApiModel- mac: str
MAC address.
- error_code: int | None
MAC address validation error code.
- message: str | None
Provides a status message about the MAC address.
- class wxc_sdk.telephony.devices.MACValidationResponse(*, status: ValidationStatus, macStatus: list[MACStatus] | None = None, **extra_data: Any)[source]
Bases:
ApiModel- status: ValidationStatus
Status of MAC address.
- class wxc_sdk.telephony.devices.TelephonyDevicesApi(session: RestSession)[source]
Bases:
ApiChildTelephony devices API
- __init__(session: RestSession)[source]
- dynamic_settings: DevicesDynamicSettingsApi
- supported_devices(allow_configure_layout_enabled: bool | None = None, type_: str | None = None, org_id: str | None = None) SupportedDevices[source]
Read the List of Supported Devices
Gets the list of supported devices for an organization.
Retrieving this list requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
allow_configure_layout_enabled (bool) – List supported devices that allow the user to configure the layout.
type (str) – List supported devices of a specific type. To excluded device types from a request or query, add type=not:DEVICE_TYPE. For example, type=not:MPP.
org_id (str) – List supported devices for an organization.
- Return type:
- details(device_id: str, org_id: str | None = None) TelephonyDeviceDetails[source]
Get Webex Calling Device Details
Not supported for Webex for Government (FedRAMP)
Retrieves Webex Calling device details that include information needed for third-party device management.
Webex calling devices are associated with a specific user Workspace or Virtual Line. Webex Calling devices share the location with the entity that owns them.
Person or workspace to which the device is assigned. Its fields point to a primary line/port of the device.
Requires a full, location, user, or read-only admin auth token with the scope of spark-admin:telephony_config_read.
- Parameters:
device_id (str) – Unique identifier for the device.
org_id (str) – ID of the organization in which the device resides.
- Return type:
- update_third_party_device(device_id: str, sip_password: str, org_id: str | None = None)[source]
Update Third Party Device
Not supported for Webex for Government (FedRAMP)
Modify a device’s sipPassword.
Updating sipPassword on the device requires a full or user administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
device_id (str) – Unique identifier for the device.
sip_password (str) – Password to be updated.
org_id (str) – ID of the organization in which the device resides.
- Return type:
None
- members(device_id: str, org_id: str | None = None) DeviceMembersResponse[source]
Get Device Members
Get the list of all the members of the device including primary and secondary users.
A device member can be either a person or a workspace. An admin can access the list of member details, modify member details and search for available members on a device.
Retrieving this list requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
device_id (str) – Unique identifier for the device.
org_id (str) – Retrieves the list of all members of the device in this Organization.
- Returns:
Device model, line count, and members
- Return type:
- update_members(device_id: str, members: list[DeviceMember | AvailableMember] | None = None, org_id: str | None = None)[source]
Modify member details on the device.
A device member can be either a person or a workspace. An admin can access the list of member details, modify member details and search for available members on a device.
Modifying members on the device requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
device_id (str) – Unique identifier for the device.
members (list[Union[DeviceMember, AvailableMember]) – New member details for the device. If the member’s list is missing then all the users are removed except the primary user.
org_id (str) – Modify members on the device in this organization.
- available_members(device_id: str, location_id: str | None = None, member_name: str | None = None, phone_number: str | None = None, extension: str | None = None, org_id: str | None = None, usage_type: UsageType | None = None, order: str | None = None, **params) Generator[AvailableMember, None, None][source]
Search members that can be assigned to the device.
A device member can be either a person or a workspace. A admin can access the list of member details, modify member details and search for available members on a device.
This requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
device_id (str) – Unique identifier for the device.
location_id (str) – Search (Contains) based on number.
member_name (str) – Search (Contains) numbers based on member name.
phone_number (str) – Search (Contains) based on number.
extension (str) – Search (Contains) based on extension.
usage_type (UsageType) – Search for members eligible to become the owner of the device, or share line on the device.
order (str) – Sort the list of available members on the device in ascending order by name, use either last name lname or first name fname. Default: last name in ascending order.
org_id (str) – Retrieves the list of available members on the device in this Organization.
- Returns:
list of available members
- get_count_of_members(device_id: str, member_name: str | None = None, phone_number: str | None = None, location_id: str | None = None, extension: str | None = None, usage_type: UsageType | None = None, org_id: str | None = None) int[source]
Get Count of Members
Get the count of members that can be assigned to the device.
A device member can be either a person or a workspace.
This requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
device_id (str) – Unique identifier for the device.
member_name (str) – Search (Contains) numbers based on member name.
phone_number (str) – Search (Contains) based on number.
location_id (str) – Unique identifier for the location.
extension (str) – Search (Contains) based on extension.
usage_type – Search for members eligible to become the owner of the device, or share line on the device.
DEVICE_OWNER - Search for members eligible to become the owner of the device.
SHARED_LINE - Search for members eligible to share line on the device.
- Parameters:
org_id (str) – Retrieves the count of available members on the device in this organization.
- Return type:
int
- apply_changes(device_id: str, org_id: str | None = None)[source]
Apply Changes for a specific device
Issues request to the device to download and apply changes to the configuration.
Applying changes for a specific device requires a full administrator auth token with a scope of spark-admin:telephony_config_write. :param device_id: Unique identifier for the device. :type device_id: str :param org_id: Apply changes for a device in this Organization. :type org_id: str
- device_settings(device_id: str, device_model: str | None = None, org_id: str | None = None) DeviceCustomization[source]
Get override settings for a device.
Device settings lists all the applicable settings for an MPP and an ATA devices at the device level. An admin can also modify the settings. DECT devices do not support settings at the device level.
This requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
device_id (str) – Unique identifier for the device.
device_model (str) – The model type of the device. The corresponding device model display name sometimes called the product name, can also be used to specify the model.
org_id (str) – Settings on the device in this organization.
- Returns:
Device settings
- Return type:
- update_device_settings(device_id: str, device_model: str, customization: DeviceCustomization, org_id: str | None = None)[source]
Modify override settings for a device.
Device settings list all the applicable settings for an MPP and an ATA devices at the device level. Admins can also modify the settings. NOTE: DECT devices do not support settings at the device level.
Updating settings on the device requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
device_id (str) – Unique identifier for the device.
device_model (str) – Device model name.
customization (DeviceCustomization) – Indicates the customization object of the device settings.
org_id (str) – Organization in which the device resides..
Example :
# target_device is a TelephonyDevice object target_device: TelephonyDevice # get device level settings settings = api.telephony.devices.device_settings(device_id=target_device.device_id, device_model=target_device.model) # update settings (display name format) and enable device level customization settings.customizations.mpp.display_name_format = DisplayNameSelection.person_last_then_first_name settings.custom_enabled = True # update the device level settings api.telephony.devices.update_device_settings(device_id=target_device.device_id, device_model=target_device.model, customization=settings) # apply changes to device api.telephony.devices.apply_changes(device_id=target_device.device_id)
- get_count_of_available_members(member_name: str | None = None, phone_number: str | None = None, location_id: str | None = None, extension: str | None = None, usage_type: UsageType | None = None, exclude_virtual_line: bool | None = None, device_location_id: str | None = None, org_id: str | None = None) int[source]
Get Count of Available Members
Get the count of members that can be assigned to devices.
A device member can be either a person or a workspace.
This requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
member_name (str) – Search (Contains) numbers based on member name.
phone_number (str) – Search (Contains) based on number.
location_id (str) – Unique identifier for the location.
extension (str) – Search (Contains) based on extension.
usage_type – Search for members eligible to become the owner of the device, or share line on the device.
DEVICE_OWNER - Search for members eligible to become the owner of the device.
SHARED_LINE - Search for members eligible to share line on the device.
- Parameters:
exclude_virtual_line (bool) – If true, filters out virtual lines from the available members list.
device_location_id (str) – Unique identifier for the device’s location. When specified, filters available members to those in the same location as the device.
org_id (str) – Retrieves the count of available members in this organization.
- Return type:
int
- validate_macs(macs: list[str], org_id: str | None = None) MACValidationResponse[source]
Validate a list of MAC addresses.
Validating this list requires a full or read-only administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
macs (list[str]) – MAC addresses to be validated.
org_id (str) – Validate the mac address(es) for this organization.
- Returns:
validation response
- Return type:
- create_line_key_template(template: LineKeyTemplate, org_id: str | None = None) str[source]
Create a Line Key Template
Create a Line Key Template in this organization.
Line Keys, also known as Programmable Line Keys (PLK) are the keys found on either sides of a typical desk phone display. A Line Key Template is a definition of actions that will be performed by each of the Line Keys for a particular device model. This API allows customers to create a Line Key Template for a device model.
Creating a Line Key Template requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
template (LineKeyTemplate) – Line key template to create
org_id (str) – id of organization to create the line key template in
- Returns:
id of new line key template
- Return type:
str
- list_line_key_templates(org_id: str | None = None) list[LineKeyTemplate][source]
Read the list of Line Key Templates
List all Line Key Templates available for this organization.
Line Keys, also known as Programmable Line Keys (PLK) are the keys found on either sides of a typical desk phone display. A Line Key Template is a definition of actions that will be performed by each of the Line Keys for a particular device model. This API allows users to retrieve the list of Line Key Templates that are available for the organization.
Retrieving this list requires a full, user or read-only administrator or location administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
org_id (str) – List line key templates for this organization.
- Return type:
list[LineKeyTemplate]
- line_key_template_details(template_id: str, org_id: str | None = None) LineKeyTemplate[source]
Get details of a Line Key Template
Get detailed information about a Line Key Template by template ID in an organization.
Line Keys, also known as Programmable Line Keys (PLK) are the keys found on either sides of a typical desk phone display. A Line Key Template is a definition of actions that will be performed by each of the Line Keys for a particular device model. This API allows users to retrieve a line key template by its ID in an organization.
Retrieving a line key template requires a full, user or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
template_id (str) – Get line key template for this template ID.
org_id (str) – Retrieve a line key template for this organization.
- Return type:
GetLineKeyTemplateResponse
- modify_line_key_template(template: LineKeyTemplate, org_id: str | None = None)[source]
Modify a Line Key Template
Modify a line key template by its template ID in an organization.
Line Keys, also known as Programmable Line Keys (PLK) are the keys found on either sides of a typical desk phone display. A Line Key Template is a definition of actions that will be performed by each of the Line Keys for a particular device model. This API allows users to modify an existing Line Key Template by its ID in an organization.
Modifying an existing line key template requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
template (LineKeyTemplate) – new line key template settings
org_id (str) – Modify a line key template for this organization.
- delete_line_key_template(template_id: str, org_id: str | None = None)[source]
Delete a Line Key Template
Delete a Line Key Template by its template ID in an organization.
Line Keys, also known as Programmable Line Keys (PLK) are the keys found on either sides of a typical desk phone display. A Line Key Template is a definition of actions that will be performed by each of the Line Keys for a particular device model. This API allows users to delete an existing Line Key Templates by its ID in an organization.
Deleting an existing line key template requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
template_id (str) – Delete line key template with this template ID.
org_id (str) – Delete a line key template for this organization.
- Return type:
None
- preview_apply_line_key_template(action: ApplyLineKeyTemplateAction, template_id: str | None = None, location_ids: list[str] | None = None, exclude_devices_with_custom_layout: bool | None = None, include_device_tags: list[str] | None = None, exclude_device_tags: list[str] | None = None, advisory_types: LineKeyTemplateAdvisoryTypes | None = None, org_id: str | None = None) int[source]
Preview Apply Line Key Template
Preview the number of devices that will be affected by the application of a Line Key Template or when resetting devices to their factory Line Key settings.
Line Keys, also known as Programmable Line Keys (PLK) are the keys found on either sides of a typical desk phone display. A Line Key Template is a definition of actions that will be performed by each of the Line Keys for a particular device model. This API allows users to preview the number of devices that will be affected if a customer were to apply a Line Key Template or apply factory default Line Key settings to devices.
Retrieving the number of devices affected requires a full administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
action (PostApplyLineKeyTemplateRequestAction) – Line key Template action to perform.
template_id (str) – templateId is required for APPLY_TEMPLATE action.
location_ids (list[str]) – Used to search for devices only in the given locations.
exclude_devices_with_custom_layout (bool) – Indicates whether to exclude devices with custom layout.
include_device_tags (list[str]) – Include devices only with these tags.
exclude_device_tags (list[str]) – Exclude devices with these tags.
advisory_types (LineKeyTemplateAdvisoryTypes) – Refine search with advisories.
org_id (str) – Preview Line Key Template for this organization.
- Return type:
int
- get_device_layout(device_id: str, org_id: str | None = None) DeviceLayout[source]
Get Device Layout by Device ID
Get layout information of a device by device ID in an organization.
Device layout customizes a user’s programmable line keys (PLK) on the phone and any attached Key Expansion Modules (KEM) with the existing configured line members and the user’s monitoring list.
This API requires a full or location administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
device_id (str) – Get device layout for this device ID.
org_id (str) – Retrieve a device layout for the device in this organization.
- Return type:
- modify_device_layout(device_id: str, layout: DeviceLayout, org_id: str | None = None)[source]
Modify Device Layout by Device ID
Modify the layout of a device by device ID in an organization.
Device layout customizes a user’s programmable line keys (PLK) on the phone and any attached Key Expansion Modules (KEM) with the existing configured line members and the user’s monitoring list.
This API requires a full or location administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
device_id (str) – Modify device layout for this device ID.
layout – New layout
org_id (str) – Modify a device layout for the device in this organization.
- Return type:
None
- get_person_device_settings(person_id: str, org_id: str | None = None) DeviceSettings[source]
Get Device Settings for a Person
Device settings list the compression settings for a person.
Device settings customize a device’s behavior and performance. The compression field optimizes call quality for inbound and outbound calls.
This API requires a full, location, user, or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
person_id (str) – ID of the person to retrieve device settings.
org_id (str) – Retrieves the device settings for a person in this organization.
- Return type:
Compression
- update_person_device_settings(person_id: str, settings: DeviceSettings, org_id: str | None = None)[source]
Update Device Settings for a Person
Update device settings modifies the compression settings for a person.
Device settings customize a device’s behavior and performance. The compression field optimizes call quality for inbound and outbound calls.
This API requires a full, location, or user administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
person_id (str) – ID of the person to update device settings.
settings (DeviceSettings) – New device settings
org_id (str) – Modify device settings for a person in this organization.
- Return type:
None
- get_workspace_device_settings(workspace_id: str, org_id: str | None = None) DeviceSettings[source]
Get Device Settings for a Workspace
Device settings list the compression settings for a workspace.
Device settings customize a device’s behavior and performance. The compression field optimizes call quality for inbound and outbound calls.
This API requires a full, location, user, or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
workspace_id (str) – ID of the workspace for which to retrieve device settings.
org_id (str) – Retrieves the device settings for a workspace in this organization.
- Return type:
Compression
- update_workspace_device_settings(workspace_id: str, settings: DeviceSettings, org_id: str | None = None)[source]
Update Device Settings for a Workspace
Update device settings modifies the compression settings for a workspace.
Device settings customize a device’s behavior and performance. The compression field optimizes call quality for inbound and outbound calls.
This API requires a full, location, or user administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
workspace_id (str) – ID of the workspace for which to update device settings.
settings (DeviceSettings) – New device settings
org_id (str) – Modify the device settings for a workspace in this organization.
- Return type:
None
- list_background_images(org_id: str | None = None) BackgroundImages[source]
Read the List of Background Images
Gets the list of device background images for an organization.
Webex Calling supports the upload of up to 100 background image files for each org. These image files can then be referenced by MPP phones in that org for use as their background image.
Retrieving this list requires a full, device, or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
org_id (str) – Retrieves the list of images in this organization.
- Return type:
- upload_background_image(device_id: str, file: BufferedReader | str, file_name: str | None = None, org_id: str | None = None) BackgroundImage[source]
Upload a Device Background Image
Configure a device’s background image by uploading an image with file format, .jpeg or .png, encoded image file. Maximum image file size allowed to upload is 625 KB.
The request must be a multipart/form-data request rather than JSON, using the image/jpeg or image/png content-type.
Webex Calling supports the upload of up to 100 background image files for each org. These image files can then be referenced by MPP phones in that org for use as their background image.
Uploading a device background image requires a full or device administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
device_id (str) – Unique identifier for the device.
file (Union[BufferedReader, str]) – the file to be uploaded, can be a path to a file or a buffered reader (opened file); if a reader referring to an open file is passed then make sure to open the file as binary b/c otherwise the content length might be calculated wrong
file_name (str) – filename for the content. Only required if content is a reader
org_id (str) – Uploads the image in this organization.
- Return type:
- delete_background_images(background_images: list[DeleteImageRequestObject], org_id: str | None = None) DeleteDeviceBackgroundImagesResponse[source]
Delete Device Background Images
Delete the list of designated device background images for an organization. Maximum is 10 images per request.
Deleting a device background image requires a full or device administrator auth token with a scope of spark-admin:telephony_config_write.
- Parameters:
background_images (list[DeleteImageRequestObject]) – Array of images to be deleted.
org_id (str) – Deletes the list of images in this organization.
- Return type:
- base = 'telephony/config'
- user_devices_count(person_id: str, org_id: str | None = None) UserDeviceCount[source]
Get User Devices Count
Get the total device and application count for a person.
The device count can be used to determine if more devices can be added for users with a device count limit. For example, users with standard calling licenses can only have one physical device.
This requires a full or read-only administrator or location administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
person_id (str) – Person for whom to retrieve the device count.
org_id (str) – Organization to which the person belongs.
- Return type:
- class wxc_sdk.telephony.devices.LineKeyType(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- primary_line = 'PRIMARY_LINE'
PRIMARY_LINE is the user’s primary extension. This is the default assignment for Line Key Index 1 and cannot be modified.
Shows the appearance of other users on the owner’s phone.
- monitor = 'MONITOR'
Enables User and Call Park monitoring.
- call_park_extension = 'CALL_PARK_EXTENSION'
Enables the configure layout feature in Control Hub to set call park extension implicitly.
- speed_dial = 'SPEED_DIAL'
Allows users to reach a telephone number, extension or a SIP URI.
- open = 'OPEN'
An open key will automatically take the configuration of a monitor button starting with the first open key. These buttons are also usable by the user to configure speed dial numbers on these keys.
- closed = 'CLOSED'
Button not usable but reserved for future features.
- mode_management = 'MODE_MANAGEMENT'
Allows users to manage call forwarding for features via schedule-based routing.
- class wxc_sdk.telephony.devices.ProgrammableLineKey(*, lineKeyIndex: int | None = None, lineKeyType: LineKeyType | None = None, lineKeyLabel: str | None = None, lineKeyValue: str | None = None, sharedLineIndex: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- line_key_index: int | None
An index representing a Line Key. Index starts from 1 representing the first key on the left side of the phone.
- line_key_type: LineKeyType | None
The action that would be performed when the Line Key is pressed.
- line_key_label: str | None
This is applicable only when the lineKeyType is SPEED_DIAL.
- line_key_value: str | None
Applicable only when the lineKeyType is SPEED_DIAL. Value must be a valid telephone number, ext, or SIP URI (format: user@host using A-Z,a-z,0-9,-_ .+ for user and host).
Shared line index is the line label number of the shared or virtual line assigned in the configured lines. Since you can add multiple appearances of the same shared or virtual line on a phone, entering the index number assigns the respective line to a line key. This is applicable only when the lineKeyType is SHARED_LINE, If multiple programmable line keys are configured as shared lines, and If the sharedLineIndex is sent for any of the shared line, then the sharedLineIndex should be sent for all other shared lines. When lineKeyType is SHARED_LINE and sharedLineIndex is not assigned to any of the configured lines, then sharedLineIndex is assigned by default in the order the shared line appears in the request.
- classmethod standard_plk_list(lines: int = 10) list[ProgrammableLineKey][source]
get a standard list of programmable line keys of given length. 1st line key is primary line and all other are “open”
- Parameters:
lines – number of programmable line keys
- Returns:
list of programmable line keys
- class wxc_sdk.telephony.devices.LineKeyTemplate(*, id: str | None = None, templateName: str | None = None, deviceModel: str | None = None, modelDisplayName: str | None = None, userReorderEnabled: bool | None = None, lineKeys: list[ProgrammableLineKey] | None = None, **extra_data: Any)[source]
Bases:
ApiModel- id: str | None
Unique identifier for the Line Key Template
- template_name: str | None
Name of the Line Key Template
- device_model: str | None
The Device Model for which the Line Key Template is applicable
- display_name: str | None
The friendly display name used to represent the device model in Control Hub
- user_reorder_enabled: bool | None
Indicates whether user can reorder the line keys.
- line_keys: list[ProgrammableLineKey] | None
Contains a mapping of Line Keys and their corresponding actions.
- class wxc_sdk.telephony.devices.TelephonyDeviceDetails(*, manufacturer: str | None = None, managedBy: str | None = None, id: str | None = None, ip: str | None = None, mac: str | None = None, model: str | None = None, activationState: ActivationState | None = None, description: list[str] | None = None, upgradeChannelEnabled: bool | None = None, owner: TelephonyDeviceOwner | None = None, proxy: TelephonyDeviceProxy | None = None, **extra_data: Any)[source]
Bases:
ApiModel- manufacturer: str | None
Manufacturer of the device.
- managed_by: str | None
Device manager(s).
- id: str | None
A unique identifier for the device.
- ip: str | None
The current IP address of the device.
- mac: str | None
The unique address for the network adapter.
- model: str | None
A model type of the device.
- activation_state: ActivationState | None
Activation state of the device. This field is only populated for a device added by a unique activation code generated by Control Hub for use with Webex.
- description: list[str] | None
Comma-separated array of tags used to describe the device.
- upgrade_channel_enabled: bool | None
Enabled / disabled status of the upgrade channel.
- owner: TelephonyDeviceOwner | None
- proxy: TelephonyDeviceProxy | None
- class wxc_sdk.telephony.devices.ActivationState(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- activating = 'activating'
Indicates a device is activating using an activation code.
- activated = 'activated'
Indicates a device has been activated using an activation code.
- deactivated = 'deactivated'
Indicates a device has not been activated using an activation code.
- class wxc_sdk.telephony.devices.TelephonyDeviceOwner(*, linePort: str | None = None, sipUserName: str | None = None, **extra_data: Any)[source]
Bases:
ApiModel- line_port: str | None
Identifies a device endpoint in standalone mode or a SIP URI public identity in IMS mode.
- sip_user_name: str | None
SIP authentication user name for the owner of the device.
- class wxc_sdk.telephony.devices.TelephonyDeviceProxy(*, outboundProxy: str | None = None, **extra_data: Any)[source]
Bases:
ApiModel- outbound_proxy: str | None
Outgoing server which the phone should use for all SIP requests. Not set if the response has no body.
- class wxc_sdk.telephony.devices.LayoutMode(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- default = 'DEFAULT'
Default layout mode when a new device is added.
- custom = 'CUSTOM'
Enables a device to have its custom layout.
- class wxc_sdk.telephony.devices.KemModuleType(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumAn enumeration.
- kem_14_keys = 'KEM_14_KEYS'
Extension module has 14 line keys that can be configured.
- kem_18_keys = 'KEM_18_KEYS'
Extension module has 18 line keys that can be configured.
- kem_20_keys = 'KEM_20_KEYS'
Extension module has 20 line keys that can be configured.
- class wxc_sdk.telephony.devices.KemKey(*, kemModuleIndex: int | None = None, kemKeyIndex: int | None = None, kemKeyType: LineKeyType | None = None, kemKeyLabel: str | None = None, kemKeyValue: str | None = None, sharedLineIndex: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- kem_module_index: int | None
An index representing a KEM Module. The Index starts from 1 representing the first KEM Module.
- kem_key_index: int | None
An index representing a KEM Key. The Index starts from 1 representing the first key on the left side of the phone.
- kem_key_type: LineKeyType | None
The action that would be performed when the KEM Key is pressed.
- kem_key_label: str | None
Applicable only when the kemKeyType is SPEED_DIAL.
- kem_key_value: str | None
Applicable only when the kemKeyType is SPEED_DIAL. Value must be a valid Telephone Number, Ext, or SIP URI (format: user@host limited to A-Z,a-z,0-9,-_ .+ for user and host).
Shared line index is the line label number of the shared or virtual line assigned in the configured lines. Since you can add multiple appearances of the same shared or virtual line on a phone, entering the index number assigns the respective line to a line key. This is applicable only when the lineKeyType is SHARED_LINE, If multiple programmable line keys are configured as shared lines, and If the sharedLineIndex is sent for any of the shared line, then the sharedLineIndex should be sent for all other shared lines. When lineKeyType is SHARED_LINE and sharedLineIndex is not assigned to any of the configured lines, then sharedLineIndex is assigned by default in the order the shared line appears in the request.
- class wxc_sdk.telephony.devices.DeviceLayout(*, layoutMode: LayoutMode | None = None, userReorderEnabled: bool | None = None, lineKeys: list[ProgrammableLineKey] | None = None, kemModuleType: KemModuleType | None = None, kemKeys: list[KemKey] | None = None, **extra_data: Any)[source]
Bases:
ApiModel- layout_mode: LayoutMode | None
Defines the layout mode of the device, i.e. DEFAULT or CUSTOM.
- user_reorder_enabled: bool | None
If true, user customization is enabled..
- line_keys: list[ProgrammableLineKey] | None
Contains a mapping of Line Keys and their corresponding actions.
- kem_module_type: KemModuleType | None
Type of KEM module.
- class wxc_sdk.telephony.devices.DeviceSettings(*, compression: bool | None = None, **extra_data: Any)[source]
Bases:
ApiModel- compression: bool | None
True -> Minimize data use during compression.
False -> Ignore data use during compression.
- class wxc_sdk.telephony.devices.BackgroundImage(*, backgroundImageUrl: str | None = None, fileName: str | None = None, count: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- background_image_url: str | None
The URL of the image file.
- file_name: str | None
The name of the image file.
- count: int | None
The total number of images in the org after uploading.
- class wxc_sdk.telephony.devices.BackgroundImages(*, backgroundImages: list[BackgroundImage] | None = None, count: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- background_images: list[BackgroundImage] | None
Array of background images.
- count: int | None
The total number of images in the org.
- class wxc_sdk.telephony.devices.DeleteImageRequestObject(*, fileName: str | None = None, forceDelete: bool | None = None, **extra_data: Any)[source]
Bases:
ApiModel- file_name: str | None
The name of the image file to be deleted.
- force_delete: bool | None
Flag to force delete the image. When forceDelete = true, if any device, location, or org level custom background URL is configured with the backgroundImageURL containing the filename being deleted, the background image is set to None.
- class wxc_sdk.telephony.devices.DeleteImageResponseSuccessObjectResult(*, status: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- status: int | None
The status of the deletion.
- class wxc_sdk.telephony.devices.DeleteImageResponseSuccessObject(*, fileName: str | None = None, result: DeleteImageResponseSuccessObjectResult | None = None, **extra_data: Any)[source]
Bases:
ApiModel- file_name: str | None
The name of the image file.
- result: DeleteImageResponseSuccessObjectResult | None
The result of the deletion.
- class wxc_sdk.telephony.devices.DeleteDeviceBackgroundImagesResponse(*, items: list[DeleteImageResponseSuccessObject] | None = None, count: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- items: list[DeleteImageResponseSuccessObject] | None
Array of deleted images.
- count: int | None
The total number of images in the org after deletion.
- class wxc_sdk.telephony.devices.UserDeviceCount(*, totalDeviceCount: int | None = None, applicationsCount: int | None = None, **extra_data: Any)[source]
Bases:
ApiModel- total_device_count: int | None
The total count of devices associated with the user as a sum of:
Count of total primary physical devices.
Count of Webex-Team system device endpoints.
Count of 1 for any or all applications present.
- applications_count: int | None
The total count of applications associated with the user.
Subpackages
- wxc_sdk.telephony.devices.dynamic_settings package
SettingsTypeDeviceSettingsGroupTagSettingsGroupDynamicSettingsGroupsValidationRuleDeviceTagDevicePutItemParentLevelDeviceDynamicTagDeviceDynamicSettingsDevicesDynamicSettingsApiDevicesDynamicSettingsApi.get_settings_groups()DevicesDynamicSettingsApi.get_validation_schema()DevicesDynamicSettingsApi.update_specified_settings_for_the_device()DevicesDynamicSettingsApi.get_customer_device_settings()DevicesDynamicSettingsApi.get_device_settings()DevicesDynamicSettingsApi.get_location_device_settings()DevicesDynamicSettingsApi.base