Hi @Idris LOKHANDWALA
Thanks for the question and using MS Q&A platform.
To set up a 1:1 call with real-time transcription using the Azure Communication Services Call Automation SDK, you need to handle both incoming and outgoing call events and configure your transcription options correctly.
- Subscribe to IncomingCall and OutgoingCall events to get details about both participants. Implement event handlers to extract participant info.
- Set the locale and WebSocket connection when configuring transcription options. Turn on the startTranscription option if you want transcription to start right when the call is answered.
- The TranscriptionData object might not directly provide participant IDs. Keep a mapping of participant IDs when the call starts and link them with the transcription data you get.
- Here’s a basic example of setting up the call and starting transcription.
// Create call options var createCallOptions = new CreateCallOptions(callInvite, callbackUri) { CallIntelligenceOptions = new CallIntelligenceOptions() { CognitiveServicesEndpoint = new Uri(cognitiveServiceEndpoint) }, TranscriptionOptions = new TranscriptionOptions(new Uri(webSocketUri), "en-US", true, TranscriptionTransport.Websocket) }; // Create the call CreateCallResult createCallResult = await callAutomationClient.CreateCallAsync(createCallOptions); // Start transcription StartTranscriptionOptions options = new StartTranscriptionOptions() { OperationContext = "startMediaStreamingContext", }; await callMedia.StartTranscriptionAsync(options);
- Make sure your WebSocket server is set up to handle incoming transcription data. You’ll get metadata and transcription data packets to process.
For more detailed guidance, check out the Azure documentation on real-time transcription setup.
Add real-time transcription into your application (programming-language-csharp)
Add real-time transcription into your application (programming-language-javascript)
Add real-time transcription into your application (programming-language-java)
Add real-time transcription into your application (programming-language-python)
If the answer is helpful, please click Accept Answer and kindly upvote it so that other people who faces similar issue may get benefitted from it.