wxc_sdk.telephony.voice_messaging module

Voice messaging API

Voice Messaging APIs provide support for handling voicemail and message waiting indicators in Webex Calling. The APIs are limited to user access (no admin access), and all GET commands require the spark:calls_read scope, while the other commands require the spark:calls_write scope

class wxc_sdk.telephony.voice_messaging.MessageSummary(*, newMessages: int | None = None, oldMessages: int | None = None, newUrgentMessages: int | None = None, oldUrgentMessages: int | None = None)[source]

Bases: ApiModel

new_messages: int | None

The number of new (unread) voicemail messages.

old_messages: int | None

The number of old (read) voicemail messages.

new_urgent_messages: int | None

The number of new (unread) urgent voicemail messages.

old_urgent_messages: int | None

The number of old (read) urgent voicemail messages.

class wxc_sdk.telephony.voice_messaging.VoiceMailPartyInformation(*, name: str | None = None, number: str | None = None, personId: str | None = None, placeId: str | None = None, privacyEnabled: bool | None = None)[source]

Bases: ApiModel

name: str | None

The party’s name. Only present when the name is available and privacy is not enabled.

number: str | None

The party’s number. Only present when the number is available and privacy is not enabled. The number can be digits or a URI. Some examples for number include: 1234, 2223334444, +12223334444, and user@company.domain.

person_id: str | None

The party’s person ID. Only present when the person ID is available and privacy is not enabled.

place_id: str | None

The party’s place ID. Only present when the place ID is available and privacy is not enabled.

privacy_enabled: bool | None

Indicates whether privacy is enabled for the name, number and personId/placeId.

class wxc_sdk.telephony.voice_messaging.VoiceMessageDetails(*, id: str | None = None, duration: int | None = None, callingParty: VoiceMailPartyInformation | None = None, urgent: bool | None = None, confidential: bool | None = None, read: bool | None = None, faxPageCount: int | None = None, created: str | None = None)[source]

Bases: ApiModel

id: str | None

The message identifier of the voicemail message.

duration: int | None

The duration (in seconds) of the voicemail message. Duration is not present for a FAX message.

calling_party: VoiceMailPartyInformation | None

The calling party’s details. For example, if user A calls user B and leaves a voicemail message, then A is the calling party.

urgent: bool | None

true if the voicemail message is urgent.

confidential: bool | None

true if the voicemail message is confidential.

read: bool | None

true if the voicemail message has been read.

fax_page_count: int | None

Number of pages for the FAX. Only set for a FAX.

created: str | None

The date and time the voicemail message was created.

class wxc_sdk.telephony.voice_messaging.VoiceMessagingApi(*, session: RestSession, base: str | None = None)[source]

Bases: ApiChild

Voice Messaging APIs provide support for handling voicemail and message waiting indicators in Webex Calling. The APIs are limited to user access (no admin access), and all GET commands require the spark:calls_read scope, while the other commands require the spark:calls_write scope.

summary() MessageSummary[source]

Get a summary of the voicemail messages for the user.

list(**params) Generator[VoiceMessageDetails, None, None][source]

Get the list of all voicemail messages for the user.

delete(message_id: str)[source]

Delete a specfic voicemail message for the user.

Parameters:

message_id (str) – The message identifer of the voicemail message to delete

mark_as_read(message_id: str)[source]

Update the voicemail message(s) as read for the user. If the messageId is provided, then only mark that message as read. Otherwise, all messages for the user are marked as read.

Parameters:

message_id (str) – The voicemail message identifier of the message to mark as read. If the messageId is not provided, then all voicemail messages for the user are marked as read.

mark_as_unread(message_id: str)[source]

Update the voicemail message(s) as unread for the user. If the messageId is provided, then only mark that message as unread. Otherwise, all messages for the user are marked as unread.

Parameters:

message_id (str) – The voicemail message identifier of the message to mark as unread. If the messageId is not provided, then all voicemail messages for the user are marked as unread.

base = 'telephony/voiceMessages'