frely-cli 0.6.10 → 0.8.3

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 (104) hide show
  1. package/README.md +97 -293
  2. package/README.zh-CN.md +230 -0
  3. package/dist/agent/agent-service.d.ts +77 -0
  4. package/dist/agent/agent-service.js +348 -0
  5. package/dist/agent/agent-service.js.map +1 -0
  6. package/dist/agent/app-install.d.ts +49 -0
  7. package/dist/agent/app-install.js +133 -0
  8. package/dist/agent/app-install.js.map +1 -0
  9. package/dist/agent/app-key.d.ts +14 -0
  10. package/dist/agent/app-key.js +46 -0
  11. package/dist/agent/app-key.js.map +1 -0
  12. package/dist/agent/compose.d.ts +23 -0
  13. package/dist/agent/compose.js +42 -0
  14. package/dist/agent/compose.js.map +1 -0
  15. package/dist/agent/ops-server.d.ts +18 -0
  16. package/dist/agent/ops-server.js +175 -0
  17. package/dist/agent/ops-server.js.map +1 -0
  18. package/dist/agent/ops-stdio.d.ts +5 -0
  19. package/dist/agent/ops-stdio.js +47 -0
  20. package/dist/agent/ops-stdio.js.map +1 -0
  21. package/dist/agent/ops.d.ts +25 -0
  22. package/dist/agent/ops.js +82 -0
  23. package/dist/agent/ops.js.map +1 -0
  24. package/dist/agent/protocol.d.ts +72 -0
  25. package/dist/agent/protocol.js +195 -0
  26. package/dist/agent/protocol.js.map +1 -0
  27. package/dist/agent/supervisor.d.ts +80 -0
  28. package/dist/agent/supervisor.js +278 -0
  29. package/dist/agent/supervisor.js.map +1 -0
  30. package/dist/agent/task-store.d.ts +82 -0
  31. package/dist/agent/task-store.js +220 -0
  32. package/dist/agent/task-store.js.map +1 -0
  33. package/dist/agent/tool-executor.d.ts +28 -0
  34. package/dist/agent/tool-executor.js +113 -0
  35. package/dist/agent/tool-executor.js.map +1 -0
  36. package/dist/agent/worktrees.d.ts +35 -0
  37. package/dist/agent/worktrees.js +143 -0
  38. package/dist/agent/worktrees.js.map +1 -0
  39. package/dist/agent-help.d.ts +200 -176
  40. package/dist/agent-help.js +65 -32
  41. package/dist/agent-help.js.map +1 -1
  42. package/dist/auth.d.ts +3 -0
  43. package/dist/auth.js +52 -14
  44. package/dist/auth.js.map +1 -1
  45. package/dist/cloud.d.ts +1 -1
  46. package/dist/cloud.js +6 -13
  47. package/dist/cloud.js.map +1 -1
  48. package/dist/device/protocol.d.ts +11 -2
  49. package/dist/device/protocol.js +18 -2
  50. package/dist/device/protocol.js.map +1 -1
  51. package/dist/device/relay-client.d.ts +19 -2
  52. package/dist/device/relay-client.js +65 -13
  53. package/dist/device/relay-client.js.map +1 -1
  54. package/dist/diagnostics.js +12 -4
  55. package/dist/diagnostics.js.map +1 -1
  56. package/dist/index.js +203 -173
  57. package/dist/index.js.map +1 -1
  58. package/dist/key-budget.js +2 -2
  59. package/dist/key-budget.js.map +1 -1
  60. package/dist/mcp-authorization.js +9 -7
  61. package/dist/mcp-authorization.js.map +1 -1
  62. package/dist/mcp-command.d.ts +12 -4
  63. package/dist/mcp-command.js +54 -25
  64. package/dist/mcp-command.js.map +1 -1
  65. package/dist/provider/state.d.ts +2 -0
  66. package/dist/provider/state.js +1 -0
  67. package/dist/provider/state.js.map +1 -1
  68. package/dist/runtime/mcp-lease.js +1 -1
  69. package/dist/runtime/mcp-lease.js.map +1 -1
  70. package/dist/runtime/mcp.d.ts +139 -0
  71. package/dist/runtime/mcp.js +88 -29
  72. package/dist/runtime/mcp.js.map +1 -1
  73. package/dist/runtime/process-manager.d.ts +1 -1
  74. package/dist/runtime/process-manager.js +4 -2
  75. package/dist/runtime/process-manager.js.map +1 -1
  76. package/dist/runtime/relay-agent.d.ts +25 -0
  77. package/dist/runtime/relay-agent.js +63 -0
  78. package/dist/runtime/relay-agent.js.map +1 -0
  79. package/dist/runtime/relay-mcp.d.ts +5 -2
  80. package/dist/runtime/relay-mcp.js +6 -1
  81. package/dist/runtime/relay-mcp.js.map +1 -1
  82. package/dist/runtime/relay-session.d.ts +47 -0
  83. package/dist/runtime/relay-session.js +56 -0
  84. package/dist/runtime/relay-session.js.map +1 -0
  85. package/dist/runtime/sandbox.d.ts +16 -0
  86. package/dist/runtime/sandbox.js +149 -0
  87. package/dist/runtime/sandbox.js.map +1 -0
  88. package/dist/runtime/workspace-registry.d.ts +5 -0
  89. package/dist/runtime/workspace-registry.js +87 -0
  90. package/dist/runtime/workspace-registry.js.map +1 -0
  91. package/dist/runtime/workspace-router.d.ts +5 -0
  92. package/dist/runtime/workspace-router.js +32 -0
  93. package/dist/runtime/workspace-router.js.map +1 -0
  94. package/dist/runtime/workspace.js +3 -1
  95. package/dist/runtime/workspace.js.map +1 -1
  96. package/dist/skill/access.d.ts +4 -2
  97. package/dist/skill/access.js +7 -3
  98. package/dist/skill/access.js.map +1 -1
  99. package/dist/upgrade/installation.js +1 -1
  100. package/dist/upgrade/installation.js.map +1 -1
  101. package/dist/workspace-command.d.ts +8 -0
  102. package/dist/workspace-command.js +36 -0
  103. package/dist/workspace-command.js.map +1 -0
  104. package/package.json +2 -1
@@ -1,9 +1,21 @@
1
1
  export declare const COMMANDS: readonly [{
2
- readonly id: "cloud";
3
- readonly usage: "frely cloud list|describe|call|login|logout [--help]";
4
- readonly auth: "cloud-oauth";
5
- readonly effect: "subcommand-dependent";
6
- readonly purpose: "Discover and call Frely cloud business operations at app.frely.cloud/mcp. Use describe before call; parameters and results are JSON.";
2
+ readonly id: "login";
3
+ readonly usage: "frely login [--relay <url>] [--no-browser]";
4
+ readonly auth: "browser";
5
+ readonly effect: "authorization";
6
+ readonly purpose: "Authorize the CLI for the user's Frely account.";
7
+ }, {
8
+ readonly id: "logout";
9
+ readonly usage: "frely logout";
10
+ readonly auth: "none";
11
+ readonly effect: "local-write";
12
+ readonly purpose: "Remove login, revoke Cloud authorization and stop the MCP background service.";
13
+ }, {
14
+ readonly id: "doctor";
15
+ readonly usage: "frely doctor [-v] [--json]";
16
+ readonly auth: "optional-account";
17
+ readonly effect: "diagnostic";
18
+ readonly purpose: "Show the signed-in account, installation, available upgrades, MCP and connection status; -v verifies the account online and runs detailed diagnostics.";
7
19
  }, {
8
20
  readonly id: "upgrade";
9
21
  readonly usage: "frely upgrade";
@@ -17,65 +29,77 @@ export declare const COMMANDS: readonly [{
17
29
  readonly effect: "read";
18
30
  readonly purpose: "Read this installed CLI's current Agent instructions.";
19
31
  }, {
20
- readonly id: "key.budget";
21
- readonly usage: "frely key budget (--api-key-stdin [--relay <url>]|--distribution <distribution-id>) [--json]";
22
- readonly auth: "api-key";
23
- readonly effect: "read";
24
- readonly purpose: "Read the Key's self usage and each funding source's limits without account login.";
32
+ readonly id: "mcp";
33
+ readonly usage: "frely mcp [--workspace <path>] [--days 1..180] [--json]";
34
+ readonly auth: "account-and-browser-if-needed";
35
+ readonly effect: "authorization-if-needed";
36
+ readonly purpose: "Enable, renew or read device MCP. Unconfigured: request browser approval for --workspace (default: current directory) and install the background service. Expired or --days given: renew with browser approval; the MCP URL stays the same. Otherwise print the MCP URL unchanged. Prompts go to stderr; stdout holds only the URL, or JSON with HTTP transport and OAuth details.";
25
37
  }, {
26
- readonly id: "skill.install";
27
- readonly usage: "frely skill install <manifest-url> [--host chatgpt|codex|claude-code|pi|generic] [--scope global|project] [--api-key-stdin] [--json]";
28
- readonly auth: "optional-api-key";
29
- readonly effect: "local-write";
30
- readonly purpose: "Install the public Agent's trigger Skill; an API key goes only through stdin to secure storage.";
38
+ readonly id: "mcp.workspace";
39
+ readonly usage: "frely mcp workspace [add|remove <path>] [--json]";
40
+ readonly auth: "mcp";
41
+ readonly effect: "subcommand-dependent";
42
+ readonly purpose: "List workspace directories for this device, or add/remove an additional one (the primary cannot be removed).";
31
43
  }, {
32
- readonly id: "skill.status";
33
- readonly usage: "frely skill status <distribution-id> [--json]";
44
+ readonly id: "mcp.stop";
45
+ readonly usage: "frely mcp stop";
34
46
  readonly auth: "none";
35
- readonly effect: "read";
36
- readonly purpose: "Inspect a managed Agent Skill.";
47
+ readonly effect: "local-service";
48
+ readonly purpose: "Pause the local MCP background service. Supported upgrades restore running services without this command.";
37
49
  }, {
38
- readonly id: "skill.remove";
39
- readonly usage: "frely skill remove <distribution-id> [--json]";
50
+ readonly id: "mcp.start";
51
+ readonly usage: "frely mcp start";
40
52
  readonly auth: "none";
53
+ readonly effect: "local-service";
54
+ readonly purpose: "Resume the local MCP background service.";
55
+ }, {
56
+ readonly id: "mcp.remove";
57
+ readonly usage: "frely mcp remove";
58
+ readonly auth: "account";
59
+ readonly effect: "remote-write";
60
+ readonly purpose: "Revoke device MCP for every connected client and uninstall the background service (kept running provider-only when local Providers exist).";
61
+ }, {
62
+ readonly id: "mcp.stdio";
63
+ readonly usage: "frely mcp stdio [--workspace <path>]";
64
+ readonly auth: "mcp";
65
+ readonly effect: "local-execution";
66
+ readonly purpose: "Serve authorized local tools over stdio for a local MCP client.";
67
+ }, {
68
+ readonly id: "mcp.serve";
69
+ readonly usage: "frely mcp serve [--workspace <path>]";
70
+ readonly auth: "account-and-mcp";
71
+ readonly effect: "local-execution";
72
+ readonly purpose: "Foreground Device Relay client; the background service runs this. Not needed for normal use.";
73
+ }, {
74
+ readonly id: "agent.install";
75
+ readonly usage: "frely agent install <distribution-id|manifest-url> [--host chatgpt|codex|claude-code|pi|generic] [--scope global|project] [--api-key-stdin] [--json]";
76
+ readonly auth: "optional-api-key";
41
77
  readonly effect: "local-write";
42
- readonly purpose: "Remove a managed Agent Skill and its saved API key.";
78
+ readonly purpose: "Install the public Agent's trigger Skill; an API key goes only through stdin to secure storage.";
43
79
  }, {
44
- readonly id: "agent.invoke";
45
- readonly usage: "frely agent invoke <distribution-id> (--input <text>|--input-stdin) [--json]";
80
+ readonly id: "agent.run";
81
+ readonly usage: "frely agent run <distribution-id> (--input <text>|--input-stdin) [--json]";
46
82
  readonly auth: "installed-api-key-or-account";
47
83
  readonly effect: "remote-call";
48
84
  readonly purpose: "Send the complete relevant user request to the installed Agent through model-scoped MCP. Usage may be billed.";
49
85
  }, {
50
- readonly id: "login";
51
- readonly usage: "frely login [--relay <url>] [--no-browser]";
52
- readonly auth: "browser";
53
- readonly effect: "authorization";
54
- readonly purpose: "Authorize the CLI for the user's Frely account.";
86
+ readonly id: "agent.status";
87
+ readonly usage: "frely agent status (<distribution-id>|--api-key-stdin [--relay <url>]) [--json]";
88
+ readonly auth: "none-or-api-key";
89
+ readonly effect: "read";
90
+ readonly purpose: "Inspect an installed Agent Skill and, for API-key installs, its Key budget. With --api-key-stdin, read that Key's budget without installing or logging in.";
55
91
  }, {
56
- readonly id: "logout";
57
- readonly usage: "frely logout";
92
+ readonly id: "agent.remove";
93
+ readonly usage: "frely agent remove <distribution-id> [--json]";
58
94
  readonly auth: "none";
59
95
  readonly effect: "local-write";
60
- readonly purpose: "Remove login and stop the MCP background service.";
61
- }, {
62
- readonly id: "whoami";
63
- readonly usage: "frely whoami";
64
- readonly auth: "account";
65
- readonly effect: "read";
66
- readonly purpose: "Read the signed-in account.";
67
- }, {
68
- readonly id: "doctor";
69
- readonly usage: "frely doctor [-v] [--json]";
70
- readonly auth: "optional-account";
71
- readonly effect: "diagnostic";
72
- readonly purpose: "Show installation, available upgrades, account, MCP and connection status; -v runs detailed diagnostics.";
96
+ readonly purpose: "Remove an installed Agent Skill and its saved API key.";
73
97
  }, {
74
98
  readonly id: "provider.share";
75
99
  readonly usage: "frely provider share [ollama|openai-compatible] [--url <loopback-v1-url>] [--models <a,b>] [--slot <slot-id>] [--name <name>]";
76
100
  readonly auth: "account";
77
101
  readonly effect: "remote-write";
78
- readonly purpose: "Publish a local model Provider.";
102
+ readonly purpose: "Publish a local model Provider. If a prepared Provider on this device is not finished, resume it instead.";
79
103
  }, {
80
104
  readonly id: "provider.list";
81
105
  readonly usage: "frely provider list [--json]";
@@ -83,59 +107,47 @@ export declare const COMMANDS: readonly [{
83
107
  readonly effect: "read";
84
108
  readonly purpose: "List configured local Providers.";
85
109
  }, {
86
- readonly id: "provider.finalize";
87
- readonly usage: "frely provider finalize <provider-id>";
88
- readonly auth: "account";
89
- readonly effect: "remote-write";
90
- readonly purpose: "Finish a prepared local Provider.";
91
- }, {
92
- readonly id: "mcp.setup";
93
- readonly usage: "frely mcp [--workspace <path>] [--days 1..180]";
94
- readonly auth: "account-and-browser";
95
- readonly effect: "authorization";
96
- readonly purpose: "Enable this computer as a device MCP service for remote HTTP MCP clients with OAuth; install its background service.";
97
- }, {
98
- readonly id: "mcp.renew";
99
- readonly usage: "frely mcp renew [--days 1..180]";
100
- readonly auth: "account-and-browser";
101
- readonly effect: "authorization";
102
- readonly purpose: "Renew this device's execution authorization without changing its MCP URL.";
110
+ readonly id: "cloud";
111
+ readonly usage: "frely cloud list|describe|call [--help]";
112
+ readonly auth: "cloud-oauth";
113
+ readonly effect: "subcommand-dependent";
114
+ readonly purpose: "Discover and call Frely cloud business operations at frely.cloud/mcp. The first call requests browser authorization. Use describe before call; parameters and results are JSON.";
103
115
  }, {
104
- readonly id: "mcp.url";
105
- readonly usage: "frely mcp url [--json]";
106
- readonly auth: "account-and-mcp-or-browser";
107
- readonly effect: "authorization-if-unconfigured";
108
- readonly purpose: "Read this device's stable MCP URL. If unconfigured, set up the user home directory with browser approval and install the background service. --json includes HTTP transport and OAuth connection details; setup prompts go to stderr.";
116
+ readonly id: "app.remote";
117
+ readonly usage: "frely app remote enable|disable|status [--json]";
118
+ readonly auth: "local";
119
+ readonly effect: "local-write";
120
+ readonly purpose: "Toggle agent remote control for the Frely web app (app.frely.cloud). Disabled by default; enable before starting tasks from a phone.";
109
121
  }, {
110
- readonly id: "mcp.serve";
111
- readonly usage: "frely mcp serve [--workspace <path>]";
112
- readonly auth: "account-and-mcp";
113
- readonly effect: "local-execution";
114
- readonly purpose: "Serve authorized local workspace tools.";
122
+ readonly id: "app.ops";
123
+ readonly usage: "frely app ops";
124
+ readonly auth: "local";
125
+ readonly effect: "read-only";
126
+ readonly purpose: "Bridge the local agent ops socket to stdin/stdout (NDJSON, incl. tasks_changed pushes); used by the Frely App GUI task panel.";
115
127
  }, {
116
- readonly id: "mcp.service";
117
- readonly usage: "frely mcp service start|stop|uninstall";
118
- readonly auth: "none";
119
- readonly effect: "local-service";
120
- readonly purpose: "Pause, resume or remove the local MCP background service for maintenance. Supported upgrades restore running services without these commands.";
128
+ readonly id: "app.connectInfo";
129
+ readonly usage: "frely app connect-info [--json]";
130
+ readonly auth: "local";
131
+ readonly effect: "read-only";
132
+ readonly purpose: "Report the local agent ops socket path and whether a serving process is reachable (used by the Frely App GUI to find task control).";
121
133
  }, {
122
- readonly id: "mcp.revoke";
123
- readonly usage: "frely mcp revoke";
124
- readonly auth: "account";
125
- readonly effect: "remote-write";
126
- readonly purpose: "Revoke device MCP execution authorization for every connected client.";
134
+ readonly id: "app.key";
135
+ readonly usage: "frely app key [--lifetime-usd N] [--json]";
136
+ readonly auth: "user";
137
+ readonly effect: "account-write";
138
+ readonly purpose: "Provision a device-scoped Frely API key for app agent tasks (shown once, capped at a lifetime spend limit; default $50, max $500).";
127
139
  }, {
128
- readonly id: "mcp.stdio";
129
- readonly usage: "frely mcp stdio [--workspace <path>]";
130
- readonly auth: "mcp";
131
- readonly effect: "local-execution";
132
- readonly purpose: "Serve authorized local tools over stdio.";
140
+ readonly id: "app.tasks";
141
+ readonly usage: "frely app tasks [--json]";
142
+ readonly auth: "local";
143
+ readonly effect: "read";
144
+ readonly purpose: "List local agent tasks with status, merge state and budget usage.";
133
145
  }, {
134
146
  readonly id: "network";
135
147
  readonly usage: "frely network setup|status|find|use|logout [--json]";
136
148
  readonly auth: "network";
137
149
  readonly effect: "subcommand-dependent";
138
- readonly purpose: "Access Frely Network using its separate setup and credentials.";
150
+ readonly purpose: "Access Frely Network (preview) using its separate setup and credentials.";
139
151
  }];
140
152
  export declare function agentHelp(): {
141
153
  schemaVersion: string;
@@ -144,11 +156,23 @@ export declare function agentHelp(): {
144
156
  skill_update_required: boolean;
145
157
  instructions: string[];
146
158
  commands: readonly [{
147
- readonly id: "cloud";
148
- readonly usage: "frely cloud list|describe|call|login|logout [--help]";
149
- readonly auth: "cloud-oauth";
150
- readonly effect: "subcommand-dependent";
151
- readonly purpose: "Discover and call Frely cloud business operations at app.frely.cloud/mcp. Use describe before call; parameters and results are JSON.";
159
+ readonly id: "login";
160
+ readonly usage: "frely login [--relay <url>] [--no-browser]";
161
+ readonly auth: "browser";
162
+ readonly effect: "authorization";
163
+ readonly purpose: "Authorize the CLI for the user's Frely account.";
164
+ }, {
165
+ readonly id: "logout";
166
+ readonly usage: "frely logout";
167
+ readonly auth: "none";
168
+ readonly effect: "local-write";
169
+ readonly purpose: "Remove login, revoke Cloud authorization and stop the MCP background service.";
170
+ }, {
171
+ readonly id: "doctor";
172
+ readonly usage: "frely doctor [-v] [--json]";
173
+ readonly auth: "optional-account";
174
+ readonly effect: "diagnostic";
175
+ readonly purpose: "Show the signed-in account, installation, available upgrades, MCP and connection status; -v verifies the account online and runs detailed diagnostics.";
152
176
  }, {
153
177
  readonly id: "upgrade";
154
178
  readonly usage: "frely upgrade";
@@ -162,65 +186,77 @@ export declare function agentHelp(): {
162
186
  readonly effect: "read";
163
187
  readonly purpose: "Read this installed CLI's current Agent instructions.";
164
188
  }, {
165
- readonly id: "key.budget";
166
- readonly usage: "frely key budget (--api-key-stdin [--relay <url>]|--distribution <distribution-id>) [--json]";
167
- readonly auth: "api-key";
168
- readonly effect: "read";
169
- readonly purpose: "Read the Key's self usage and each funding source's limits without account login.";
189
+ readonly id: "mcp";
190
+ readonly usage: "frely mcp [--workspace <path>] [--days 1..180] [--json]";
191
+ readonly auth: "account-and-browser-if-needed";
192
+ readonly effect: "authorization-if-needed";
193
+ readonly purpose: "Enable, renew or read device MCP. Unconfigured: request browser approval for --workspace (default: current directory) and install the background service. Expired or --days given: renew with browser approval; the MCP URL stays the same. Otherwise print the MCP URL unchanged. Prompts go to stderr; stdout holds only the URL, or JSON with HTTP transport and OAuth details.";
170
194
  }, {
171
- readonly id: "skill.install";
172
- readonly usage: "frely skill install <manifest-url> [--host chatgpt|codex|claude-code|pi|generic] [--scope global|project] [--api-key-stdin] [--json]";
173
- readonly auth: "optional-api-key";
174
- readonly effect: "local-write";
175
- readonly purpose: "Install the public Agent's trigger Skill; an API key goes only through stdin to secure storage.";
195
+ readonly id: "mcp.workspace";
196
+ readonly usage: "frely mcp workspace [add|remove <path>] [--json]";
197
+ readonly auth: "mcp";
198
+ readonly effect: "subcommand-dependent";
199
+ readonly purpose: "List workspace directories for this device, or add/remove an additional one (the primary cannot be removed).";
176
200
  }, {
177
- readonly id: "skill.status";
178
- readonly usage: "frely skill status <distribution-id> [--json]";
201
+ readonly id: "mcp.stop";
202
+ readonly usage: "frely mcp stop";
179
203
  readonly auth: "none";
180
- readonly effect: "read";
181
- readonly purpose: "Inspect a managed Agent Skill.";
204
+ readonly effect: "local-service";
205
+ readonly purpose: "Pause the local MCP background service. Supported upgrades restore running services without this command.";
182
206
  }, {
183
- readonly id: "skill.remove";
184
- readonly usage: "frely skill remove <distribution-id> [--json]";
207
+ readonly id: "mcp.start";
208
+ readonly usage: "frely mcp start";
185
209
  readonly auth: "none";
210
+ readonly effect: "local-service";
211
+ readonly purpose: "Resume the local MCP background service.";
212
+ }, {
213
+ readonly id: "mcp.remove";
214
+ readonly usage: "frely mcp remove";
215
+ readonly auth: "account";
216
+ readonly effect: "remote-write";
217
+ readonly purpose: "Revoke device MCP for every connected client and uninstall the background service (kept running provider-only when local Providers exist).";
218
+ }, {
219
+ readonly id: "mcp.stdio";
220
+ readonly usage: "frely mcp stdio [--workspace <path>]";
221
+ readonly auth: "mcp";
222
+ readonly effect: "local-execution";
223
+ readonly purpose: "Serve authorized local tools over stdio for a local MCP client.";
224
+ }, {
225
+ readonly id: "mcp.serve";
226
+ readonly usage: "frely mcp serve [--workspace <path>]";
227
+ readonly auth: "account-and-mcp";
228
+ readonly effect: "local-execution";
229
+ readonly purpose: "Foreground Device Relay client; the background service runs this. Not needed for normal use.";
230
+ }, {
231
+ readonly id: "agent.install";
232
+ readonly usage: "frely agent install <distribution-id|manifest-url> [--host chatgpt|codex|claude-code|pi|generic] [--scope global|project] [--api-key-stdin] [--json]";
233
+ readonly auth: "optional-api-key";
186
234
  readonly effect: "local-write";
187
- readonly purpose: "Remove a managed Agent Skill and its saved API key.";
235
+ readonly purpose: "Install the public Agent's trigger Skill; an API key goes only through stdin to secure storage.";
188
236
  }, {
189
- readonly id: "agent.invoke";
190
- readonly usage: "frely agent invoke <distribution-id> (--input <text>|--input-stdin) [--json]";
237
+ readonly id: "agent.run";
238
+ readonly usage: "frely agent run <distribution-id> (--input <text>|--input-stdin) [--json]";
191
239
  readonly auth: "installed-api-key-or-account";
192
240
  readonly effect: "remote-call";
193
241
  readonly purpose: "Send the complete relevant user request to the installed Agent through model-scoped MCP. Usage may be billed.";
194
242
  }, {
195
- readonly id: "login";
196
- readonly usage: "frely login [--relay <url>] [--no-browser]";
197
- readonly auth: "browser";
198
- readonly effect: "authorization";
199
- readonly purpose: "Authorize the CLI for the user's Frely account.";
243
+ readonly id: "agent.status";
244
+ readonly usage: "frely agent status (<distribution-id>|--api-key-stdin [--relay <url>]) [--json]";
245
+ readonly auth: "none-or-api-key";
246
+ readonly effect: "read";
247
+ readonly purpose: "Inspect an installed Agent Skill and, for API-key installs, its Key budget. With --api-key-stdin, read that Key's budget without installing or logging in.";
200
248
  }, {
201
- readonly id: "logout";
202
- readonly usage: "frely logout";
249
+ readonly id: "agent.remove";
250
+ readonly usage: "frely agent remove <distribution-id> [--json]";
203
251
  readonly auth: "none";
204
252
  readonly effect: "local-write";
205
- readonly purpose: "Remove login and stop the MCP background service.";
206
- }, {
207
- readonly id: "whoami";
208
- readonly usage: "frely whoami";
209
- readonly auth: "account";
210
- readonly effect: "read";
211
- readonly purpose: "Read the signed-in account.";
212
- }, {
213
- readonly id: "doctor";
214
- readonly usage: "frely doctor [-v] [--json]";
215
- readonly auth: "optional-account";
216
- readonly effect: "diagnostic";
217
- readonly purpose: "Show installation, available upgrades, account, MCP and connection status; -v runs detailed diagnostics.";
253
+ readonly purpose: "Remove an installed Agent Skill and its saved API key.";
218
254
  }, {
219
255
  readonly id: "provider.share";
220
256
  readonly usage: "frely provider share [ollama|openai-compatible] [--url <loopback-v1-url>] [--models <a,b>] [--slot <slot-id>] [--name <name>]";
221
257
  readonly auth: "account";
222
258
  readonly effect: "remote-write";
223
- readonly purpose: "Publish a local model Provider.";
259
+ readonly purpose: "Publish a local model Provider. If a prepared Provider on this device is not finished, resume it instead.";
224
260
  }, {
225
261
  readonly id: "provider.list";
226
262
  readonly usage: "frely provider list [--json]";
@@ -228,59 +264,47 @@ export declare function agentHelp(): {
228
264
  readonly effect: "read";
229
265
  readonly purpose: "List configured local Providers.";
230
266
  }, {
231
- readonly id: "provider.finalize";
232
- readonly usage: "frely provider finalize <provider-id>";
233
- readonly auth: "account";
234
- readonly effect: "remote-write";
235
- readonly purpose: "Finish a prepared local Provider.";
236
- }, {
237
- readonly id: "mcp.setup";
238
- readonly usage: "frely mcp [--workspace <path>] [--days 1..180]";
239
- readonly auth: "account-and-browser";
240
- readonly effect: "authorization";
241
- readonly purpose: "Enable this computer as a device MCP service for remote HTTP MCP clients with OAuth; install its background service.";
242
- }, {
243
- readonly id: "mcp.renew";
244
- readonly usage: "frely mcp renew [--days 1..180]";
245
- readonly auth: "account-and-browser";
246
- readonly effect: "authorization";
247
- readonly purpose: "Renew this device's execution authorization without changing its MCP URL.";
267
+ readonly id: "cloud";
268
+ readonly usage: "frely cloud list|describe|call [--help]";
269
+ readonly auth: "cloud-oauth";
270
+ readonly effect: "subcommand-dependent";
271
+ readonly purpose: "Discover and call Frely cloud business operations at frely.cloud/mcp. The first call requests browser authorization. Use describe before call; parameters and results are JSON.";
248
272
  }, {
249
- readonly id: "mcp.url";
250
- readonly usage: "frely mcp url [--json]";
251
- readonly auth: "account-and-mcp-or-browser";
252
- readonly effect: "authorization-if-unconfigured";
253
- readonly purpose: "Read this device's stable MCP URL. If unconfigured, set up the user home directory with browser approval and install the background service. --json includes HTTP transport and OAuth connection details; setup prompts go to stderr.";
273
+ readonly id: "app.remote";
274
+ readonly usage: "frely app remote enable|disable|status [--json]";
275
+ readonly auth: "local";
276
+ readonly effect: "local-write";
277
+ readonly purpose: "Toggle agent remote control for the Frely web app (app.frely.cloud). Disabled by default; enable before starting tasks from a phone.";
254
278
  }, {
255
- readonly id: "mcp.serve";
256
- readonly usage: "frely mcp serve [--workspace <path>]";
257
- readonly auth: "account-and-mcp";
258
- readonly effect: "local-execution";
259
- readonly purpose: "Serve authorized local workspace tools.";
279
+ readonly id: "app.ops";
280
+ readonly usage: "frely app ops";
281
+ readonly auth: "local";
282
+ readonly effect: "read-only";
283
+ readonly purpose: "Bridge the local agent ops socket to stdin/stdout (NDJSON, incl. tasks_changed pushes); used by the Frely App GUI task panel.";
260
284
  }, {
261
- readonly id: "mcp.service";
262
- readonly usage: "frely mcp service start|stop|uninstall";
263
- readonly auth: "none";
264
- readonly effect: "local-service";
265
- readonly purpose: "Pause, resume or remove the local MCP background service for maintenance. Supported upgrades restore running services without these commands.";
285
+ readonly id: "app.connectInfo";
286
+ readonly usage: "frely app connect-info [--json]";
287
+ readonly auth: "local";
288
+ readonly effect: "read-only";
289
+ readonly purpose: "Report the local agent ops socket path and whether a serving process is reachable (used by the Frely App GUI to find task control).";
266
290
  }, {
267
- readonly id: "mcp.revoke";
268
- readonly usage: "frely mcp revoke";
269
- readonly auth: "account";
270
- readonly effect: "remote-write";
271
- readonly purpose: "Revoke device MCP execution authorization for every connected client.";
291
+ readonly id: "app.key";
292
+ readonly usage: "frely app key [--lifetime-usd N] [--json]";
293
+ readonly auth: "user";
294
+ readonly effect: "account-write";
295
+ readonly purpose: "Provision a device-scoped Frely API key for app agent tasks (shown once, capped at a lifetime spend limit; default $50, max $500).";
272
296
  }, {
273
- readonly id: "mcp.stdio";
274
- readonly usage: "frely mcp stdio [--workspace <path>]";
275
- readonly auth: "mcp";
276
- readonly effect: "local-execution";
277
- readonly purpose: "Serve authorized local tools over stdio.";
297
+ readonly id: "app.tasks";
298
+ readonly usage: "frely app tasks [--json]";
299
+ readonly auth: "local";
300
+ readonly effect: "read";
301
+ readonly purpose: "List local agent tasks with status, merge state and budget usage.";
278
302
  }, {
279
303
  readonly id: "network";
280
304
  readonly usage: "frely network setup|status|find|use|logout [--json]";
281
305
  readonly auth: "network";
282
306
  readonly effect: "subcommand-dependent";
283
- readonly purpose: "Access Frely Network using its separate setup and credentials.";
307
+ readonly purpose: "Access Frely Network (preview) using its separate setup and credentials.";
284
308
  }];
285
309
  };
286
310
  export declare function cliUsage(): string;