nyx Typedoc
    Preparing search index...

    Interface SessionLimitRule<Types>

    A single concurrency rule within a session limit policy.

    interface SessionLimitRule<Types extends InteractionTypes = InteractionTypes> {
        max: number;
        onExceed: SessionExceedHandler<Types>;
        scope:
            | SessionLimitKeyProvider<Types>
            | ((session: Session<unknown, Types>) => string);
    }

    Type Parameters

    Index
    max: number

    Maximum number of concurrent sessions allowed within the scope.

    The action to take when the limit is exceeded.

    scope:
        | SessionLimitKeyProvider<Types>
        | ((session: Session<unknown, Types>) => string)

    The scope within which to enforce the limit.