mcpwn API
    Preparing search index...

    Function loadDetectorPlugin

    • Load a custom Detector from path. The module (or its default export) must be an object exposing a name:string and an inspect(flow, sink) — or visit(flow, sink) — method matching detect/detector.ts. Returns a Detector that delegates to it; isolation is provided by the pipeline, which wraps every detector call in try/catch. Throws a clear error when the module is missing or does not implement the interface.

      Parameters

      • path: string

      Returns Promise<Detector & { name: string }>