Example #1
0
        public async Task <PlayTTSAndCollectAction> PlayTTSAndCollectAsync(CallMedia.TTSParams tts, CallCollect collect)
        {
            CallMedia media = new CallMedia()
            {
                Type = CallMedia.MediaType.tts, Parameters = JObject.FromObject(tts)
            };
            PlayMediaAndCollectAction playMediaAndCollectAction = await PlayMediaAndCollectAsync(new List <CallMedia> {
                media
            }, collect);

            return(new PlayTTSAndCollectAction(playMediaAndCollectAction));
        }
Example #2
0
        public async Task <PlaySilenceAndCollectAction> PlaySilenceAndCollectAsync(CallMedia.SilenceParams silence, CallCollect collect)
        {
            CallMedia media = new CallMedia()
            {
                Type = CallMedia.MediaType.silence, Parameters = JObject.FromObject(silence)
            };
            PlayMediaAndCollectAction playMediaAndCollectAction = await PlayMediaAndCollectAsync(new List <CallMedia> {
                media
            }, collect);

            return(new PlaySilenceAndCollectAction(playMediaAndCollectAction));
        }
Example #3
0
        public async Task <PlayAudioAndCollectAction> PlayAudioAndCollectAsync(CallMedia.AudioParams audio, CallCollect collect)
        {
            CallMedia media = new CallMedia()
            {
                Type = CallMedia.MediaType.audio, Parameters = JObject.FromObject(audio)
            };
            PlayMediaAndCollectAction playMediaAndCollectAction = await PlayMediaAndCollectAsync(new List <CallMedia> {
                media
            }, collect);

            return(new PlayAudioAndCollectAction(playMediaAndCollectAction));
        }