@parall/daemon 1.56.0 → 1.56.2

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.
@@ -1,6 +1,6 @@
1
1
  {
2
- "version": "1.56.0",
3
- "built_at": "2026-08-20T12:13:18.765Z",
2
+ "version": "1.56.2",
3
+ "built_at": "2026-08-21T14:21:02.917Z",
4
4
  "min_node_version": "20.0.0",
5
5
  "files": {
6
6
  "bb-browser-daemon.js": {
@@ -16,29 +16,29 @@
16
16
  "size": 18
17
17
  },
18
18
  "parall-browser-pod.js": {
19
- "sha256": "29465ed25d7eaa9f7f6e35345f0501594fafa0c885a4ad8bc9712aa6a20fac6b",
20
- "size": 2961071
19
+ "sha256": "d7cd22077f1c4bb49e2d52c220f092015f5feb44732943ee57b4350c88c6dc68",
20
+ "size": 2964867
21
21
  },
22
22
  "parall-channel-exec.js": {
23
23
  "sha256": "7c2a6e12483a45e9eb4a42cd7d4cdd3c4fa21dd09ac1347d9a3e177b4ddee930",
24
24
  "size": 7220
25
25
  },
26
26
  "parall-claude-agent.js": {
27
- "sha256": "4ccbdb9f93cb2adeea7313b4391c471c0df150a185fb91b439c59274abfff506",
28
- "size": 2838235
27
+ "sha256": "62f6d64a5a6ee8b46a1d2505cbe05226420128b59bcaa10c2ec9d5b0637dd460",
28
+ "size": 2844167
29
29
  },
30
30
  "parall-codex-agent.js": {
31
- "sha256": "a0dd40e7a27785f60ca8fff9a1c158203f5381447223dad3374811ec22ca1da5",
32
- "size": 2870182
31
+ "sha256": "11d4c536300daeef09e471f28c474dddd0ebcb91cc18c9a34828f6756de75d5f",
32
+ "size": 2876114
33
33
  },
34
34
  "parall-daemon.js": {
35
- "sha256": "0f149f68323a5013c1afc5ddc3de6f1cd94b5005dac905ac2142f85fe7987ee9",
36
- "size": 3028253
35
+ "sha256": "bd184a0cf0c6f026ce4c9e3b6630973e109e4d232994a8199791b0418e9384ce",
36
+ "size": 3032407
37
37
  },
38
38
  "parall-openclaw-agent.js": {
39
39
  "sha256": "856a1c3a9ae0ffef8efe2481fa1171dbeb1d67cccb88616aa9bf16da96a69355",
40
40
  "size": 9923
41
41
  }
42
42
  },
43
- "signature": "WXtWlGYLvRViBXtS33ZMXudumDWb7pcc8PkegD7b6DIONYlVsnlLWxqbpuA2o7S7g6poInLXWY0LTt+I1RIGAQ=="
43
+ "signature": "o7p9D5wm97kql2R2fN4lHpJfUQdCWAIaz8UUUVcYZ0gQsqZzS8AmnjsJguD0NpfuZZagmM2SrVKjs62QfbCBCA=="
44
44
  }
@@ -18360,7 +18360,7 @@ var require_response = __commonJS({
18360
18360
  var assert = __require("node:assert");
18361
18361
  var { isomorphicEncode, serializeJavascriptValueToJSONString } = require_infra();
18362
18362
  var textEncoder = new TextEncoder("utf-8");
18363
- var Response = class _Response {
18363
+ var Response2 = class _Response {
18364
18364
  /** @type {Headers} */
18365
18365
  #headers;
18366
18366
  #state;
@@ -18532,13 +18532,13 @@ var require_response = __commonJS({
18532
18532
  response.#state = newState;
18533
18533
  }
18534
18534
  };
18535
- var { getResponseHeaders, setResponseHeaders, getResponseState, setResponseState } = Response;
18536
- Reflect.deleteProperty(Response, "getResponseHeaders");
18537
- Reflect.deleteProperty(Response, "setResponseHeaders");
18538
- Reflect.deleteProperty(Response, "getResponseState");
18539
- Reflect.deleteProperty(Response, "setResponseState");
18540
- mixinBody(Response, getResponseState);
18541
- Object.defineProperties(Response.prototype, {
18535
+ var { getResponseHeaders, setResponseHeaders, getResponseState, setResponseState } = Response2;
18536
+ Reflect.deleteProperty(Response2, "getResponseHeaders");
18537
+ Reflect.deleteProperty(Response2, "setResponseHeaders");
18538
+ Reflect.deleteProperty(Response2, "getResponseState");
18539
+ Reflect.deleteProperty(Response2, "setResponseState");
18540
+ mixinBody(Response2, getResponseState);
18541
+ Object.defineProperties(Response2.prototype, {
18542
18542
  type: kEnumerableProperty,
18543
18543
  url: kEnumerableProperty,
18544
18544
  status: kEnumerableProperty,
@@ -18554,7 +18554,7 @@ var require_response = __commonJS({
18554
18554
  configurable: true
18555
18555
  }
18556
18556
  });
18557
- Object.defineProperties(Response, {
18557
+ Object.defineProperties(Response2, {
18558
18558
  json: kEnumerableProperty,
18559
18559
  redirect: kEnumerableProperty,
18560
18560
  error: kEnumerableProperty
@@ -18687,7 +18687,7 @@ var require_response = __commonJS({
18687
18687
  }
18688
18688
  }
18689
18689
  function fromInnerResponse(innerResponse, guard) {
18690
- const response = new Response(kConstruct);
18690
+ const response = new Response2(kConstruct);
18691
18691
  setResponseState(response, innerResponse);
18692
18692
  const headers = new Headers2(kConstruct);
18693
18693
  setResponseHeaders(response, headers);
@@ -18741,14 +18741,14 @@ var require_response = __commonJS({
18741
18741
  converter: webidl.converters.HeadersInit
18742
18742
  }
18743
18743
  ]);
18744
- webidl.is.Response = webidl.util.MakeTypeAssertion(Response);
18744
+ webidl.is.Response = webidl.util.MakeTypeAssertion(Response2);
18745
18745
  module.exports = {
18746
18746
  isNetworkError,
18747
18747
  makeNetworkError,
18748
18748
  makeResponse,
18749
18749
  makeAppropriateNetworkError,
18750
18750
  filterResponse,
18751
- Response,
18751
+ Response: Response2,
18752
18752
  cloneResponse,
18753
18753
  fromInnerResponse,
18754
18754
  getResponseState
@@ -63563,6 +63563,8 @@ var ENDPOINTS = {
63563
63563
  // Users
63564
63564
  USERS_ME: `${API_BASE}/users/me`,
63565
63565
  USER_AVATAR: `${API_BASE}/users/me/avatar`,
63566
+ PERSONAL_API_KEYS: `${API_BASE}/users/me/api-keys`,
63567
+ PERSONAL_API_KEY: (keyId) => `${API_BASE}/users/me/api-keys/${keyId}`,
63566
63568
  USER: (id) => `${API_BASE}/users/${id}`,
63567
63569
  // WebSocket ticket
63568
63570
  WS_TICKET: `${API_BASE}/ws/ticket`,
@@ -64275,6 +64277,99 @@ var AttachmentClient = class extends WechatClient {
64275
64277
  }
64276
64278
  };
64277
64279
 
64280
+ // ts/sdk/dist/wiki-upload.js
64281
+ function createWikiUploadFormData(params) {
64282
+ const form = new FormData();
64283
+ form.append("path", params.path);
64284
+ form.append("file", params.file);
64285
+ if (params.message)
64286
+ form.append("message", params.message);
64287
+ if (params.uploadId)
64288
+ form.append("upload_id", params.uploadId);
64289
+ if (params.conflict)
64290
+ form.append("conflict", params.conflict);
64291
+ if ("contentRoute" in params && params.contentRoute) {
64292
+ form.append("content_route", params.contentRoute);
64293
+ }
64294
+ return form;
64295
+ }
64296
+ function sendMultipartRequest(options) {
64297
+ if (options.onProgress && typeof XMLHttpRequest !== "undefined") {
64298
+ return multipartXHR(options, options.onProgress);
64299
+ }
64300
+ const timeoutSignal = AbortSignal.timeout(options.timeoutMs);
64301
+ const signal = options.signal ? AbortSignal.any([options.signal, timeoutSignal]) : timeoutSignal;
64302
+ return fetch(options.url, {
64303
+ method: options.method,
64304
+ headers: options.headers,
64305
+ body: options.body,
64306
+ signal
64307
+ });
64308
+ }
64309
+ function multipartXHR(options, onProgress) {
64310
+ return new Promise((resolve2, reject) => {
64311
+ const xhr = new XMLHttpRequest();
64312
+ let settled = false;
64313
+ const finish = (fn) => {
64314
+ if (settled)
64315
+ return;
64316
+ settled = true;
64317
+ options.signal?.removeEventListener("abort", abortFromSignal);
64318
+ fn();
64319
+ };
64320
+ const abortFromSignal = () => xhr.abort();
64321
+ xhr.open(options.method, options.url, true);
64322
+ xhr.timeout = options.timeoutMs;
64323
+ for (const [name, value] of Object.entries(options.headers)) {
64324
+ xhr.setRequestHeader(name, value);
64325
+ }
64326
+ xhr.upload.onprogress = (event) => {
64327
+ try {
64328
+ onProgress(event.loaded, event.lengthComputable ? event.total : 0);
64329
+ } catch {
64330
+ }
64331
+ };
64332
+ xhr.onload = () => finish(() => {
64333
+ const responseHeaders = new Headers();
64334
+ for (const line of xhr.getAllResponseHeaders().trim().split(/[\r\n]+/)) {
64335
+ if (!line)
64336
+ continue;
64337
+ const separator = line.indexOf(":");
64338
+ if (separator > 0) {
64339
+ responseHeaders.append(line.slice(0, separator).trim(), line.slice(separator + 1).trim());
64340
+ }
64341
+ }
64342
+ const responseBody = xhr.status === 204 || xhr.responseText === "" ? null : xhr.responseText;
64343
+ resolve2(new Response(responseBody, {
64344
+ status: xhr.status,
64345
+ statusText: xhr.statusText,
64346
+ headers: responseHeaders
64347
+ }));
64348
+ });
64349
+ xhr.onerror = () => finish(() => reject(new TypeError("Network request failed")));
64350
+ xhr.ontimeout = () => finish(() => reject(new DOMException("Request timed out", "TimeoutError")));
64351
+ xhr.onabort = () => finish(() => reject(new DOMException("Request aborted", "AbortError")));
64352
+ if (options.signal?.aborted) {
64353
+ finish(() => reject(new DOMException("Request aborted", "AbortError")));
64354
+ return;
64355
+ }
64356
+ options.signal?.addEventListener("abort", abortFromSignal, { once: true });
64357
+ xhr.send(options.body);
64358
+ });
64359
+ }
64360
+
64361
+ // ts/sdk/dist/wiki-changeset.js
64362
+ function normalizeWikiChangeset(changeset) {
64363
+ return {
64364
+ ...changeset,
64365
+ head_branch: changeset.head_branch ?? null,
64366
+ base_commit: changeset.base_commit ?? null,
64367
+ merge_commit: changeset.merge_commit ?? null,
64368
+ changed_paths: changeset.changed_paths ?? [],
64369
+ file_changes: changeset.file_changes ?? []
64370
+ };
64371
+ }
64372
+
64278
64373
  // ts/sdk/dist/client.js
64279
64374
  var ParallClient = class _ParallClient extends AttachmentClient {
64280
64375
  baseUrl;
@@ -64480,23 +64575,27 @@ var ParallClient = class _ParallClient extends AttachmentClient {
64480
64575
  * Multipart upload variant of `request`. Same auth / refresh / error
64481
64576
  * handling, but lets the caller hand us a prepared `FormData` (file +
64482
64577
  * text fields) and skips the JSON content-type. Used by
64483
- * uploadWikiFile / uploadWikiFileToChangeset — wiki binary uploads can
64578
+ * uploadWikiFile / uploadWikiFileToChangeset — wiki file uploads can
64484
64579
  * hit the 100 MiB cap, so a longer 5-minute timeout is used so a
64485
64580
  * 50 MiB blob on a slow connection doesn't get chopped at 15 s.
64486
64581
  */
64487
- async multipartRequest(method, path7, body, retried = false) {
64582
+ async multipartRequest(method, path7, body, retried = false, opts) {
64488
64583
  if (!retried) {
64489
64584
  await this.ensureFreshToken(path7);
64490
64585
  }
64491
64586
  const { "Content-Type": _drop, ...headers } = this.buildHeaders(path7);
64492
64587
  void _drop;
64588
+ const timeoutMs = opts?.timeoutMs ?? 5 * 60 * 1e3;
64493
64589
  let res;
64494
64590
  try {
64495
- res = await fetch(`${this.baseUrlFor(path7)}${path7}`, {
64591
+ res = await sendMultipartRequest({
64496
64592
  method,
64593
+ url: `${this.baseUrlFor(path7)}${path7}`,
64497
64594
  headers,
64498
64595
  body,
64499
- signal: AbortSignal.timeout(5 * 60 * 1e3)
64596
+ timeoutMs,
64597
+ signal: opts?.signal,
64598
+ onProgress: opts?.onProgress
64500
64599
  });
64501
64600
  } catch (err) {
64502
64601
  throw _ParallClient.normalizeFetchError(err);
@@ -64507,7 +64606,7 @@ var ParallClient = class _ParallClient extends AttachmentClient {
64507
64606
  if (!retried && !isAuthPath && this.getRefreshToken) {
64508
64607
  const refreshed = await this.tryRefresh();
64509
64608
  if (refreshed) {
64510
- return this.multipartRequest(method, path7, body, true);
64609
+ return this.multipartRequest(method, path7, body, true, opts);
64511
64610
  }
64512
64611
  }
64513
64612
  if (this.onTokenExpired && !isAuthPath) {
@@ -64586,6 +64685,18 @@ var ParallClient = class _ParallClient extends AttachmentClient {
64586
64685
  async deleteAvatar() {
64587
64686
  return this.request("DELETE", ENDPOINTS.USER_AVATAR);
64588
64687
  }
64688
+ // ---- Personal API keys (org-scoped; JWT session required) ----
64689
+ /** Mints an org-scoped personal API key. The plaintext is returned once and never again. */
64690
+ async createPersonalApiKey(req) {
64691
+ return this.request("POST", ENDPOINTS.PERSONAL_API_KEYS, req);
64692
+ }
64693
+ async listPersonalApiKeys() {
64694
+ const res = await this.request("GET", ENDPOINTS.PERSONAL_API_KEYS);
64695
+ return res.data;
64696
+ }
64697
+ async revokePersonalApiKey(keyId) {
64698
+ return this.request("DELETE", ENDPOINTS.PERSONAL_API_KEY(keyId));
64699
+ }
64589
64700
  async uploadAgentAvatar(orgId, agentId, file) {
64590
64701
  const fd = new FormData();
64591
64702
  fd.append("file", file);
@@ -65804,26 +65915,21 @@ var ParallClient = class _ParallClient extends AttachmentClient {
65804
65915
  * through createWikiChangeset / updateWikiChangeset.
65805
65916
  */
65806
65917
  async uploadWikiFile(orgId, wikiId, params) {
65807
- const fd = new FormData();
65808
- fd.append("path", params.path);
65809
- fd.append("file", params.file);
65810
- if (params.message)
65811
- fd.append("message", params.message);
65812
- return this.multipartRequest("POST", ENDPOINTS.WIKI_UPLOADS(orgId, wikiId), fd);
65918
+ const fd = createWikiUploadFormData(params);
65919
+ return this.multipartRequest("POST", ENDPOINTS.WIKI_UPLOADS(orgId, wikiId), fd, false, {
65920
+ signal: params.signal,
65921
+ onProgress: params.onProgress
65922
+ });
65813
65923
  }
65814
65924
  /**
65815
- * Upload a binary file into a changeset's feature branch (read scope +
65816
- * author-only). Used by reader flow: propose a changeset, attach
65817
- * binary, PATCH markdown that references it. On merge the binary
65818
- * squashes into the default branch.
65925
+ * Upload a file into a changeset's feature branch (read scope +
65926
+ * author-only). The default remains binary-only; contentRoute `auto`
65927
+ * opts into reviewable text for the Web library upload flow. On merge the
65928
+ * branch contents squash into the default branch.
65819
65929
  */
65820
65930
  async uploadWikiFileToChangeset(orgId, wikiId, changesetId, params) {
65821
- const fd = new FormData();
65822
- fd.append("path", params.path);
65823
- fd.append("file", params.file);
65824
- if (params.message)
65825
- fd.append("message", params.message);
65826
- return this.multipartRequest("POST", ENDPOINTS.WIKI_CHANGESET_FILES(orgId, wikiId, changesetId), fd);
65931
+ const fd = createWikiUploadFormData(params);
65932
+ return this.multipartRequest("POST", ENDPOINTS.WIKI_CHANGESET_FILES(orgId, wikiId, changesetId), fd, false, { signal: params.signal, onProgress: params.onProgress });
65827
65933
  }
65828
65934
  /** Remove a binary file from the default branch. Text files must use a
65829
65935
  * changeset delete action. The blob stays reachable via git history. */
@@ -66690,13 +66796,6 @@ var ParallClient = class _ParallClient extends AttachmentClient {
66690
66796
  );
66691
66797
  }
66692
66798
  };
66693
- function normalizeWikiChangeset(changeset) {
66694
- return {
66695
- ...changeset,
66696
- changed_paths: changeset.changed_paths ?? [],
66697
- file_changes: changeset.file_changes ?? []
66698
- };
66699
- }
66700
66799
  var ApiError = class extends Error {
66701
66800
  status;
66702
66801
  code;