Table of Contents

Class SerproBiometricsServiceCollectionExtensions

Namespace
NuvTools.Security.Biometrics.Serpro.Extensions
Assembly
NuvTools.Security.Biometrics.Serpro.dll

Extension methods for registering the facial verification services.

public static class SerproBiometricsServiceCollectionExtensions
Inheritance
SerproBiometricsServiceCollectionExtensions
Inherited Members

Methods

AddSerproFaceVerification(IServiceCollection, IConfiguration, string, int)

Binds DatavalidOptions from configuration and registers SERPRO Datavalid as the IFaceVerifier, with its own HttpClient and a cached access token.

public static IServiceCollection AddSerproFaceVerification(this IServiceCollection services, IConfiguration configuration, string sectionName = "Datavalid", int timeoutInSeconds = 30)

Parameters

services IServiceCollection

The service collection to add the services to.

configuration IConfiguration

Configuration holding the Datavalid section.

sectionName string

Name of the section to bind. Defaults to SectionName; pass the application's own when its settings already live under another name.

timeoutInSeconds int

Timeout of each call to SERPRO. Defaults to 30 seconds.

Returns

IServiceCollection

The service collection for chaining.

Remarks

This is the only place a caller names the provider: everything above it depends on IFaceVerifier, so changing provider is changing this call.