@parall/parall 1.61.0 → 1.63.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parall/parall",
3
- "version": "1.61.0",
3
+ "version": "1.63.0",
4
4
  "description": "OpenClaw channel plugin for Parall IM",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -16,8 +16,8 @@
16
16
  "openclaw.plugin.json"
17
17
  ],
18
18
  "dependencies": {
19
- "@parall/agent-core": "1.61.0",
20
- "@parall/sdk": "1.61.0"
19
+ "@parall/agent-core": "1.63.0",
20
+ "@parall/sdk": "1.63.0"
21
21
  },
22
22
  "devDependencies": {
23
23
  "@types/node": "^22.0.0",
@@ -212,14 +212,17 @@ or configure.
212
212
 
213
213
  ```sh
214
214
  parall clip exec <clip> <command> '{"query":"AI","count":10}' --connection <ccn_id|alias>
215
- # or route to a desktop (BYOC) device you own: --edge <edge-id>
216
- # --connection and --edge are mutually exclusive; --timeout <ms> defaults to 30000
215
+ # --connection is REQUIRED for an agent: a desktop device, a cloud profile
216
+ # and an MCP server are all reached through the connection bound to the
217
+ # clip. --timeout <ms> defaults to 30000
217
218
  ```
218
219
 
219
- A **cloud (hosted) profile is reachable ONLY via `--connection`** the
220
- binding its maintainer created IS the authorization. With neither flag the
221
- server resolves only your own online desktop device, never a cloud profile.
222
- Discover the bindings with `parall clip connections <clip>`.
220
+ Who may run through a connection follows its layer (ADR-020): an
221
+ org-shared connection (cloud profile, MCP server, org-managed device) is
222
+ decided by the clip's access list an org admin edits; a member's personal
223
+ desktop device is theirs alone. Discover what YOU may run through with
224
+ `parall clip connections <clip>` — an ungranted connection is not listed,
225
+ so a missing row means "ask an admin", not "retry".
223
226
 
224
227
  3. **Iterate**: edit locally → `parall clip publish` again → re-exec. Exec
225
228
  resolves the file set from the REGISTRY, server-side — your own org always
@@ -18,11 +18,17 @@ parall clip tools <clip> # MCP clips only: live tool schemas
18
18
  ```
19
19
 
20
20
  `clip list` answers both discovery questions at once: WHICH clip (name,
21
- description, version) and WHERE it can run — every connection with its
22
- `ccn_…` id, alias, and target kind:
21
+ description, version) and WHERE it could run — every connection you can SEE
22
+ (public org-layer rows or those the clip's access list admits you to, plus rows on your
23
+ own personal device; an admin's list is a management view of the whole org
24
+ layer and does not by itself grant exec) with its `ccn_…` id, alias, and
25
+ target kind:
23
26
 
24
27
  - `cloud` — an org-shared cloud profile (a maintainer's signed-in browser)
25
- - `desktop` — a member's own device (only its owner can exec through it)
28
+ - `desktop` — a member's device: org-shared (`layer: org` an org admin
29
+ binds it; public connections admit everyone, otherwise the clip's access
30
+ list decides, same as cloud and MCP) or
31
+ personal (`layer: personal` — its owner alone, nobody else sees it)
26
32
  - `mcp` — a remote MCP tool server
27
33
  - `device` — a device whose placement could not be resolved just now (the
28
34
  device list was unavailable); don't guess which kind it is — re-run
@@ -54,15 +60,18 @@ via a quoted heredoc, as above; strict JSON, mutually exclusive with the
54
60
  sees them, exactly the trap `messages send --text-file` exists for.
55
61
  Results are JSON on stdout; failures print a typed error.
56
62
 
57
- **Name the target explicitly — every exec.** `clip exec` refuses to run
58
- without `--connection` or `--edge`; there is no implicit route to any
59
- profile, and the legacy no-flag desktop fallback is gone from the CLI.
60
-
61
- - A cloud (hosted) profile is reachable ONLY via `--connection` — the clip
62
- connection its maintainer bound. That binding IS your authorization;
63
- without one the server answers `HOSTED_CONNECTION_REQUIRED` and the fix
64
- is to ask an owner/admin to bind the clip, never to retry.
65
- - `--edge <edgeId>` targets only a desktop device YOU own.
63
+ **Name the connection — every exec.** `clip exec` refuses to run without
64
+ `--connection`; there is no other target form. A desktop device, a cloud
65
+ (hosted) profile and an MCP server are all reached through the connection
66
+ bound to the clip, and the connection is what your access is granted on.
67
+
68
+ - Without a connection the server answers `AGENT_CONNECTION_REQUIRED`; the
69
+ fix is to discover the clip's connections and name one, never to retry.
70
+ - human 调用返回 `CONNECTION_NOT_ALLOWED` 时,请 org admin 公开该 connection
71
+ 或把调用者加入 Clip 名单;agent 本版仍返回下述两个错误码。
72
+ - `CLIP_AGENT_NOT_ALLOWED` / `CLIP_AGENT_CONNECTION_NOT_ALLOWED` mean a
73
+ human has restricted who may run this clip (or through which account);
74
+ ask them to widen access — you cannot grant it to yourself.
66
75
  - Waiting on a cloud profile is handled by the CLI: `EDGE_ACTIVATING` (cold
67
76
  start), `EDGE_BUSY` (another exec is running) and
68
77
  `EDGE_CONCURRENCY_LIMIT` (org at capacity) are all guaranteed-unexecuted
@@ -89,10 +98,9 @@ parall clip exec <clip> <tool> [json-args] --connection <ccn_|alias>
89
98
  - `clip connections` marks MCP rows with their auth mode, `credential_set`
90
99
  / `oauth_status` and `tool_count` — a `needs_reauth` or credential-less
91
100
  row will refuse exec until an org admin fixes it in the Clip Console.
92
- - `--connection` is REQUIRED to exec an MCP connection, exactly like a cloud
93
- profile the only other target form, `--edge`, is a desktop device and
94
- never routes to MCP. The alias tells you WHICH account you act as —
95
- always name it.
101
+ - `--connection` is REQUIRED to exec an MCP connection, exactly like every
102
+ other target. The alias tells you WHICH account you act as always name
103
+ it.
96
104
  (`is_default` marks the org's primary connection in listings and the
97
105
  Console, not an implicit exec route.)
98
106
  - `clip tools` without `--connection` reads the default connection's
@@ -110,11 +118,22 @@ parall clip exec <clip> <tool> [json-args] --connection <ccn_|alias>
110
118
  - `OUTCOME_UNKNOWN` follows the rule below: dispatched and MAY HAVE
111
119
  EXECUTED — never auto-retry.
112
120
 
121
+ ## Browser Use
122
+
123
+ Browser Use 接受 personal key 和 agent key,无需 managed key;权限按调用者
124
+ 在目标设备 profile 上的授权裁决。`PROFILE_NOT_ALLOWED` 表示未获授权,
125
+ 请 org admin 调整该 profile 的公开状态或名单,不要重试或改用其他 key 绕过。
126
+ profile 公开只授予 browser.read / browser.interact,browser.advanced 仍需显式授权。
127
+ Clip exec 的 connection 是另一种目标:agent 调用仍必须带 connection,缺失会返回
128
+ `AGENT_CONNECTION_REQUIRED`,先发现 connection 再调用。
129
+
113
130
  ## Behavior rules
114
131
 
115
- - An authorization error (`HOSTED_CONNECTION_REQUIRED`, `FORBIDDEN`) is a
116
- fail-fast: ask the clip's maintainer or an org admin to bind the clip or
117
- grant the connection do not retry or work around it.
132
+ - An authorization error (`CLIP_AGENT_NOT_ALLOWED`,
133
+ `CLIP_AGENT_CONNECTION_NOT_ALLOWED`, `CONNECTION_NOT_ALLOWED`,
134
+ `PROFILE_NOT_ALLOWED`, `FORBIDDEN`) is a fail-fast: ask
135
+ an org admin to grant the clip or the connection — do not retry or work
136
+ around it.
118
137
  - If the target device is offline or the call times out, report that
119
138
  plainly; do not queue, and never fabricate a result for a run that errored.
120
139
  - **`OUTCOME_UNKNOWN` is never retryable.** It means the command was
@@ -264,16 +264,16 @@ Every entity is addressable with a `prll://` URI. Common prefixes you'll see in
264
264
  | `prll://prj_` | Project | parall-tasks |
265
265
  | `prll://sch_` | Schedule (time trigger) | parall-schedules |
266
266
  | `prll://srn_` | Schedule run (single fire audit record; carries fire-time snapshot) | parall-schedules |
267
- | `prll://xcn_` | External Trigger Connection (incoming endpoint) | parall-external-triggers |
268
- | `prll://xin_` | External Trigger Event (single incoming event audit record) | parall-external-triggers |
269
- | `prll://xtr_` | External Trigger (incoming trigger configuration) | parall-external-triggers |
270
- | `prll://xrn_` | External Trigger run (single matched dispatch audit record) | parall-external-triggers |
267
+ | `prll://xcn_` | Trigger Connection (incoming endpoint) | parall-triggers |
268
+ | `prll://xin_` | Trigger Event (single incoming event audit record) | parall-triggers |
269
+ | `prll://xtr_` | Trigger (incoming trigger configuration) | parall-triggers |
270
+ | `prll://xrn_` | Trigger run (single matched dispatch audit record) | parall-triggers |
271
271
  | `prll://wik_` | Wiki | parall-wiki |
272
272
  | `prll://att_` | Attachment | parall-platform (files) |
273
273
 
274
274
  When a message or event references `prll://sch_xxx` or `prll://srn_xxx`, or when you receive `[Event: schedule.fired]`, switch to the **parall-schedules** skill for the CLI commands (create / list / pause / resume / cancel / runs).
275
275
 
276
- When a message or event references `prll://xcn_xxx`, `prll://xin_xxx`, `prll://xtr_xxx`, or `prll://xrn_xxx`, or when you receive `[Event: external.trigger]`, switch to the **parall-external-triggers** skill for the CLI commands (connections / triggers / events / runs).
276
+ When a message or event references `prll://xcn_xxx`, `prll://xin_xxx`, `prll://xtr_xxx`, or `prll://xrn_xxx`, or when you receive `[Event: external.trigger]`, switch to the **parall-triggers** skill for the CLI commands (connections / triggers / events / runs).
277
277
 
278
278
  ## References (relationship graph)
279
279
 
@@ -1,27 +1,27 @@
1
1
  ---
2
- name: parall-external-triggers
3
- description: "Parall External Trigger operations: create incoming connections, configure CEL/Liquid triggers, inspect incoming events and runs, and respond to `[Event: external.trigger]` dispatches. Use when: user asks to connect an external system to an agent, set up incoming callbacks/notifications, or when the agent receives an external trigger event."
2
+ name: parall-triggers
3
+ description: "Parall Trigger operations: create incoming connections, configure CEL/Liquid triggers, inspect incoming events and runs, and respond to `[Event: external.trigger]` dispatches. Use when: user asks to connect an external system to an agent, set up incoming callbacks/notifications, or when the agent receives a trigger event."
4
4
  ---
5
5
 
6
- # Parall External Triggers
6
+ # Parall Triggers
7
7
 
8
- An **External Trigger** is an incoming platform trigger. External systems send events to an External Trigger Connection, Parall matches active triggers with CEL, renders a Liquid template into an agent input body, and dispatches that input to the configured target agents.
8
+ A **Trigger** is an incoming automation entity. External systems send events to a Trigger Connection, Parall matches active triggers with CEL, renders a Liquid template into an agent input body, and dispatches that input to the configured target agents.
9
9
 
10
- Use External Triggers for incoming events such as GitHub callbacks, Slack/Feishu notifications, generic webhooks, or emails once the platform has a connection for them. The runtime behavior is incoming-only: receiving a trigger does not imply that you can call the external system back unless another explicit Parall capability is available.
10
+ Use Triggers for incoming events such as GitHub callbacks, Slack/Feishu notifications, generic webhooks, or emails once the platform has a connection for them. The runtime behavior is incoming-only: receiving a trigger does not imply that you can call the external system back unless another explicit Parall capability is available.
11
11
 
12
12
  ## Prerequisite
13
13
 
14
- External Trigger CLI commands are gated by the org-level `external-triggers` feature flag. If a command reports that the feature is unavailable, ask a human org admin to enable the flag before trying again. Public ingress delivery may still be live even when the management CLI is hidden behind the rollout flag.
14
+ Trigger CLI commands are gated by the org-level `external-triggers` feature flag. If a command reports that the feature is unavailable, ask a human org admin to enable the flag before trying again. Public ingress delivery may still be live even when the management CLI is hidden behind the rollout flag.
15
15
 
16
16
  ## Creating a trigger
17
17
 
18
18
  ```bash
19
19
  # 1. Create a connection. The ingress token is shown once; prefer writing it
20
20
  # to a local file so it does not land in shell history or logs.
21
- parall external-triggers create-connection --name "GitHub CI" --token-file ./github-ci-webhook-token.txt
21
+ parall triggers create-connection --name "GitHub CI" --token-file ./github-ci-webhook-token.txt
22
22
 
23
23
  # 2. Create a trigger that targets one or more agents.
24
- parall external-triggers create \
24
+ parall triggers create \
25
25
  --connection prll://xcn_xxx \
26
26
  --name "Failed checks" \
27
27
  --target-ids prll://usr_agent_xxx \
@@ -53,25 +53,25 @@ Do not render access tokens, signing secrets, cookies, or private credentials in
53
53
  ## Inspecting and lifecycle
54
54
 
55
55
  ```bash
56
- parall external-triggers connections
57
- parall external-triggers connection prll://xcn_xxx
58
- parall external-triggers schema prll://xcn_xxx
59
-
60
- parall external-triggers list
61
- parall external-triggers list --connection prll://xcn_xxx
62
- parall external-triggers get prll://xtr_xxx
63
- parall external-triggers update prll://xtr_xxx --filter "event.type == 'check_run'"
64
- parall external-triggers pause prll://xtr_xxx
65
- parall external-triggers resume prll://xtr_xxx
66
- parall external-triggers delete prll://xtr_xxx
67
-
68
- parall external-triggers runs prll://xtr_xxx
69
- parall external-triggers run prll://xrn_xxx
70
- parall external-triggers events --connection prll://xcn_xxx
71
- parall external-triggers event prll://xin_xxx
56
+ parall triggers connections
57
+ parall triggers connection prll://xcn_xxx
58
+ parall triggers schema prll://xcn_xxx
59
+
60
+ parall triggers list
61
+ parall triggers list --connection prll://xcn_xxx
62
+ parall triggers get prll://xtr_xxx
63
+ parall triggers update prll://xtr_xxx --filter "event.type == 'check_run'"
64
+ parall triggers pause prll://xtr_xxx
65
+ parall triggers resume prll://xtr_xxx
66
+ parall triggers delete prll://xtr_xxx
67
+
68
+ parall triggers runs prll://xtr_xxx
69
+ parall triggers run prll://xrn_xxx
70
+ parall triggers events --connection prll://xcn_xxx
71
+ parall triggers event prll://xin_xxx
72
72
  ```
73
73
 
74
- ## Responding to external trigger dispatches
74
+ ## Responding to trigger dispatches
75
75
 
76
76
  When you receive `[Event: external.trigger]`, Parall has already matched a trigger and rendered its template. The prompt includes headers such as:
77
77
 
@@ -84,9 +84,9 @@ When you receive `[Event: external.trigger]`, Parall has already matched a trigg
84
84
  The rendered agent input body follows those headers. You usually do not need to fetch the run before acting. Fetch the run only for audit/debugging:
85
85
 
86
86
  ```bash
87
- parall external-triggers run prll://xrn_xxx
87
+ parall triggers run prll://xrn_xxx
88
88
  ```
89
89
 
90
- Act on the rendered input the same way you would act on a user message: send a message, create or update tasks, edit wiki pages, or use available clips. If no visible response is needed, use `parall no-reply --reason "handled external trigger"` before sending any message.
90
+ Act on the rendered input the same way you would act on a user message: send a message, create or update tasks, edit wiki pages, or use available clips. If no visible response is needed, use `parall no-reply --reason "handled trigger"` before sending any message.
91
91
 
92
92
  CLI command results are JSON on stdout; mutation commands may emit auxiliary hints on stderr, for example `Created: prll://xtr_xxx`.
package/src/gateway.ts CHANGED
@@ -14,6 +14,7 @@ import {
14
14
  initAgentTelemetry,
15
15
  resolveServiceVersion,
16
16
  createOtelLogger,
17
+ traceContextHeaders,
17
18
  type DispatchAdapter,
18
19
  type ParallEvent,
19
20
  type RuntimeEvent,
@@ -436,6 +437,7 @@ export const parallGateway: ChannelGatewayAdapter<ResolvedParallAccount> = {
436
437
  baseUrl: config.parall_url,
437
438
  token: config.api_key,
438
439
  swimlaneName: process.env.PRLL_SWIMLANE_NAME,
440
+ getRequestHeaders: traceContextHeaders,
439
441
  });
440
442
 
441
443
  const me = await getAgentMeWithLegacyFallback(client, config.org_id);
@@ -443,10 +445,11 @@ export const parallGateway: ChannelGatewayAdapter<ResolvedParallAccount> = {
443
445
  setAgentIdentity(identityFromMe(me));
444
446
  log?.info(`parall[${ctx.accountId}]: authenticated as ${me.display_name} (${agentUserId})`);
445
447
 
448
+ const serviceVersion = resolveServiceVersion(import.meta.url);
446
449
  const telemetry = await initAgentTelemetry('parall-openclaw-agent', 'openclaw', {
447
450
  apiUrl: process.env.PRLL_API_URL,
448
451
  apiKey: process.env.PRLL_API_KEY,
449
- serviceVersion: resolveServiceVersion(import.meta.url),
452
+ serviceVersion,
450
453
  });
451
454
  const otelLog = createOtelLogger('agent', 'openclaw-agent');
452
455
  try {
@@ -526,6 +529,7 @@ export const parallGateway: ChannelGatewayAdapter<ResolvedParallAccount> = {
526
529
  },
527
530
  agentUserId,
528
531
  runtimeType: 'openclaw',
532
+ runtimeVersion: serviceVersion,
529
533
  runtimeKey: orchestratorKey,
530
534
  runtimeRef: { hostname: os.hostname(), pid: process.pid },
531
535
  dispatchAdapter,