microsoft-graph-comms-samples icon indicating copy to clipboard operation
microsoft-graph-comms-samples copied to clipboard

Samples\V1.0Samples\StatelessSamples do not work with the latest versions of the SDK.

Open michaeljdresser opened this issue 1 year ago • 0 comments

Describe the issue Updating all the 'Microsoft.Graph.Communications' packages to 1.2.0.9212 or above breaks the samples.

Should the stateless samples work with the latest versions of the SDK's? If so can the samples be updated?

I've managed to fix most things but still have a few errors.

Code Example private async Task BotAnswerIncomingCallAsync(string callId, string tenantId, Guid scenarioId) { var answerRequest = this.RequestBuilder.Communications.Calls[callId].Answer( callbackUri: new Uri(this.botBaseUri, ControllerConstants.CallbackPrefix).ToString(), mediaConfig: new ServiceHostedMediaConfig { PreFetchMedia = new List<MediaInfo>() { new MediaInfo() { Uri = new Uri(this.botBaseUri, "audio/speech.wav").ToString(), ResourceId = Guid.NewGuid().ToString(), }, }, }, acceptedModalities: new List<Modality> { Modality.Audio }).Request(); await this.GraphApiClient.SendAsync(answerRequest, RequestType.Create, tenantId, scenarioId).ConfigureAwait(false); }

This produces the error: Severity Code Description Project File Line Suppression State Error CS1955 Non-invocable member 'CallItemRequestBuilder.Answer' cannot be used like a method. SimpleIvrBot C:\Workspace\Projects\microsoft-graph-comms-samples-master\Samples\V1.0Samples\StatelessSamples\SimpleIvrBot\Bot\Bot.cs 403 Active

Regards

Michael.

michaeljdresser avatar Mar 12 '24 21:03 michaeljdresser