AgentDetector
TheAgentDetector is the main entry point for interacting with the Superline Agent Detection library. It manages the initialization, configuration, and detection process.
You need to create an instance of this class, providing necessary providers.
Constructor
Creates a new agent detector instance.Instance Methods
init
Initializes the agent detector instance with the provided configuration.startDetection
Starts the detection process, initializing all extractors and beginning data collection.getCurrentDetectionResult
Gets the current detection result based on data collected so far. Does not stop the detection process or remove event listeners.finalizeDetection
Finalizes the detection process, computes a final result based on collected data, and cleans up listeners. Stops collecting new events but keeps the current session data.cleanup
Cleans up all resources used by the agent detector instance. Stops all event listeners and clears stored session events.cleanupOldEvents
Cleans up old events from storage based on age. Helps manage storage size.Next Steps
Detection Result
Learn more about the detection result object
Configuration
Explore all configuration options for the init method