Modifier

Partager via


New-CsAutoAttendantPrompt

Use the New-CsAutoAttendantPrompt cmdlet to create a new prompt.

Syntax

New-CsAutoAttendantPrompt
   -AudioFilePrompt <Object>
   [-Tenant <Guid>]
   [<CommonParameters>]
New-CsAutoAttendantPrompt
   -TextToSpeechPrompt <String>
   [-Tenant <Guid>]
   [<CommonParameters>]
New-CsAutoAttendantPrompt
   -ActiveType <None | TextToSpeech | AudioFile>
   -AudioFilePrompt <Object>
   -TextToSpeechPrompt <String>
   [-Tenant <Guid>]
   [<CommonParameters>]

Description

The New-CsAutoAttendantPrompt cmdlet creates a new prompt for the Auto Attendant (AA) service. A prompt is either an audio file that is played, or text that is read aloud to give callers additional information. A prompt can be disabled by setting the ActiveType to None.

Examples

-------------------------- Example 1 --------------------------

$ttsPrompt = New-CsAutoAttendantPrompt -TextToSpeechPrompt "Welcome to Contoso!"

This example creates a new prompt that reads the supplied text.

-------------------------- Example 2 --------------------------

$content = [System.IO.File]::ReadAllBytes('C:\Media\hello.wav')
$audioFile = Import-CsOnlineAudioFile -ApplicationId "OrgAutoAttendant" -FileName "hello.wav" -Content $content
$audioFilePrompt = New-CsAutoAttendantPrompt -AudioFilePrompt $audioFile

This example creates a new prompt that plays the selected audio file.

-------------------------- Example 3 --------------------------

$content = [System.IO.File]::ReadAllBytes('C:\Media\hello.wav')
$audioFile = Import-CsOnlineAudioFile -ApplicationId "OrgAutoAttendant" -FileName "hello.wav" -Content $content
$dualPrompt = New-CsAutoAttendantPrompt -ActiveType AudioFile -AudioFilePrompt $audioFile -TextToSpeechPrompt "Welcome to Contoso!"

This example creates a new prompt that has both audio file and text-to-speech data, but will play the audio file when the prompt is activated (rendered).

Parameters

-ActiveType

PARAMVALUE: None | TextToSpeech | AudioFile

The ActiveType parameter identifies the active type (modality) of the AA prompt. It can be set to None (the prompt is disabled), TextToSpeech (text-to-speech is played when the prompt is rendered) or AudioFile (audio file data is played when the prompt is rendered).

This is explicitly required if both Audio File and TTS prompts are specified. Otherwise, it is inferred.

Type:Object
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Microsoft Teams

-AudioFilePrompt

The AudioFilePrompt parameter represents the audio to play when the prompt is activated (rendered).

This parameter is required when audio file prompts are being created. You can create audio files by using the Import-CsOnlineAudioFile cmdlet.

Type:Object
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Microsoft Teams

-Tenant

Type:System.Guid
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Microsoft Teams

-TextToSpeechPrompt

The TextToSpeechPrompt parameter indicates the Text-to-Speech (TTS) prompt that is to be read when the prompt is activated.

This parameter is required when text to speech prompts are being created.

Type:System.String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:Microsoft Teams

Inputs

None

Outputs

Microsoft.Rtc.Management.Hosted.OAA.Models.Prompt