Skip to content

Commit 28f6b4a

Browse files
Merge pull request #311888 from alvin-l-han/main
Update Call Recording docs to include support for callconnectionid
2 parents 93e38fe + 1724f00 commit 28f6b4a

5 files changed

Lines changed: 64 additions & 50 deletions

File tree

articles/communication-services/concepts/voice-video-calling/call-recording.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,13 @@ Call Recording supports multiple media outputs and content types to address your
5151
5252

5353
## Get full control over your recordings with our Call Recording APIs
54-
You can use Call Recording APIs to manage recording via internal business logic triggers, such as an application creating a group call and recording the conversation. Also, recordings can be triggered by a user action that tells the server application to start recording. Call Recording APIs use exclusively the `serverCallId` to initiate recording. To learn how to get the `serverCallId`, check our [Call Recording Quickstart](../../quickstarts/voice-video-calling/get-started-call-recording.md).
54+
You can use Call Recording APIs to manage recording via internal business logic triggers, such as an application creating a group call and recording the conversation. Also, recordings can be triggered by a user action that tells the server application to start recording. To initiate a recording, Call Recording APIs can use the `callConnectionId` (preferred) or the `serverCallId` when the callConnectionId is not available. To learn how to get the `callConnectionId` or `serverCallId`, check our [Call Recording Quickstart](../../quickstarts/voice-video-calling/get-started-call-recording.md).
5555
A `recordingId` is returned when recording is started, which can then be used for follow-on operations like pause and resume.
5656

5757

5858
| Operation | Operates On | Comments |
5959
| :-------------------- | :--------------------- | :----------------------------- |
60-
| Start Recording | `serverCallId` | Returns `recordingId` |
60+
| Start Recording | `callConnectionId` or `serverCallId` | Returns `recordingId` |
6161
| Get Recording State | `recordingId` | Returns `RecordingStateResult` |
6262
| Pause Recording | `recordingId` | Pausing and resuming call recording enables you to skip recording a portion of a call or meeting, and resume recording to a single file. |
6363
| Resume Recording | `recordingId` | Resumes a Paused recording operation. Content is included in the same file as content from prior to pausing. |
@@ -149,6 +149,9 @@ Many countries/regions and states have laws and regulations that apply to call r
149149

150150
Regulations around the maintenance of personal data require the ability to export user data. In order to support these requirements, recording metadata files include the `participantId` for each call participant in the `participants` array. You can cross-reference the Azure Communication Services User Identity in the `participants` array with your internal user identities to identify participants in a call.
151151

152+
## Known Issues ##
153+
In rare High Availability or Disaster Recovery (HADR) scenarios, a single call recording session may produce multiple recording files that share the same `recordingId` and `chunkId`. In these cases, `StopCallRecording` may return `404 Recording not found` even though recording files are successfully delivered via `RecordingFileStatusUpdated` events. Applications should correlate recordings using `serverCallId` and not assume a one‑to‑one relationship between calls, recording IDs, chunk IDs, and output files.
154+
152155
## Next steps
153156

154157
> [!div class="nextstepaction"]

articles/communication-services/quickstarts/voice-video-calling/includes/call-recording-samples/call-recording-csharp.md

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,17 +20,20 @@ You can download the sample app from [GitHub](https://github.com/Azure-Samples/c
2020

2121
## Before you start
2222

23-
Call Recording APIs use exclusively the `serverCallId`to initiate recording. There are a couple of methods you can use to fetch the `serverCallId` depending on your scenario:
23+
Call Recording APIs use the `callConnectionId` or `serverCallId`to initiate recording. There are a couple of methods you can use to fetch the these IDs depending on your scenario:
2424

25-
### Call Automation scenarios
25+
### How to fetch callConnectionId
26+
27+
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you will receive the `callConnectionId` from the response event from a `createCall`, `answer`, or `connect` requests when initiating the call.
28+
29+
### How to fetch serverCallId
2630

2731
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you have two options to get the `serverCallId`:
2832

2933
1. When you establish a call, it returns a `serverCallId` as a property of the `CallConnected` event after a call is established. Learn how to [Get CallConnected event](../../../call-automation/callflows-for-customer-interactions.md?pivots=programming-language-csharp#update-programcs) from Call Automation SDK.
3034

3135
2. When you answer the call or a call is created, it returns the `serverCallId` as a property of the `AnswerCallResult` or `CreateCallResult` API responses respectively.
3236

33-
### Calling SDK scenarios
3437

3538
When using [Calling Client SDK](../../get-started-with-video-calling.md), you can retrieve the `serverCallId` by using the `getServerCallId` method on the call.
3639
Use this example to learn how to [Get serverCallId](../../get-server-call-id.md) from the Calling Client SDK.
@@ -49,13 +52,13 @@ CallAutomationClient callAutomationClient = new CallAutomationClient("<ACSConnec
4952

5053
## 2. Start recording session with StartRecordingOptions using 'StartAsync' API
5154

52-
Use the `serverCallId` received during initiation of the call.
55+
Use the `callConnectionId` or `serverCallId` received during initiation of the call.
5356
- Use `RecordingContent` to pass the recording content type. Use `AUDIO`.
5457
- Use `RecordingChannel` to pass the recording channel type. Use `MIXED` or `UNMIXED`.
5558
- Use `RecordingFormat` to pass the format of the recording. Use `WAV`.
5659

5760
```csharp
58-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<ServerCallId>"))
61+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<callConnectionId> or <ServerCallId>"))
5962
{
6063
RecordingContent = RecordingContent.Audio,
6164
RecordingChannel = RecordingChannel.Unmixed,
@@ -70,7 +73,7 @@ Response<RecordingStateResult> response = await callAutomationClient.GetCallReco
7073
Start recording using your designated Azure Blob Storage to store the recorded file once recording is complete.
7174

7275
```csharp
73-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<ServerCallId>"))
76+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<CallConnectionId> or <ServerCallId>"))
7477
{
7578
RecordingContent = RecordingContent.Audio,
7679
RecordingChannel = RecordingChannel.Unmixed,
@@ -88,7 +91,7 @@ Response<RecordingStateResult> response = await callAutomationClient.GetCallReco
8891
> **Recordings will need to be resumed for recording file to be generated.**
8992
9093
```csharp
91-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<ServerCallId>"))
94+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<CallConnectionId> or <ServerCallId>"))
9295
{
9396
RecordingContent = RecordingContent.Audio,
9497
RecordingChannel = RecordingChannel.Unmixed,
@@ -105,7 +108,7 @@ Response<RecordingStateResult> response = await callAutomationClient.GetCallReco
105108
To produce unmixed audio recording files, you can use the `AudioChannelParticipantOrdering` functionality to specify which user you want to record on channel 0. The rest of the participants are assigned to a channel as they speak. If you use `RecordingChannel.Unmixed` but don't use `AudioChannelParticipantOrdering`, Call Recording assigns channel 0 to the first participant speaking.
106109

107110
```csharp
108-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<ServerCallId>"))
111+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<CallConnectionId> or <ServerCallId>"))
109112
{
110113
RecordingContent = RecordingContent.Audio,
111114
RecordingChannel = RecordingChannel.Unmixed,
@@ -121,7 +124,7 @@ Response<RecordingStateResult> response = await callAutomationClient.GetCallReco
121124

122125
```csharp
123126
var channelAffinity = new ChannelAffinity(new CommunicationUserIdentifier("<ACS_USER_MRI>")) { Channel = 0};
124-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<ServerCallId>"))
127+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<CallConnectionId> or <ServerCallId>"))
125128
{
126129
RecordingContent = RecordingContent.Audio,
127130
RecordingChannel = RecordingChannel.Unmixed,

articles/communication-services/quickstarts/voice-video-calling/includes/call-recording-samples/call-recording-java.md

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,22 @@ You can download the sample app from [GitHub](https://github.com/Azure-Samples/c
2121

2222
## Before you start
2323

24-
Call Recording APIs exclusively use the `serverCallId` to initiate recording. There are a couple of methods you can use to fetch the `serverCallId` depending on your scenario:
24+
Call Recording APIs use the `callConnectionId` or `serverCallId`to initiate recording. There are a couple of methods you can use to fetch the these IDs depending on your scenario:
2525

26-
### Call Automation scenarios
26+
### How to fetch callConnectionId
2727

28-
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you have two options to get the `serverCallId`:
28+
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you will receive the `callConnectionId` from the response event from a `createCall`, `answer`, or `connect` requests when initiating the call.
29+
30+
### How to fetch serverCallId
2931

30-
1. Once a call is created, a `serverCallId` is returned as a property of the `CallConnected` event after a call is established. Learn how to [Get CallConnected event](../../../call-automation/callflows-for-customer-interactions.md?pivots=programming-language-java#update-programcs) from Call Automation SDK.
32+
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you have two options to get the `serverCallId`:
3133

32-
2. Once you answer the call or a call is created the `serverCallId` is returned as a property of the `AnswerCallResult` or `CreateCallResult` API responses respectively.
34+
1. When you establish a call, it returns a `serverCallId` as a property of the `CallConnected` event after a call is established. Learn how to [Get CallConnected event](../../../call-automation/callflows-for-customer-interactions.md?pivots=programming-language-csharp#update-programcs) from Call Automation SDK.
3335

34-
### Calling SDK scenarios
36+
2. When you answer the call or a call is created, it returns the `serverCallId` as a property of the `AnswerCallResult` or `CreateCallResult` API responses respectively.
3537

36-
When using [Calling Client SDK](../../get-started-with-video-calling.md), you can retrieve the `serverCallId` by using the `getServerCallId` method on the call.
3738

39+
When using [Calling Client SDK](../../get-started-with-video-calling.md), you can retrieve the `serverCallId` by using the `getServerCallId` method on the call.
3840
Use this example to learn how to [Get serverCallId](../../get-server-call-id.md) from the Calling Client SDK.
3941

4042
Let's get started with a few simple steps.
@@ -53,13 +55,13 @@ CallAutomationClient callAutomationClient = new CallAutomationClientBuilder()
5355

5456
## 2. Start recording session with StartRecordingOptions using `startWithResponse` API
5557

56-
Use the `serverCallId` received during initiation of the call.
58+
Use the `callConnectionId` or `serverCallId` received during initiation of the call.
5759
- Use `RecordingContent` to pass the recording content type. Use `AUDIO`.
5860
- Use `RecordingChannel` to pass the recording channel type. Use `MIXED` or `UNMIXED`.
5961
- Use `RecordingFormat` to pass the format of the recording. Use `WAV`.
6062

6163
```java
62-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<serverCallId>"))
64+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<callConnectionId> or <serverCallId>"))
6365
.setRecordingChannel(RecordingChannel.UNMIXED)
6466
.setRecordingFormat(RecordingFormat.WAV)
6567
.setRecordingContent(RecordingContent.AUDIO)
@@ -91,7 +93,7 @@ Start recording using your designated Azure Blob Storage to store the recorded f
9193
> **Recordings must be resumed for recording file to be generated.**
9294
9395
```java
94-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<serverCallId>"))
96+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<<callConnectionId> or serverCallId>"))
9597
.setRecordingChannel(RecordingChannel.UNMIXED)
9698
.setRecordingFormat(RecordingFormat.WAV)
9799
.setRecordingContent(RecordingContent.AUDIO)
@@ -109,7 +111,7 @@ Response<RecordingStateResult> response = callAutomationClient.getCallRecording(
109111
To produce unmixed audio recording files, you can use the `AudioChannelParticipantOrdering` functionality to specify which user you want to record on channel 0. The rest of the participants are assigned to a channel as they speak. If you use `RecordingChannel.Unmixed` but don't use `AudioChannelParticipantOrdering`, Call Recording assigns channel 0 to the first participant speaking.
110112

111113
```java
112-
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<serverCallId>"))
114+
StartRecordingOptions recordingOptions = new StartRecordingOptions(new ServerCallLocator("<<callConnectionId> or serverCallId>"))
113115
.setRecordingChannel(RecordingChannel.UNMIXED)
114116
.setRecordingFormat(RecordingFormat.WAV)
115117
.setRecordingContent(RecordingContent.AUDIO)

articles/communication-services/quickstarts/voice-video-calling/includes/call-recording-samples/call-recording-javascript.md

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -20,21 +20,25 @@ You can download the sample app from [GitHub](https://github.com/Azure-Samples/c
2020

2121
## Before you start
2222

23-
Call Recording APIs use exclusively the `serverCallId`to initiate recording. There are a couple of methods you can use to fetch the `serverCallId` depending on your scenario:
23+
Call Recording APIs use the `callConnectionId` or `serverCallId`to initiate recording. There are a couple of methods you can use to fetch the these IDs depending on your scenario:
2424

25-
### Call Automation scenarios
25+
### How to fetch callConnectionId
2626

27-
- When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you have two options to get the `serverCallId`:
28-
1) Once a call is created, a `serverCallId` is returned as a property of the `CallConnected` event after a call is established. Learn how to [Get a CallConnected event](../../../call-automation/callflows-for-customer-interactions.md?pivots=programming-language-javascript#update-programcs) from the Call Automation SDK.
29-
2) Once you answer the call or a call is created, it returns the `serverCallId` as a property of the `AnswerCallResult` or `CreateCallResult` API responses respectively.
27+
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you will receive the `callConnectionId` from the response event from a `createCall`, `answer`, or `connect` requests when initiating the call.
3028

31-
### Calling SDK scenarios
29+
### How to fetch serverCallId
3230

33-
When using [Calling Client SDK](../../get-started-with-video-calling.md), you can retrieve the `serverCallId` by using the `getServerCallId` method on the call.
31+
When using [Call Automation](../../../call-automation/callflows-for-customer-interactions.md), you have two options to get the `serverCallId`:
3432

35-
Use this example to learn how to [Get a serverCallId](../../get-server-call-id.md) from the Calling Client SDK.
33+
1. When you establish a call, it returns a `serverCallId` as a property of the `CallConnected` event after a call is established. Learn how to [Get CallConnected event](../../../call-automation/callflows-for-customer-interactions.md?pivots=programming-language-csharp#update-programcs) from Call Automation SDK.
3634

37-
Let's get started with a few simple steps!
35+
2. When you answer the call or a call is created, it returns the `serverCallId` as a property of the `AnswerCallResult` or `CreateCallResult` API responses respectively.
36+
37+
38+
When using [Calling Client SDK](../../get-started-with-video-calling.md), you can retrieve the `serverCallId` by using the `getServerCallId` method on the call.
39+
Use this example to learn how to [Get serverCallId](../../get-server-call-id.md) from the Calling Client SDK.
40+
41+
Let's get started with a few simple steps.
3842

3943
## 1. Create a Call Automation client
4044

@@ -48,13 +52,13 @@ const callAutomationClient = new CallAutomationClient.CallAutomationClient("<ACS
4852

4953
## 2. Start recording session with StartRecordingOptions using 'StartAsync' API
5054

51-
Use the `serverCallId` received during initiation of the call.
55+
Use the `callConnectionId` or `serverCallId` received during initiation of the call.
5256
- Use `RecordingContent` to pass the recording content type. Use `AUDIO`.
5357
- Use `RecordingChannel` to pass the recording channel type. Use `MIXED` or `UNMIXED`.
5458
- Use `RecordingFormat` to pass the format of the recording. Use `WAV`.
5559

5660
```javascript
57-
var locator: CallLocator = { id: "<ServerCallId>", kind: "serverCallLocator" };
61+
var locator: CallLocator = { id: "<callConnectionId> or <ServerCallId>", kind: "serverCallLocator" };
5862

5963
var options: StartRecordingOptions =
6064
{
@@ -91,7 +95,7 @@ var response = await callAutomationClient.getCallRecording().start(options);
9195
> [!NOTE]
9296
> **Recordings will need to be resumed for recording file to be generated.**
9397
```javascript
94-
var locator: CallLocator = { id: "<ServerCallId>", kind: "serverCallLocator" };
98+
var locator: CallLocator = { id: "<callConnectionId> or <ServerCallId>", kind: "serverCallLocator" };
9599

96100
var options: StartRecordingOptions =
97101
{
@@ -110,7 +114,7 @@ var response = await callAutomationClient.getCallRecording().start(options);
110114
To produce unmixed audio recording files, you can use the `AudioChannelParticipantOrdering` functionality to specify which user you want to record on channel 0. The rest of the participants are assigned to a channel as they speak. If you use `RecordingChannel.Unmixed` but don't use `AudioChannelParticipantOrdering`, Call Recording assigns channel 0 to the first participant speaking.
111115

112116
```javascript
113-
var locator: CallLocator = { id: "<ServerCallId>", kind: "serverCallLocator" };
117+
var locator: CallLocator = { id: "<callConnectionId> or <ServerCallId>", kind: "serverCallLocator" };
114118

115119
var options: StartRecordingOptions =
116120
{

0 commit comments

Comments
 (0)