Share via


VoiceLiveClient.StartSessionAsync Method

Definition

Overloads

Name Description
StartSessionAsync(VoiceLiveSessionOptions, CancellationToken)

Starts a new VoiceLiveSession for real-time voice communication with specified session configuration.

StartSessionAsync(String, CancellationToken)

Starts a new VoiceLiveSession for real-time voice communication.

StartSessionAsync(VoiceLiveSessionOptions, CancellationToken)

Source:
VoiceLiveClient.core.cs
Source:
VoiceLiveClient.core.cs

Starts a new VoiceLiveSession for real-time voice communication with specified session configuration.

public virtual System.Threading.Tasks.Task<Azure.AI.VoiceLive.VoiceLiveSession> StartSessionAsync(Azure.AI.VoiceLive.VoiceLiveSessionOptions sessionConfig, System.Threading.CancellationToken cancellationToken = default);
abstract member StartSessionAsync : Azure.AI.VoiceLive.VoiceLiveSessionOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.AI.VoiceLive.VoiceLiveSession>
override this.StartSessionAsync : Azure.AI.VoiceLive.VoiceLiveSessionOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.AI.VoiceLive.VoiceLiveSession>
Public Overridable Function StartSessionAsync (sessionConfig As VoiceLiveSessionOptions, Optional cancellationToken As CancellationToken = Nothing) As Task(Of VoiceLiveSession)

Parameters

sessionConfig
VoiceLiveSessionOptions

The configuration for the session.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

A task that represents the asynchronous operation. The task result contains a new, connected instance of VoiceLiveSession.

Remarks

The VoiceLiveSession abstracts bidirectional communication between the caller and service, simultaneously sending and receiving WebSocket messages.

Applies to

StartSessionAsync(String, CancellationToken)

Source:
VoiceLiveClient.core.cs
Source:
VoiceLiveClient.core.cs

Starts a new VoiceLiveSession for real-time voice communication.

public virtual System.Threading.Tasks.Task<Azure.AI.VoiceLive.VoiceLiveSession> StartSessionAsync(string model, System.Threading.CancellationToken cancellationToken = default);
abstract member StartSessionAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.AI.VoiceLive.VoiceLiveSession>
override this.StartSessionAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.AI.VoiceLive.VoiceLiveSession>
Public Overridable Function StartSessionAsync (model As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of VoiceLiveSession)

Parameters

model
String
cancellationToken
CancellationToken

The cancellation token to use.

Returns

A task that represents the asynchronous operation. The task result contains a new, connected instance of VoiceLiveSession.

Remarks

The VoiceLiveSession abstracts bidirectional communication between the caller and service, simultaneously sending and receiving WebSocket messages.

Applies to