A modern JavaScript library for interacting with the Everything search engine, providing a powerful cross-platform interface to search files on Windows systems.
Everything is a powerful and lightweight file search engine for Windows that instantly finds files and folders by name. This library provides a unified interface to interact with Everything through multiple methods:
- Command line interface
- IPC (Inter-Process Communication)
- HTTP API (via Everything's built-in HTTP server)
- Windows operating system (target system)
- Everything search engine installed on the target Windows system
- Node.js >= 14.0.0 (for Node.js environment)
- Everything HTTP server enabled (for HTTP/browser access)
# npm
$ npm install everything-client
# yarn
$ yarn add everything-client
# pnpm
$ pnpm add everything-client
import { createClient } from "everything-client";
// The client factory automatically selects the best available adapter
const everything = createClient();
// Simple search - returns a promise with results
const results = await everything.search("*.pdf");
console.log(results);
// Advanced search with options
const advancedResults = await everything.search("document", {
matchCase: true,
regex: false,
maxResults: 100,
sortBy: "date",
sortOrder: "desc",
});
// Node.js with specific adapter
import { createClient } from "everything-client";
const everything = createClient({
adapter: "ipc", // Explicitly use IPC adapter
// IPC-specific options
timeout: 5000,
});
// Browser environment
import { createClient } from "everything-client";
const everything = createClient({
adapter: "http", // Only HTTP adapter is available in browsers
serverUrl: "http://localhost:8080", // Optional - defaults to "http://localhost:8080"
username: "admin", // HTTP authentication username
password: "password", // HTTP authentication password
});
The library provides three adapters to communicate with Everything:
Works in Node.js environments by using child processes to execute Everything commands. Suitable for simple integration scenarios.
import { createCLIAdapter } from "everything-client";
const adapter = createCLIAdapter({
cliPath: "path/to/es.exe", // Optional - defaults to "es" in PATH
timeout: 10000, // Optional - defaults to 10000ms
});
Windows-specific Node.js implementation with direct communication with Everything using Windows messages. This is the highest performance option for Node.js applications on Windows.
import { createIPCAdapter } from "everything-client";
const adapter = createIPCAdapter({
timeout: 5000, // Optional - defaults to 5000ms
});
Works in both Node.js and browser environments by communicating with Everything's built-in HTTP server using ofetch. This adapter is cross-platform and cross-environment compatible.
import { createHTTPAdapter } from "everything-client";
const adapter = createHTTPAdapter({
serverUrl: "http://localhost:8080", // Optional - defaults to "http://localhost:8080"
username: "admin", // Optional - for HTTP authentication
password: "password", // Optional - for HTTP authentication
timeout: 5000, // Optional - defaults to 5000ms
});
- 🚀 Built with modern ESM and TypeScript
- 🔄 Uses ofetch for HTTP communication with better performance and robustness
- 🔌 Dynamically loads optional dependencies for better compatibility
- 📦 Optimized package structure with smaller installation size
See the main project documentation for full API details.