Optionalconfig: SessionConfigInputNumber of active sessions
Current statistics
Broadcasts prompt list changed notification to all sessions. Called when dynamic prompts are added/removed.
Broadcasts resource list changed notification to all sessions. Called when dynamic resources are added/removed.
Sends a resource updated notification to sessions subscribed to the given URI.
Only sessions that have called resources/subscribe for this URI receive
the notifications/resources/updated notification.
Broadcasts tool list changed notification to all sessions. Called when dynamic tools are added/removed.
Closes and removes a specific session.
Session identifier
Reason for closure
Closes all sessions during shutdown.
Creates and registers a new session.
Session creation options
The created session, or undefined if at capacity
Disposes of the manager and stops background tasks.
Finds sessions matching a predicate.
Filter function
Array of matching sessions
Iterates over all active sessions.
Function to call for each session
Gets a session by ID. Does NOT update activity time (use touch() for that).
Session identifier
The session if found and active
Gets all sessions of a specific transport type.
Transport type to filter by
Checks if a session exists and is active.
Session identifier
Checks if there's capacity for new sessions.
Checks if there's capacity for a specific transport type. Enforces per-transport limits from config.
Updates the last activity time for a session. Also resets missed heartbeat count.
Session identifier
true if session was touched
Facade implementation of SessionManager.
Delegates to:
Example