@mercuryo-ai/agentbrowse-cli 0.1.7 → 0.1.8

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.
Files changed (2) hide show
  1. package/README.md +57 -30
  2. package/package.json +4 -4
package/README.md CHANGED
@@ -1,59 +1,86 @@
1
1
  # @mercuryo-ai/agentbrowse-cli
2
2
 
3
- Browser-only CLI for AI agents.
3
+ Browser automation CLI for AI agents.
4
4
 
5
- Choose this package when the task is navigation, observation, extraction, or
6
- browser actions on visible page state. If the task includes protected login,
7
- identity, or payment forms, pair it with `@mercuryo-ai/magicpay-cli` or use
8
- `@mercuryo-ai/magicpay-agent-cli`.
5
+ AgentBrowse CLI is the operator-facing way to work with a real web page.
9
6
 
10
- ## Before You Start
7
+ Use it when you need to:
11
8
 
12
- - Node.js 18 or newer
13
- - A MagicPay account. Create it at `https://agents.mercuryo.io/signup`, then
14
- create an API key in the dashboard.
15
- - A browser the agent can launch itself or attach to over the Chrome DevTools
16
- Protocol (CDP)
9
+ - launch a browser or attach to an existing CDP session;
10
+ - inspect the current page and act on visible controls;
11
+ - navigate directly to a known URL;
12
+ - extract structured data from the page;
13
+ - capture screenshots or recover a stuck browser session.
17
14
 
18
- ## Install And Initialize
15
+ AgentBrowse works well as a standalone browser tool. It can also sit next to
16
+ MagicPay when a broader flow later reaches a protected login, identity, or
17
+ payment step.
18
+
19
+ Open source:
20
+
21
+ - library and docs: `https://github.com/MercuryoAI/agentbrowse`
22
+
23
+ ## Install
19
24
 
20
25
  ```bash
21
26
  npm i -g @mercuryo-ai/agentbrowse-cli@latest
22
- agentbrowse init <magicpay-api-key>
23
- agentbrowse --version
24
27
  ```
25
28
 
26
- `agentbrowse init` stores the shared MagicPay config used by goal-based
27
- `observe` and `extract`. After setup, start a fresh agent session if the new
28
- CLI is not visible immediately.
29
+ ## Core Loop
29
30
 
30
- ## Verify And First Use
31
+ 1. `agentbrowse launch [url]` or `agentbrowse attach <cdp-url>`
32
+ 2. `agentbrowse observe`
33
+ 3. `agentbrowse act <targetRef> <action> [value]`
34
+ 4. repeat `observe` after meaningful page changes
35
+ 5. `agentbrowse navigate <url>` if the destination is already known
36
+ 6. `agentbrowse extract '<schema-json>' [scopeRef]` when you need structured
37
+ output
38
+ 7. `agentbrowse screenshot` or `agentbrowse browser-status` for evidence and
39
+ debugging
40
+ 8. `agentbrowse close` when you are done
31
41
 
32
- Verify the install first:
42
+ ## When You Need API Setup
43
+
44
+ Simple browser tasks work without API setup.
45
+
46
+ Goal-based `observe` and `extract` use the shared agent config. Set it up once
47
+ with:
33
48
 
34
49
  ```bash
35
- agentbrowse --version
50
+ agentbrowse init <api-key>
36
51
  ```
37
52
 
38
- Then run a simple browser-only task:
53
+ You can also provide `MAGICPAY_API_KEY` in the environment. Use
54
+ `agentbrowse doctor` only if semantic commands still fail after `init` and you
55
+ want to inspect `~/.magicpay/config.json`.
56
+
57
+ ## First Task
58
+
59
+ Start with a plain browser task:
39
60
 
40
61
  ```bash
41
62
  agentbrowse launch "https://example.com"
42
- agentbrowse observe "find the next visible action to continue"
63
+ agentbrowse observe
43
64
  ```
44
65
 
45
- Use `agentbrowse doctor` only when `init` succeeded but goal-based `observe` or
46
- `extract` still fail because the local MagicPay config looks wrong.
66
+ If you want a focused or structured result:
67
+
68
+ ```bash
69
+ agentbrowse init <api-key>
70
+ agentbrowse observe "find the next visible action to continue"
71
+ agentbrowse extract '{"summary":"string"}'
72
+ ```
47
73
 
48
74
  ## Command Groups
49
75
 
50
- - Setup: `init`, `doctor`
51
- - Browser lifecycle: `launch`, `attach`, `browser-status`, `close`
52
- - Task loop: `navigate`, `observe`, `act`, `extract`, `screenshot`
76
+ - Session setup: `launch`, `attach`, `navigate`
77
+ - Page work: `observe`, `act`, `extract`
78
+ - Diagnostics and cleanup: `screenshot`, `browser-status`, `close`
79
+ - Semantic runtime setup: `init`, `doctor`, `--version`
53
80
 
54
- ## Choose Another Package When
81
+ ## Companion Tools
55
82
 
56
- - You already have the browser on a protected login, identity, or payment form:
83
+ - If the page is already at a protected login, identity, or payment form:
57
84
  use `@mercuryo-ai/magicpay-cli`
58
- - You want one CLI that covers both browser work and protected fills:
85
+ - If one CLI should cover both browser work and protected fills:
59
86
  use `@mercuryo-ai/magicpay-agent-cli`
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mercuryo-ai/agentbrowse-cli",
3
- "version": "0.1.7",
4
- "description": "AgentBrowse CLI browser-only operator shell on the shared MagicPay home",
3
+ "version": "0.1.8",
4
+ "description": "Browser automation CLI for AI agents",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "bin": {
@@ -37,9 +37,9 @@
37
37
  "dependencies": {
38
38
  "@browserbasehq/stagehand": "^3.0.0",
39
39
  "dotenv": "^16.4.0",
40
- "@mercuryo-ai/magicpay-home": "0.1.6",
41
40
  "@mercuryo-ai/agentbrowse": "0.2.53",
42
- "@mercuryo-ai/magicpay-sdk": "0.1.0-test.5"
41
+ "@mercuryo-ai/magicpay-home": "0.1.6",
42
+ "@mercuryo-ai/magicpay-sdk": "0.1.0-test.6"
43
43
  },
44
44
  "devDependencies": {
45
45
  "@types/node": "^22.0.0",