wxc_sdk.telephony.location.moh module
MoH API for locations
- class wxc_sdk.telephony.location.moh.LocationMoHGreetingType(value=<no_arg>, names=None, module=None, qualname=None, type=None, start=1, boundary=None)[source]
Bases:
str,SafeEnumGreeting type for the location.
- system = 'SYSTEM'
Play default music when call is placed on hold or parked. The system plays music to fill the silence and lets the customer know they are still connected.
- custom = 'CUSTOM'
Play custom music when call is placed on hold or parked. An audio file must already have been successfully uploaded to specify this option.
- class wxc_sdk.telephony.location.moh.LocationMoHSetting(*, callHoldEnabled: bool | None = None, callParkEnabled: bool | None = None, greeting: LocationMoHGreetingType | None = None, audioFile: AnnAudioFile | None = None, playlist: IdAndName | None = None)[source]
Bases:
ApiModellocation’s music on hold settings.
- call_hold_enabled: bool | None
If enabled, music will be played when call is placed on hold.
- call_park_enabled: bool | None
If enabled, music will be played when call is parked.
- greeting: LocationMoHGreetingType | None
Greeting type for the location.
- audio_file: AnnAudioFile | None
Announcement Audio File details when greeting is selected to be CUSTOM.
- class wxc_sdk.telephony.location.moh.LocationMoHApi(*, session: RestSession, base: str | None = None)[source]
Bases:
ApiChildLocation Music on Hold API
- read(location_id: str, org_id: str | None = None) LocationMoHSetting[source]
Get Music On Hold
Retrieve the location’s music on hold settings.
Location’s music on hold settings allows you to play music when a call is placed on hold or parked.
Retrieving location’s music on hold settings requires a full, user or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
location_id (str) – Retrieve access codes details for this location.
org_id (str) – Retrieve access codes details for a customer location in this organization
- Returns:
MoH settings
- Return type:
- update(location_id: str, settings: LocationMoHSetting, org_id: str | None = None)[source]
Get Music On Hold
Retrieve the location’s music on hold settings.
Location’s music on hold settings allows you to play music when a call is placed on hold or parked.
Retrieving location’s music on hold settings requires a full, user or read-only administrator auth token with a scope of spark-admin:telephony_config_read.
- Parameters:
location_id (str) – Retrieve access codes details for this location.
settings (
LocationMoHSetting) – new settingsorg_id (str) – Retrieve access codes details for a customer location in this organization
- Returns:
list of
wxc_sdk.common.CallPark
- base = 'telephony/config/locations'