Dela via


AIVisionFaceModelFactory.CreateLivenessSessionContent Method

Definition

Initializes a new instance of CreateLivenessSessionContent.

public static Azure.AI.Vision.Face.CreateLivenessSessionContent CreateLivenessSessionContent (Azure.AI.Vision.Face.LivenessOperationMode livenessOperationMode = default, bool? sendResultsToClient = default, bool? deviceCorrelationIdSetInClient = default, bool? enableSessionImage = default, Azure.AI.Vision.Face.LivenessModel? livenessSingleModalModel = default, string deviceCorrelationId = default, int? authTokenTimeToLiveInSeconds = default);
static member CreateLivenessSessionContent : Azure.AI.Vision.Face.LivenessOperationMode * Nullable<bool> * Nullable<bool> * Nullable<bool> * Nullable<Azure.AI.Vision.Face.LivenessModel> * string * Nullable<int> -> Azure.AI.Vision.Face.CreateLivenessSessionContent
Public Shared Function CreateLivenessSessionContent (Optional livenessOperationMode As LivenessOperationMode = Nothing, Optional sendResultsToClient As Nullable(Of Boolean) = Nothing, Optional deviceCorrelationIdSetInClient As Nullable(Of Boolean) = Nothing, Optional enableSessionImage As Nullable(Of Boolean) = Nothing, Optional livenessSingleModalModel As Nullable(Of LivenessModel) = Nothing, Optional deviceCorrelationId As String = Nothing, Optional authTokenTimeToLiveInSeconds As Nullable(Of Integer) = Nothing) As CreateLivenessSessionContent

Parameters

livenessOperationMode
LivenessOperationMode

Type of liveness mode the client should follow.

sendResultsToClient
Nullable<Boolean>

Whether or not to allow a '200 - Success' response body to be sent to the client, which may be undesirable for security reasons. Default is false, clients will receive a '204 - NoContent' empty body response. Regardless of selection, calling Session GetResult will always contain a response body enabling business logic to be implemented.

deviceCorrelationIdSetInClient
Nullable<Boolean>

Whether or not to allow client to set their own 'deviceCorrelationId' via the Vision SDK. Default is false, and 'deviceCorrelationId' must be set in this request body.

enableSessionImage
Nullable<Boolean>

Whether or not store the session image.

livenessSingleModalModel
Nullable<LivenessModel>

The model version used for liveness classification. This is an optional parameter, and if this is not specified, then the latest supported model version will be chosen.

deviceCorrelationId
String

Unique Guid per each end-user device. This is to provide rate limiting and anti-hammering. If 'deviceCorrelationIdSetInClient' is true in this request, this 'deviceCorrelationId' must be null.

authTokenTimeToLiveInSeconds
Nullable<Int32>

Seconds the session should last for. Range is 60 to 86400 seconds. Default value is 600.

Returns

A new CreateLivenessSessionContent instance for mocking.

Applies to