agentic-browser 2.2.0 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +1 -1
- package/README.md +5 -2
- package/dist/cli/index.d.mts +2 -0
- package/dist/cli/index.mjs +2 -2
- package/dist/index.d.mts +928 -0
- package/dist/index.mjs +1 -1
- package/dist/mcp/index.d.mts +5 -0
- package/dist/mcp/index.mjs +67 -3
- package/dist/{runtime-CRkUsvhV.mjs → runtime-PnWvjdzU.mjs} +502 -19
- package/package.json +34 -8
package/AGENTS.md
CHANGED
|
@@ -108,7 +108,7 @@ AgenticBrowserCore → ControlApi → SessionManager → BrowserController (CDP)
|
|
|
108
108
|
|
|
109
109
|
## Environment Variables
|
|
110
110
|
|
|
111
|
-
- `
|
|
111
|
+
- `AGENTIC_BROWSER_DIR` — base dir for sessions/memory/events (default: `~/.agentic-browser`)
|
|
112
112
|
- `AGENTIC_BROWSER_CHROME_EXECUTABLE_PATH` — explicit Chrome path (auto-discovered if not set)
|
|
113
113
|
- `AGENTIC_BROWSER_CDP_URL` — connect to an already-running Chrome via CDP (e.g. `http://127.0.0.1:9222`)
|
|
114
114
|
- `AGENTIC_BROWSER_USER_PROFILE` — use real Chrome profile (`default`, `true`, or absolute path)
|
package/README.md
CHANGED
|
@@ -264,10 +264,14 @@ agentic-browser memory:stats
|
|
|
264
264
|
5. `agent memory-search` — reuse known selectors for repeated tasks.
|
|
265
265
|
6. `agent stop` — terminate when done.
|
|
266
266
|
|
|
267
|
+
## Anti-Detection
|
|
268
|
+
|
|
269
|
+
Chrome is launched with stealth flags (`--disable-blink-features=AutomationControlled`, `--disable-infobars`, `--excludeSwitches=enable-automation`) and runtime patches that remove `navigator.webdriver`, fake plugins and languages, patch `chrome.runtime`, clean `Function.prototype.toString`, and patch `Permissions.query`. The `HeadlessChrome` token is automatically stripped from the user-agent string. Stealth is always on — no configuration needed.
|
|
270
|
+
|
|
267
271
|
## Important Notes for LLMs
|
|
268
272
|
|
|
269
273
|
- Exactly **one** managed session is supported at a time.
|
|
270
|
-
- Session state is persisted in
|
|
274
|
+
- Session state is persisted in `~/.agentic-browser/` (override with `AGENTIC_BROWSER_DIR`).
|
|
271
275
|
- All commands print exactly one JSON line to `stdout`.
|
|
272
276
|
- The typed `agent` commands are the preferred interface for LLMs. Use low-level `command:run` only when you need raw JSON payload control.
|
|
273
277
|
- Parse only `stdout` as result object and use exit code for success/failure.
|
|
@@ -282,7 +286,6 @@ const session = await core.startSession();
|
|
|
282
286
|
|
|
283
287
|
await core.runCommand({
|
|
284
288
|
sessionId: session.sessionId,
|
|
285
|
-
commandId: "cmd-1",
|
|
286
289
|
type: "navigate",
|
|
287
290
|
payload: { url: "https://example.com" },
|
|
288
291
|
});
|
package/dist/cli/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { r as createCliRuntime } from "../runtime-
|
|
2
|
+
import { r as createCliRuntime } from "../runtime-PnWvjdzU.mjs";
|
|
3
3
|
import fs from "node:fs";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
import crypto from "node:crypto";
|
|
@@ -7,7 +7,7 @@ import { Command } from "commander";
|
|
|
7
7
|
//#region src/cli/commands/agent.ts
|
|
8
8
|
const STATE_FILE_NAME = "agent-state.json";
|
|
9
9
|
function stateFilePath(runtime) {
|
|
10
|
-
return path.join(runtime.context.config.
|
|
10
|
+
return path.join(runtime.context.config.dataDir, STATE_FILE_NAME);
|
|
11
11
|
}
|
|
12
12
|
function loadState(runtime) {
|
|
13
13
|
const filePath = stateFilePath(runtime);
|