File Explorer

/var/runtime/node_modules/@aws-sdk/client-rekognitionstreaming/dist-cjs

This explorer reads the filesystem of the server it runs on, so /workspace/user isn't present here. Browsing and the terminal still work against this server's own disk from /.

index.js29.1 KB · 750 lines
const { awsEndpointFunctions, emitWarningIfUnsupportedVersion: emitWarningIfUnsupportedVersion$1, createDefaultUserAgentProvider, NODE_APP_ID_CONFIG_OPTIONS, getAwsRegionExtensionConfiguration, resolveAwsRegionExtensionConfiguration, resolveUserAgentConfig, resolveHostHeaderConfig, getUserAgentPlugin, getHostHeaderPlugin, getLoggerPlugin, getRecursionDetectionPlugin } = require("@aws-sdk/core/client");const { resolveEventStreamConfig, getEventStreamPlugin } = require("@aws-sdk/middleware-eventstream");const { resolveWebSocketConfig, getWebSocketPlugin } = require("@aws-sdk/middleware-websocket");const { getHttpAuthSchemeEndpointRuleSetPlugin, DefaultIdentityProviderConfig, getHttpSigningPlugin } = require("@smithy/core");const { normalizeProvider, getSmithyContext, ServiceException, NoOpLogger, emitWarningIfUnsupportedVersion, loadConfigsForDefaultMode, getDefaultExtensionConfiguration, resolveDefaultRuntimeConfig, Client, makeBuilder, createAggregatedClient } = require("@smithy/core/client");const { Command: $Command } = require("@smithy/core/client");exports.$Command = $Command;exports.__Client = Client;const { resolveDefaultsModeConfig, loadConfig, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_REGION_CONFIG_FILE_OPTIONS, resolveRegionConfig } = require("@smithy/core/config");const { BinaryDecisionDiagram, EndpointCache, decideEndpoint, customEndpointFunctions, resolveEndpointConfig, getEndpointPlugin } = require("@smithy/core/endpoints");const { eventStreamSerdeProvider, resolveEventStreamSerdeConfig } = require("@smithy/core/event-streams");const { parseUrl, getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig, getContentLengthPlugin } = require("@smithy/core/protocols");const { DEFAULT_RETRY_MODE, NODE_RETRY_MODE_CONFIG_OPTIONS, NODE_MAX_ATTEMPT_CONFIG_OPTIONS, resolveRetryConfig, getRetryPlugin } = require("@smithy/core/retry");const { TypeRegistry, getSchemaSerdePlugin } = require("@smithy/core/schema");const { resolveAwsSdkSigV4Config, AwsSdkSigV4Signer, NODE_AUTH_SCHEME_PREFERENCE_OPTIONS } = require("@aws-sdk/core/httpAuthSchemes");const { defaultProvider } = require("@aws-sdk/credential-provider-node");const { eventStreamPayloadHandlerProvider } = require("@aws-sdk/eventstream-handler-node");const { toUtf8, fromUtf8, toBase64, fromBase64, calculateBodyLength } = require("@smithy/core/serde");const { streamCollector, NodeHttpHandler } = require("@smithy/node-http-handler");const { AwsRestJsonProtocol } = require("@aws-sdk/core/protocols");const { Sha256 } = require("@smithy/core/checksum"); const defaultRekognitionStreamingHttpAuthSchemeParametersProvider = async (config, context, input) => {    return {        operation: getSmithyContext(context).operation,        region: await normalizeProvider(config.region)() || (() => {            throw new Error("expected `region` to be configured for `aws.auth#sigv4`");        })(),    };};function createAwsAuthSigv4HttpAuthOption(authParameters) {    return {        schemeId: "aws.auth#sigv4",        signingProperties: {            name: "rekognition",            region: authParameters.region,        },        propertiesExtractor: (config, context) => ({            signingProperties: {                config,                context,            },        }),    };}const defaultRekognitionStreamingHttpAuthSchemeProvider = (authParameters) => {    const options = [];    switch (authParameters.operation) {        default: {            options.push(createAwsAuthSigv4HttpAuthOption(authParameters));        }    }    return options;};const resolveHttpAuthSchemeConfig = (config) => {    const config_0 = resolveAwsSdkSigV4Config(config);    return Object.assign(config_0, {        authSchemePreference: normalizeProvider(config.authSchemePreference ?? []),    });}; const resolveClientEndpointParameters = (options) => {    return Object.assign(options, {        useDualstackEndpoint: options.useDualstackEndpoint ?? false,        useFipsEndpoint: options.useFipsEndpoint ?? false,        defaultSigningName: "rekognition",    });};const commonParams = {    UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },    Endpoint: { type: "builtInParams", name: "endpoint" },    Region: { type: "builtInParams", name: "region" },    UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" },}; var version = "3.1104.0";var packageInfo = {	version: version}; const k = "ref";const a = -1, b = true, c = "isSet", d = "PartitionResult", e = "booleanEquals", f = "getAttr", g = { [k]: "Endpoint" }, h = { [k]: d }, i = {}, j = [{ [k]: "Region" }];const _data = {    conditions: [        [c, [g]],        [c, j],        ["aws.partition", j, d],        [e, [{ [k]: "UseFIPS" }, b]],        [e, [{ [k]: "UseDualStack" }, b]],        [e, [{ fn: f, argv: [h, "supportsDualStack"] }, b]],        [e, [{ fn: f, argv: [h, "supportsFIPS"] }, b]]    ],    results: [        [a],        [a, "Invalid Configuration: FIPS and custom endpoint are not supported"],        [a, "Invalid Configuration: Dualstack and custom endpoint are not supported"],        [g, i],        ["https://streaming-rekognition-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", i],        [a, "FIPS and DualStack are enabled, but this partition does not support one or both"],        ["https://streaming-rekognition-fips.{Region}.{PartitionResult#dnsSuffix}", i],        [a, "FIPS is enabled but this partition does not support FIPS"],        ["https://streaming-rekognition.{Region}.{PartitionResult#dualStackDnsSuffix}", i],        [a, "DualStack is enabled but this partition does not support DualStack"],        ["https://streaming-rekognition.{Region}.{PartitionResult#dnsSuffix}", i],        [a, "Invalid Configuration: Missing Region"]    ]};const root = 2;const r = 100_000_000;const nodes = new Int32Array([    -1, 1, -1,    0, 12, 3,    1, 4, r + 11,    2, 5, r + 11,    3, 8, 6,    4, 7, r + 10,    5, r + 8, r + 9,    4, 10, 9,    6, r + 6, r + 7,    5, 11, r + 5,    6, r + 4, r + 5,    3, r + 1, 13,    4, r + 2, r + 3,]);const bdd = BinaryDecisionDiagram.from(nodes, root, _data.conditions, _data.results); const cache = new EndpointCache({    size: 50,    params: ["Endpoint", "Region", "UseDualStack", "UseFIPS"],});const defaultEndpointResolver = (endpointParams, context = {}) => {    return cache.get(endpointParams, () => decideEndpoint(bdd, {        endpointParams: endpointParams,        logger: context.logger,    }));};customEndpointFunctions.aws = awsEndpointFunctions; class RekognitionStreamingServiceException extends ServiceException {    constructor(options) {        super(options);        Object.setPrototypeOf(this, RekognitionStreamingServiceException.prototype);    }} class AccessDeniedException extends RekognitionStreamingServiceException {    name = "AccessDeniedException";    $fault = "client";    Message;    Code;    constructor(opts) {        super({            name: "AccessDeniedException",            $fault: "client",            ...opts,        });        Object.setPrototypeOf(this, AccessDeniedException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }}class InternalServerException extends RekognitionStreamingServiceException {    name = "InternalServerException";    $fault = "server";    Message;    Code;    constructor(opts) {        super({            name: "InternalServerException",            $fault: "server",            ...opts,        });        Object.setPrototypeOf(this, InternalServerException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }}class ServiceQuotaExceededException extends RekognitionStreamingServiceException {    name = "ServiceQuotaExceededException";    $fault = "client";    Message;    Code;    constructor(opts) {        super({            name: "ServiceQuotaExceededException",            $fault: "client",            ...opts,        });        Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }}class ServiceUnavailableException extends RekognitionStreamingServiceException {    name = "ServiceUnavailableException";    $fault = "server";    Message;    Code;    constructor(opts) {        super({            name: "ServiceUnavailableException",            $fault: "server",            ...opts,        });        Object.setPrototypeOf(this, ServiceUnavailableException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }}class ThrottlingException extends RekognitionStreamingServiceException {    name = "ThrottlingException";    $fault = "client";    Message;    Code;    constructor(opts) {        super({            name: "ThrottlingException",            $fault: "client",            ...opts,        });        Object.setPrototypeOf(this, ThrottlingException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }}class ValidationException extends RekognitionStreamingServiceException {    name = "ValidationException";    $fault = "client";    Message;    Code;    constructor(opts) {        super({            name: "ValidationException",            $fault: "client",            ...opts,        });        Object.setPrototypeOf(this, ValidationException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }}class SessionNotFoundException extends RekognitionStreamingServiceException {    name = "SessionNotFoundException";    $fault = "client";    Message;    Code;    constructor(opts) {        super({            name: "SessionNotFoundException",            $fault: "client",            ...opts,        });        Object.setPrototypeOf(this, SessionNotFoundException.prototype);        this.Message = opts.Message;        this.Code = opts.Code;    }} const _ADE = "AccessDeniedException";const _BB = "BoundingBox";const _BFDT = "BlazeFaceDetectionThreshold";const _C = "Code";const _CC = "ChallengeConfig";const _CCST = "CurrentColorStartTimestamp";const _CCl = "ClientChallenge";const _CCu = "CurrentColor";const _CD = "ColorDisplayed";const _CE = "ChallengeEvent";const _CI = "ChallengeId";const _CS = "ColorSequence";const _CSIE = "ClientSessionInformationEvent";const _CSo = "ColorSequences";const _CV = "ChallengeVersions";const _CX = "CenterX";const _CY = "CenterY";const _Ch = "Challenge";const _DD = "DownscrollDuration";const _DE = "DisconnectionEvent";const _FC = "FreshnessColor";const _FDD = "FlatDisplayDuration";const _FDITPET = "FaceDetectedInTargetPositionEndTimestamp";const _FDITPST = "FaceDetectedInTargetPositionStartTimestamp";const _FDT = "FaceDistanceThreshold";const _FDTM = "FaceDistanceThresholdMin";const _FDTMa = "FaceDistanceThresholdMax";const _FIHT = "FaceIouHeightThreshold";const _FIWT = "FaceIouWidthThreshold";const _FMALC = "FaceMovementAndLightChallenge";const _FMALCC = "FaceMovementAndLightClientChallenge";const _FMALSC = "FaceMovementAndLightServerChallenge";const _FMC = "FaceMovementChallenge";const _FMCC = "FaceMovementClientChallenge";const _FMSC = "FaceMovementServerChallenge";const _H = "Height";const _IF = "InitialFace";const _IFDT = "InitialFaceDetectedTimestamp";const _ISE = "InternalServerException";const _L = "Left";const _LCT = "LightChallengeType";const _LRS = "LivenessRequestStream";const _LRSi = "LivenessResponseStream";const _M = "Message";const _OFT = "OvalFitTimeout";const _OHWR = "OvalHeightWidthRatio";const _OIHT = "OvalIouHeightThreshold";const _OIT = "OvalIouThreshold";const _OIWT = "OvalIouWidthThreshold";const _OP = "OvalParameters";const _PC = "PreviousColor";const _RGB = "RGB";const _SC = "ServerChallenge";const _SFLS = "StartFaceLivenessSession";const _SFLSR = "StartFaceLivenessSessionRequest";const _SFLSRt = "StartFaceLivenessSessionResponse";const _SI = "SessionInformation";const _SIe = "SessionId";const _SN = "SequenceNumber";const _SNFE = "SessionNotFoundException";const _SQEE = "ServiceQuotaExceededException";const _SSIE = "ServerSessionInformationEvent";const _SUE = "ServiceUnavailableException";const _T = "Top";const _TE = "ThrottlingException";const _TF = "TargetFace";const _TM = "TimestampMillis";const _Ty = "Type";const _V = "Version";const _VC = "VideoChunk";const _VE = "ValidationException";const _VET = "VideoEndTimestamp";const _VEi = "VideoEvent";const _VH = "VideoHeight";const _VST = "VideoStartTimestamp";const _VW = "VideoWidth";const _W = "Width";const _c = "client";const _e = "error";const _h = "http";const _hE = "httpError";const _hH = "httpHeader";const _s = "smithy.ts.sdk.synthetic.com.amazonaws.rekognitionstreaming";const _se = "server";const _st = "streaming";const _xarslcv = "x-amz-rekognition-streaming-liveness-challenge-versions";const _xarslsi = "x-amz-rekognition-streaming-liveness-session-id";const _xarslvh = "x-amz-rekognition-streaming-liveness-video-height";const _xarslvw = "x-amz-rekognition-streaming-liveness-video-width";const n0 = "com.amazonaws.rekognitionstreaming";const _s_registry = TypeRegistry.for(_s);var RekognitionStreamingServiceException$ = [-3, _s, "RekognitionStreamingServiceException", 0, [], []];_s_registry.registerError(RekognitionStreamingServiceException$, RekognitionStreamingServiceException);const n0_registry = TypeRegistry.for(n0);var AccessDeniedException$ = [-3, n0, _ADE,    { [_e]: _c, [_hE]: 403 },    [_M, _C],    [0, 0]];n0_registry.registerError(AccessDeniedException$, AccessDeniedException);var InternalServerException$ = [-3, n0, _ISE,    { [_e]: _se, [_hE]: 500 },    [_M, _C],    [0, 0]];n0_registry.registerError(InternalServerException$, InternalServerException);var ServiceQuotaExceededException$ = [-3, n0, _SQEE,    { [_e]: _c, [_hE]: 429 },    [_M, _C],    [0, 0]];n0_registry.registerError(ServiceQuotaExceededException$, ServiceQuotaExceededException);var ServiceUnavailableException$ = [-3, n0, _SUE,    { [_e]: _se, [_hE]: 503 },    [_M, _C],    [0, 0]];n0_registry.registerError(ServiceUnavailableException$, ServiceUnavailableException);var SessionNotFoundException$ = [-3, n0, _SNFE,    { [_e]: _c, [_hE]: 400 },    [_M, _C],    [0, 0]];n0_registry.registerError(SessionNotFoundException$, SessionNotFoundException);var ThrottlingException$ = [-3, n0, _TE,    { [_e]: _c, [_hE]: 429 },    [_M, _C],    [0, 0]];n0_registry.registerError(ThrottlingException$, ThrottlingException);var ValidationException$ = [-3, n0, _VE,    { [_e]: _c, [_hE]: 400 },    [_M, _C],    [0, 0]];n0_registry.registerError(ValidationException$, ValidationException);const errorTypeRegistries = [    _s_registry,    n0_registry,];var BoundingBox$ = [3, n0, _BB,    0,    [_W, _H, _L, _T],    [1, 1, 1, 1], 4];var ChallengeConfig$ = [3, n0, _CC,    0,    [_BFDT, _FDTM, _FDT, _FDTMa, _OIT, _OHWR, _OIWT, _OIHT, _FIWT, _FIHT, _OFT],    [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];var ChallengeEvent$ = [3, n0, _CE,    0,    [_V, _Ty],    [0, 0], 2];var ClientSessionInformationEvent$ = [3, n0, _CSIE,    0,    [_Ch],    [() => ClientChallenge$], 1];var ColorDisplayed$ = [3, n0, _CD,    0,    [_CCu, _SN, _CCST, _PC],    [() => FreshnessColor$, 1, 1, () => FreshnessColor$], 3];var ColorSequence$ = [3, n0, _CS,    0,    [_FC, _DD, _FDD],    [() => FreshnessColor$, 1, 1], 3];var DisconnectionEvent$ = [3, n0, _DE,    0,    [_TM],    [1], 1];var FaceMovementAndLightClientChallenge$ = [3, n0, _FMALCC,    0,    [_CI, _VST, _VET, _IF, _TF, _CD],    [0, 1, 1, () => InitialFace$, () => TargetFace$, () => ColorDisplayed$], 1];var FaceMovementAndLightServerChallenge$ = [3, n0, _FMALSC,    0,    [_OP, _LCT, _CC, _CSo],    [() => OvalParameters$, 0, () => ChallengeConfig$, () => ColorSequences], 4];var FaceMovementClientChallenge$ = [3, n0, _FMCC,    0,    [_CI, _VST, _VET, _IF, _TF],    [0, 1, 1, () => InitialFace$, () => TargetFace$], 1];var FaceMovementServerChallenge$ = [3, n0, _FMSC,    0,    [_OP, _CC],    [() => OvalParameters$, () => ChallengeConfig$], 2];var FreshnessColor$ = [3, n0, _FC,    0,    [_RGB],    [64 | 1], 1];var InitialFace$ = [3, n0, _IF,    0,    [_BB, _IFDT],    [() => BoundingBox$, 1], 2];var OvalParameters$ = [3, n0, _OP,    0,    [_W, _H, _CX, _CY],    [1, 1, 1, 1], 4];var ServerSessionInformationEvent$ = [3, n0, _SSIE,    0,    [_SI],    [() => SessionInformation$], 1];var SessionInformation$ = [3, n0, _SI,    0,    [_Ch],    [() => ServerChallenge$], 1];var StartFaceLivenessSessionRequest$ = [3, n0, _SFLSR,    0,    [_SIe, _VW, _VH, _CV, _LRS],    [[0, { [_hH]: _xarslsi }], [0, { [_hH]: _xarslvw }], [0, { [_hH]: _xarslvh }], [0, { [_hH]: _xarslcv }], [() => LivenessRequestStream$, 16]], 4];var StartFaceLivenessSessionResponse$ = [3, n0, _SFLSRt,    0,    [_SIe, _LRSi],    [[0, { [_hH]: _xarslsi }], [() => LivenessResponseStream$, 16]], 1];var TargetFace$ = [3, n0, _TF,    0,    [_BB, _FDITPST, _FDITPET],    [() => BoundingBox$, 1, 1], 3];var VideoEvent$ = [3, n0, _VEi,    0,    [_VC, _TM],    [21, 1]];var ColorSequences = [1, n0, _CSo,    0, () => ColorSequence$];var ClientChallenge$ = [4, n0, _CCl,    0,    [_FMALC, _FMC],    [() => FaceMovementAndLightClientChallenge$, () => FaceMovementClientChallenge$]];var LivenessRequestStream$ = [4, n0, _LRS,    { [_st]: 1 },    [_VEi, _CSIE],    [() => VideoEvent$, () => ClientSessionInformationEvent$]];var LivenessResponseStream$ = [4, n0, _LRSi,    { [_st]: 1 },    [_SSIE, _DE, _CE, _VE, _ISE, _TE, _SQEE, _SUE],    [() => ServerSessionInformationEvent$, () => DisconnectionEvent$, () => ChallengeEvent$, [() => ValidationException$, 0], [() => InternalServerException$, 0], [() => ThrottlingException$, 0], [() => ServiceQuotaExceededException$, 0], [() => ServiceUnavailableException$, 0]]];var ServerChallenge$ = [4, n0, _SC,    0,    [_FMALC, _FMC],    [() => FaceMovementAndLightServerChallenge$, () => FaceMovementServerChallenge$]];var StartFaceLivenessSession$ = [9, n0, _SFLS,    { [_h]: ["POST", "/start-face-liveness-session", 200] }, () => StartFaceLivenessSessionRequest$, () => StartFaceLivenessSessionResponse$]; const getRuntimeConfig$1 = (config) => {    return {        apiVersion: "2022-05-30",        base64Decoder: config?.base64Decoder ?? fromBase64,        base64Encoder: config?.base64Encoder ?? toBase64,        disableHostPrefix: config?.disableHostPrefix ?? false,        endpointProvider: config?.endpointProvider ?? defaultEndpointResolver,        extensions: config?.extensions ?? [],        httpAuthSchemeProvider: config?.httpAuthSchemeProvider ?? defaultRekognitionStreamingHttpAuthSchemeProvider,        httpAuthSchemes: config?.httpAuthSchemes ?? [            {                schemeId: "aws.auth#sigv4",                identityProvider: (ipc) => ipc.getIdentityProvider("aws.auth#sigv4"),                signer: new AwsSdkSigV4Signer(),            },        ],        logger: config?.logger ?? new NoOpLogger(),        protocol: config?.protocol ?? AwsRestJsonProtocol,        protocolSettings: config?.protocolSettings ?? {            defaultNamespace: "com.amazonaws.rekognitionstreaming",            errorTypeRegistries,            version: "2022-05-30",            serviceTarget: "RekognitionStreamingService",        },        serviceId: config?.serviceId ?? "RekognitionStreaming",        sha256: config?.sha256 ?? Sha256,        urlParser: config?.urlParser ?? parseUrl,        utf8Decoder: config?.utf8Decoder ?? fromUtf8,        utf8Encoder: config?.utf8Encoder ?? toUtf8,    };}; const getRuntimeConfig = (config) => {    emitWarningIfUnsupportedVersion(process.version);    const defaultsMode = resolveDefaultsModeConfig(config);    const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);    const clientSharedValues = getRuntimeConfig$1(config);    emitWarningIfUnsupportedVersion$1(process.version);    const loaderConfig = {        profile: config?.profile,        logger: clientSharedValues.logger,    };    return {        ...clientSharedValues,        ...config,        runtime: "node",        defaultsMode,        authSchemePreference: config?.authSchemePreference ?? loadConfig(NODE_AUTH_SCHEME_PREFERENCE_OPTIONS, loaderConfig),        bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,        credentialDefaultProvider: config?.credentialDefaultProvider ?? defaultProvider,        defaultUserAgentProvider: config?.defaultUserAgentProvider ?? createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),        eventStreamPayloadHandlerProvider: config?.eventStreamPayloadHandlerProvider ?? eventStreamPayloadHandlerProvider,        eventStreamSerdeProvider: config?.eventStreamSerdeProvider ?? eventStreamSerdeProvider,        maxAttempts: config?.maxAttempts ?? loadConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS, config),        region: config?.region ?? loadConfig(NODE_REGION_CONFIG_OPTIONS, { ...NODE_REGION_CONFIG_FILE_OPTIONS, ...loaderConfig }),        requestHandler: NodeHttpHandler.create(config?.requestHandler ?? defaultConfigProvider),        retryMode: config?.retryMode ??            loadConfig({                ...NODE_RETRY_MODE_CONFIG_OPTIONS,                default: async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE,            }, config),        streamCollector: config?.streamCollector ?? streamCollector,        useDualstackEndpoint: config?.useDualstackEndpoint ?? loadConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, loaderConfig),        useFipsEndpoint: config?.useFipsEndpoint ?? loadConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, loaderConfig),        userAgentAppId: config?.userAgentAppId ?? loadConfig(NODE_APP_ID_CONFIG_OPTIONS, loaderConfig),    };}; const getHttpAuthExtensionConfiguration = (runtimeConfig) => {    const _httpAuthSchemes = runtimeConfig.httpAuthSchemes;    let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider;    let _credentials = runtimeConfig.credentials;    return {        setHttpAuthScheme(httpAuthScheme) {            const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId);            if (index === -1) {                _httpAuthSchemes.push(httpAuthScheme);            }            else {                _httpAuthSchemes.splice(index, 1, httpAuthScheme);            }        },        httpAuthSchemes() {            return _httpAuthSchemes;        },        setHttpAuthSchemeProvider(httpAuthSchemeProvider) {            _httpAuthSchemeProvider = httpAuthSchemeProvider;        },        httpAuthSchemeProvider() {            return _httpAuthSchemeProvider;        },        setCredentials(credentials) {            _credentials = credentials;        },        credentials() {            return _credentials;        },    };};const resolveHttpAuthRuntimeConfig = (config) => {    return {        httpAuthSchemes: config.httpAuthSchemes(),        httpAuthSchemeProvider: config.httpAuthSchemeProvider(),        credentials: config.credentials(),    };}; const resolveRuntimeExtensions = (runtimeConfig, extensions) => {    const extensionConfiguration = Object.assign(getAwsRegionExtensionConfiguration(runtimeConfig), getDefaultExtensionConfiguration(runtimeConfig), getHttpHandlerExtensionConfiguration(runtimeConfig), getHttpAuthExtensionConfiguration(runtimeConfig));    extensions.forEach((extension) => extension.configure(extensionConfiguration));    return Object.assign(runtimeConfig, resolveAwsRegionExtensionConfiguration(extensionConfiguration), resolveDefaultRuntimeConfig(extensionConfiguration), resolveHttpHandlerRuntimeConfig(extensionConfiguration), resolveHttpAuthRuntimeConfig(extensionConfiguration));}; class RekognitionStreamingClient extends Client {    config;    constructor(...[configuration]) {        const _config_0 = getRuntimeConfig(configuration || {});        super(_config_0);        this.initConfig = _config_0;        const _config_1 = resolveClientEndpointParameters(_config_0);        const _config_2 = resolveUserAgentConfig(_config_1);        const _config_3 = resolveRetryConfig(_config_2);        const _config_4 = resolveRegionConfig(_config_3);        const _config_5 = resolveHostHeaderConfig(_config_4);        const _config_6 = resolveEndpointConfig(_config_5);        const _config_7 = resolveEventStreamSerdeConfig(_config_6);        const _config_8 = resolveHttpAuthSchemeConfig(_config_7);        const _config_9 = resolveEventStreamConfig(_config_8);        const _config_10 = resolveWebSocketConfig(_config_9);        const _config_11 = resolveRuntimeExtensions(_config_10, configuration?.extensions || []);        this.config = _config_11;        this.middlewareStack.use(getSchemaSerdePlugin(this.config));        this.middlewareStack.use(getUserAgentPlugin(this.config));        this.middlewareStack.use(getRetryPlugin(this.config));        this.middlewareStack.use(getContentLengthPlugin(this.config));        this.middlewareStack.use(getHostHeaderPlugin(this.config));        this.middlewareStack.use(getLoggerPlugin(this.config));        this.middlewareStack.use(getRecursionDetectionPlugin(this.config));        this.middlewareStack.use(getHttpAuthSchemeEndpointRuleSetPlugin(this.config, {            httpAuthSchemeParametersProvider: defaultRekognitionStreamingHttpAuthSchemeParametersProvider,            identityProviderConfigProvider: async (config) => new DefaultIdentityProviderConfig({                "aws.auth#sigv4": config.credentials,            }),        }));        this.middlewareStack.use(getHttpSigningPlugin(this.config));    }    destroy() {        super.destroy();    }} const command = makeBuilder(commonParams, "RekognitionStreamingService", "RekognitionStreamingClient", getEndpointPlugin);const _ep0 = {};const _mw0 = (Command, cs, config, o) => [    getEventStreamPlugin(config),    getWebSocketPlugin(config, {        headerPrefix: "x-amz-rekognition-streaming-liveness-",    }),]; class StartFaceLivenessSessionCommand extends command(_ep0, _mw0, "StartFaceLivenessSession", StartFaceLivenessSession$) {} const commands = {    StartFaceLivenessSessionCommand,};class RekognitionStreaming extends RekognitionStreamingClient {}createAggregatedClient(commands, RekognitionStreaming); const ChallengeType = {    FACE_MOVEMENT_AND_LIGHT_CHALLENGE: "FaceMovementAndLightChallenge",    FACE_MOVEMENT_CHALLENGE: "FaceMovementChallenge",};const LightChallengeType = {    SEQUENTIAL: "SEQUENTIAL",}; exports.AccessDeniedException = AccessDeniedException;exports.AccessDeniedException$ = AccessDeniedException$;exports.BoundingBox$ = BoundingBox$;exports.ChallengeConfig$ = ChallengeConfig$;exports.ChallengeEvent$ = ChallengeEvent$;exports.ChallengeType = ChallengeType;exports.ClientChallenge$ = ClientChallenge$;exports.ClientSessionInformationEvent$ = ClientSessionInformationEvent$;exports.ColorDisplayed$ = ColorDisplayed$;exports.ColorSequence$ = ColorSequence$;exports.DisconnectionEvent$ = DisconnectionEvent$;exports.FaceMovementAndLightClientChallenge$ = FaceMovementAndLightClientChallenge$;exports.FaceMovementAndLightServerChallenge$ = FaceMovementAndLightServerChallenge$;exports.FaceMovementClientChallenge$ = FaceMovementClientChallenge$;exports.FaceMovementServerChallenge$ = FaceMovementServerChallenge$;exports.FreshnessColor$ = FreshnessColor$;exports.InitialFace$ = InitialFace$;exports.InternalServerException = InternalServerException;exports.InternalServerException$ = InternalServerException$;exports.LightChallengeType = LightChallengeType;exports.LivenessRequestStream$ = LivenessRequestStream$;exports.LivenessResponseStream$ = LivenessResponseStream$;exports.OvalParameters$ = OvalParameters$;exports.RekognitionStreaming = RekognitionStreaming;exports.RekognitionStreamingClient = RekognitionStreamingClient;exports.RekognitionStreamingServiceException = RekognitionStreamingServiceException;exports.RekognitionStreamingServiceException$ = RekognitionStreamingServiceException$;exports.ServerChallenge$ = ServerChallenge$;exports.ServerSessionInformationEvent$ = ServerSessionInformationEvent$;exports.ServiceQuotaExceededException = ServiceQuotaExceededException;exports.ServiceQuotaExceededException$ = ServiceQuotaExceededException$;exports.ServiceUnavailableException = ServiceUnavailableException;exports.ServiceUnavailableException$ = ServiceUnavailableException$;exports.SessionInformation$ = SessionInformation$;exports.SessionNotFoundException = SessionNotFoundException;exports.SessionNotFoundException$ = SessionNotFoundException$;exports.StartFaceLivenessSession$ = StartFaceLivenessSession$;exports.StartFaceLivenessSessionCommand = StartFaceLivenessSessionCommand;exports.StartFaceLivenessSessionRequest$ = StartFaceLivenessSessionRequest$;exports.StartFaceLivenessSessionResponse$ = StartFaceLivenessSessionResponse$;exports.TargetFace$ = TargetFace$;exports.ThrottlingException = ThrottlingException;exports.ThrottlingException$ = ThrottlingException$;exports.ValidationException = ValidationException;exports.ValidationException$ = ValidationException$;exports.VideoEvent$ = VideoEvent$;exports.errorTypeRegistries = errorTypeRegistries;