@open-mercato/cezar 0.19.0-pr1895.4324 → 0.19.0-pr1908.4332
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/dist/contract/health.d.ts +2 -0
- package/dist/contract/index.d.ts +1 -0
- package/dist/contract/index.js +122 -0
- package/dist/contract/phones.d.ts +287 -0
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/managers/engine.d.ts +1 -0
- package/dist/managers/engine.js +7 -5
- package/dist/managers/engine.js.map +1 -1
- package/dist/relay/connection.d.ts +89 -0
- package/dist/relay/connection.js +385 -0
- package/dist/relay/connection.js.map +1 -0
- package/dist/relay/devices.d.ts +48 -0
- package/dist/relay/devices.js +145 -0
- package/dist/relay/devices.js.map +1 -0
- package/dist/relay/dispatcher.d.ts +68 -0
- package/dist/relay/dispatcher.js +332 -0
- package/dist/relay/dispatcher.js.map +1 -0
- package/dist/relay/identity.d.ts +24 -0
- package/dist/relay/identity.js +102 -0
- package/dist/relay/identity.js.map +1 -0
- package/dist/relay/noise.d.ts +59 -0
- package/dist/relay/noise.js +234 -0
- package/dist/relay/noise.js.map +1 -0
- package/dist/relay/pairing.d.ts +73 -0
- package/dist/relay/pairing.js +260 -0
- package/dist/relay/pairing.js.map +1 -0
- package/dist/relay/probe.d.ts +8 -0
- package/dist/relay/probe.js +71 -0
- package/dist/relay/probe.js.map +1 -0
- package/dist/relay/rendezvous.d.ts +87 -0
- package/dist/relay/rendezvous.js +240 -0
- package/dist/relay/rendezvous.js.map +1 -0
- package/dist/relay/scope.d.ts +14 -0
- package/dist/relay/scope.js +20 -0
- package/dist/relay/scope.js.map +1 -0
- package/dist/relay/service.d.ts +124 -0
- package/dist/relay/service.js +604 -0
- package/dist/relay/service.js.map +1 -0
- package/dist/relay/session.d.ts +65 -0
- package/dist/relay/session.js +228 -0
- package/dist/relay/session.js.map +1 -0
- package/dist/relay/socket.d.ts +21 -0
- package/dist/relay/socket.js +66 -0
- package/dist/relay/socket.js.map +1 -0
- package/dist/relay/wire.d.ts +132 -0
- package/dist/relay/wire.js +287 -0
- package/dist/relay/wire.js.map +1 -0
- package/dist/runs/task-refs.js +17 -8
- package/dist/runs/task-refs.js.map +1 -1
- package/dist/self-update/service.d.ts +3 -1
- package/dist/self-update/service.js +8 -5
- package/dist/self-update/service.js.map +1 -1
- package/dist/server/capabilities.js +3 -0
- package/dist/server/capabilities.js.map +1 -1
- package/dist/server/project-context.js +4 -2
- package/dist/server/project-context.js.map +1 -1
- package/dist/server/server.d.ts +411 -18
- package/dist/server/server.js +129 -33
- package/dist/server/server.js.map +1 -1
- package/dist/server/webhooks.js +4 -0
- package/dist/server/webhooks.js.map +1 -1
- package/dist/server/ws.js +3 -2
- package/dist/server/ws.js.map +1 -1
- package/dist/workflows/run.js +4 -3
- package/dist/workflows/run.js.map +1 -1
- package/dist/workspace/config.d.ts +4 -0
- package/dist/workspace/config.js +14 -2
- package/dist/workspace/config.js.map +1 -1
- package/package.json +3 -3
- package/web/dist/assets/{active-forge-C-_PdZgg.js → active-forge-DEmP_h4r.js} +1 -1
- package/web/dist/assets/{agent-task-pickers-KKwKivxO.js → agent-task-pickers-8skJH9bS.js} +1 -1
- package/web/dist/assets/{alert-dialog-DzQLw5to.js → alert-dialog-BZkKvKiu.js} +1 -1
- package/web/dist/assets/arrow-down-cBTb_EjO.js +1 -0
- package/web/dist/assets/arrow-left-BvR1Oqhc.js +1 -0
- package/web/dist/assets/arrow-up-Cn0IS81u.js +1 -0
- package/web/dist/assets/ask-answer-Cfb0vEFv.js +1 -0
- package/web/dist/assets/{ask-card-B3jWKF62.js → ask-card-CfNUHYt9.js} +1 -1
- package/web/dist/assets/{automation-format-w8_9nvYJ.js → automation-format-BPrWgGBz.js} +1 -1
- package/web/dist/assets/{automations-route-BOxtN2HL.js → automations-route-B4axw9eb.js} +1 -1
- package/web/dist/assets/{bot-Cs9MQd2C.js → bot-qZRkHkDp.js} +1 -1
- package/web/dist/assets/{button-D5FFOAeu.js → button-BrxohNcK.js} +1 -1
- package/web/dist/assets/{centered-state-CP55386O.js → centered-state-CSW_o4N7.js} +1 -1
- package/web/dist/assets/check-B5omShEO.js +1 -0
- package/web/dist/assets/chevron-left-D74_-PJ_.js +1 -0
- package/web/dist/assets/chevron-right-C3fLn_fF.js +1 -0
- package/web/dist/assets/{circle-alert-5MWttBkd.js → circle-alert-COKQc-87.js} +1 -1
- package/web/dist/assets/circle-check-j6r9xbE5.js +1 -0
- package/web/dist/assets/{collapsible-DCjeSotW.js → collapsible-BJ0sxcz9.js} +1 -1
- package/web/dist/assets/{commit-list-BbqlO4aH.js → commit-list-HXZj01RO.js} +1 -1
- package/web/dist/assets/{compare-variants-CRXWB-Lt.js → compare-variants-CDrFR7P_.js} +1 -1
- package/web/dist/assets/{composer-CM2zU1kg.js → composer-GntpkeQD.js} +1 -1
- package/web/dist/assets/{composer-attachments-Cm_UaXht.js → composer-attachments-Xa-qW8Eq.js} +1 -1
- package/web/dist/assets/{dashboard-Ba_HDzNi.js → dashboard-CJW-Xk7f.js} +1 -1
- package/web/dist/assets/{diff-CogrXJWG.js → diff-RPASOQVF.js} +2 -2
- package/web/dist/assets/{diff-view-Byno8b8N.js → diff-view-Ckaab4uQ.js} +1 -1
- package/web/dist/assets/{directional-usage-BsXaIJKW.js → directional-usage-BtjgT5nc.js} +1 -1
- package/web/dist/assets/{download-B3DkC-bv.js → download-DH68Y5Vz.js} +1 -1
- package/web/dist/assets/{external-link-zzDZyHwY.js → external-link-BVYdhpSK.js} +1 -1
- package/web/dist/assets/{file-mweNu-_v.js → file-DYpKJvYs.js} +1 -1
- package/web/dist/assets/{file-preview-ByHC9ehC.js → file-preview-DOSEbcqV.js} +1 -1
- package/web/dist/assets/{folder-CApLhnHY.js → folder-CeFUSrsO.js} +1 -1
- package/web/dist/assets/{git-pull-request-draft-CsckKRgM.js → git-pull-request-draft-DL1VMp1L.js} +1 -1
- package/web/dist/assets/{git-tab-loading-DqmJV1ZG.js → git-tab-loading-DhclV71X.js} +1 -1
- package/web/dist/assets/{git-toolbar-u3bSozbj.js → git-toolbar-Bk-3i42V.js} +1 -1
- package/web/dist/assets/{github-yoo-2ZT0.js → github-TdBnzj-H.js} +1 -1
- package/web/dist/assets/{host-usage-BKVevGLj.js → host-usage-o1rC0TiP.js} +1 -1
- package/web/dist/assets/{icon-tooltip-DcLjMBtU.js → icon-tooltip-CUJLXOxf.js} +1 -1
- package/web/dist/assets/index-CDhEdFaZ.js +33 -0
- package/web/dist/assets/index-Dk1VTlxY.css +2 -0
- package/web/dist/assets/{input-oDwCK3fd.js → input-BxjGaO_P.js} +1 -1
- package/web/dist/assets/{layout-cards-CGpFi-NX.js → layout-cards-BYOEsNbu.js} +1 -1
- package/web/dist/assets/{layout-grid-GA_0wTEU.js → layout-grid-C4d5rrDE.js} +1 -1
- package/web/dist/assets/{lib-D2liL_SJ.js → lib-D2__YoPr.js} +1 -1
- package/web/dist/assets/loader-circle-DCpZCAyT.js +1 -0
- package/web/dist/assets/{manager-chat-DHnV7liI.js → manager-chat-B1Taq3Eg.js} +1 -1
- package/web/dist/assets/{manager-index-wFeR3v3L.js → manager-index-COwisKDf.js} +1 -1
- package/web/dist/assets/{manager-new-CcJNGB9V.js → manager-new-BdJPiBs2.js} +1 -1
- package/web/dist/assets/{manager-pickers-BdcqExo1.js → manager-pickers-CvYpd5cU.js} +1 -1
- package/web/dist/assets/{managers-C6rZIgcS.js → managers-CDiETPHi.js} +1 -1
- package/web/dist/assets/{markdown-BQeRxp3e.js → markdown-Di8pirEb.js} +1 -1
- package/web/dist/assets/{markdown--tMxrFYe.js → markdown-rDA5iFAU.js} +1 -1
- package/web/dist/assets/{message-square-BrT83MDu.js → message-square-CstvkIHe.js} +1 -1
- package/web/dist/assets/{pencil-BmXvj5kf.js → pencil-DWtoOm2f.js} +1 -1
- package/web/dist/assets/{picker-pill-BVPvpdFn.js → picker-pill-DQICTO2N.js} +1 -1
- package/web/dist/assets/play-BYwEI1EA.js +1 -0
- package/web/dist/assets/plus-BPopgSYQ.js +1 -0
- package/web/dist/assets/{popover-D5AXgA0O.js → popover-DzdYqnHw.js} +1 -1
- package/web/dist/assets/{project-router-BchsWVNj.js → project-router-CmpQcVZp.js} +1 -1
- package/web/dist/assets/{queries-C-tAKRCi.js → queries-DOHu2y2B.js} +1 -1
- package/web/dist/assets/{reference-chip-DxkzPL-2.js → reference-chip-ty5g_OLC.js} +1 -1
- package/web/dist/assets/{reference-conflict-action-RTCKJRKI.js → reference-conflict-action-B2LrO-o3.js} +1 -1
- package/web/dist/assets/{repo-git-jjLnTklO.js → repo-git-CyoBxHfP.js} +1 -1
- package/web/dist/assets/{run-diff-BM164jU0.js → run-diff-CFHlmgGA.js} +1 -1
- package/web/dist/assets/{save-MznB2ixm.js → save-C4TDysfG.js} +1 -1
- package/web/dist/assets/{scroll-within-DVA5bRyy.js → scroll-within-D3mqUngk.js} +1 -1
- package/web/dist/assets/{search-x-DWxsCXf5.js → search-x-BkezzsKh.js} +1 -1
- package/web/dist/assets/{settings-2-fXumKqyK.js → settings-2-DIHmg7wZ.js} +1 -1
- package/web/dist/assets/{sheet-B6WMHVIq.js → sheet-7RYAcp_E.js} +1 -1
- package/web/dist/assets/{skills-CWN4OvTJ.js → skills-BBqk5FoM.js} +1 -1
- package/web/dist/assets/{sortable.esm-C2C8OJfV.js → sortable.esm-O2daV3YI.js} +1 -1
- package/web/dist/assets/square-BPbl10lx.js +1 -0
- package/web/dist/assets/{status-dot-8NQgUcGm.js → status-dot-C_5ryAFi.js} +1 -1
- package/web/dist/assets/{tabs-RXufwIjt.js → tabs-EEnYYrJF.js} +1 -1
- package/web/dist/assets/{tag-CweXKIph.js → tag-B56iP2zA.js} +1 -1
- package/web/dist/assets/{task-commits-BM0_KToY.js → task-commits-DFalvqkF.js} +1 -1
- package/web/dist/assets/{task-graph-dw351M25.js → task-graph-ZjFyDrAV.js} +1 -1
- package/web/dist/assets/{task-notes-pImKVBNi.js → task-notes-DRDKGsIw.js} +1 -1
- package/web/dist/assets/{task-workspace-DJv24mb3.js → task-workspace-D2ak5sTE.js} +6 -6
- package/web/dist/assets/terminal-B-JX8x9P.js +1 -0
- package/web/dist/assets/{terminal-drawer-Sg9C5JGu.js → terminal-drawer-S0cBMANF.js} +1 -1
- package/web/dist/assets/{terminal-pane-B1I-ifaB.js → terminal-pane-CeYi-FvS.js} +1 -1
- package/web/dist/assets/{textarea-Cq7DDtfD.js → textarea-BXN4nZ0d.js} +1 -1
- package/web/dist/assets/{toaster-Wa7F4iyv.js → toaster-DrFdGtNN.js} +1 -1
- package/web/dist/assets/{tooltip-DtKnqzDA.js → tooltip-p6YPEpXC.js} +1 -1
- package/web/dist/assets/{tracker--eJvMq2y.js → tracker-CFDEuaFt.js} +1 -1
- package/web/dist/assets/{triangle-alert-GmfaRcJN.js → triangle-alert-Crbc2knA.js} +1 -1
- package/web/dist/assets/{upload-D3ets0xI.js → upload-D_kW6AjR.js} +1 -1
- package/web/dist/assets/{use-now-ASrNOof2.js → use-now-DQpgbshl.js} +1 -1
- package/web/dist/assets/{utils-DvM_XxkX.js → utils-Df_1kJEk.js} +1 -1
- package/web/dist/assets/{workflow-graph-YBHJoPgB.js → workflow-graph-Cye5SBdg.js} +1 -1
- package/web/dist/assets/{workflow-CQDl4-8z.js → workflow-j8scU63W.js} +1 -1
- package/web/dist/assets/{worktree-lifecycle-DEPkStwL.js → worktree-lifecycle-Da61xsLH.js} +1 -1
- package/web/dist/assets/{worktree-lifecycle-operation-Ds8wfeoc.js → worktree-lifecycle-operation-mYB7KCpQ.js} +1 -1
- package/web/dist/assets/x-sQR-jRBj.js +1 -0
- package/web/dist/assets/{zoomable-image-CdOa3uR9.js → zoomable-image-CW-pQ6ZO.js} +1 -1
- package/web/dist/index.html +60 -60
- package/web/dist/assets/arrow-down-CmqCCyer.js +0 -1
- package/web/dist/assets/arrow-left-GMAZTo9J.js +0 -1
- package/web/dist/assets/arrow-up-BXq9W_db.js +0 -1
- package/web/dist/assets/ask-answer-D5siM2hW.js +0 -1
- package/web/dist/assets/check-CdQxse6D.js +0 -1
- package/web/dist/assets/chevron-left-ChcO824y.js +0 -1
- package/web/dist/assets/chevron-right-Bju7cOoN.js +0 -1
- package/web/dist/assets/circle-check-CiFQQrr7.js +0 -1
- package/web/dist/assets/index-BCWvvPAv.css +0 -2
- package/web/dist/assets/index-gDOowls7.js +0 -31
- package/web/dist/assets/loader-circle-C4NULY2C.js +0 -1
- package/web/dist/assets/play-YB3b07Ma.js +0 -1
- package/web/dist/assets/plus-4qpaGAmL.js +0 -1
- package/web/dist/assets/square-DaoIWJi2.js +0 -1
- package/web/dist/assets/terminal-rv57Weq5.js +0 -1
- package/web/dist/assets/x-DFmQiiud.js +0 -1
|
@@ -49,6 +49,7 @@ export declare const capabilitiesSchema: z.ZodObject<{
|
|
|
49
49
|
terminal: z.ZodBoolean;
|
|
50
50
|
designMode: z.ZodBoolean;
|
|
51
51
|
followups: z.ZodBoolean;
|
|
52
|
+
phonePairing: z.ZodBoolean;
|
|
52
53
|
singleProject: z.ZodBoolean;
|
|
53
54
|
automations: z.ZodBoolean;
|
|
54
55
|
managers: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -129,6 +130,7 @@ export declare const healthResponseSchema: z.ZodObject<{
|
|
|
129
130
|
terminal: z.ZodBoolean;
|
|
130
131
|
designMode: z.ZodBoolean;
|
|
131
132
|
followups: z.ZodBoolean;
|
|
133
|
+
phonePairing: z.ZodBoolean;
|
|
132
134
|
singleProject: z.ZodBoolean;
|
|
133
135
|
automations: z.ZodBoolean;
|
|
134
136
|
managers: z.ZodOptional<z.ZodBoolean>;
|
package/dist/contract/index.d.ts
CHANGED
package/dist/contract/index.js
CHANGED
|
@@ -84,6 +84,12 @@ var capabilitiesSchema = z2.object({
|
|
|
84
84
|
*/
|
|
85
85
|
designMode: z2.boolean(),
|
|
86
86
|
followups: z2.boolean(),
|
|
87
|
+
/**
|
|
88
|
+
* `true` means Settings offers Connect a phone: `CEZ_RELAY=0` is not set. The relay address is a
|
|
89
|
+
* setting, reported by `GET /workspace/phones` (spec `.ai/specs/2026-11-01-relay-qr-pairing.md`).
|
|
90
|
+
* Always false in a relay scope, so a phone cannot pair another phone.
|
|
91
|
+
*/
|
|
92
|
+
phonePairing: z2.boolean(),
|
|
87
93
|
singleProject: z2.boolean(),
|
|
88
94
|
/**
|
|
89
95
|
* `true` means `CEZ_AUTOMATIONS=1` opted this server into GitHub automations (#801). Off — the
|
|
@@ -5275,6 +5281,103 @@ var usageAccountBindingSchema = z38.object({
|
|
|
5275
5281
|
var usageWindowsSnapshotSchema = usageWindowsObservationSchema.extend({
|
|
5276
5282
|
binding: usageAccountBindingSchema
|
|
5277
5283
|
}).refine((s) => s.provider === s.binding.provider, "Provider must match account binding");
|
|
5284
|
+
|
|
5285
|
+
// ../contract/src/phones.ts
|
|
5286
|
+
import { z as z39 } from "zod";
|
|
5287
|
+
var phonePlatformSchema = z39.enum(["android", "ios"]);
|
|
5288
|
+
var phoneDeviceParamSchema = z39.object({ deviceId: z39.string().regex(/^[A-Za-z0-9_-]{22}$/) });
|
|
5289
|
+
var phonePairingParamSchema = z39.object({ id: z39.uuid() });
|
|
5290
|
+
var relayStatusSchema = z39.enum([
|
|
5291
|
+
"off",
|
|
5292
|
+
"connecting",
|
|
5293
|
+
"connected",
|
|
5294
|
+
"unreachable",
|
|
5295
|
+
"replaced",
|
|
5296
|
+
"rate-limited",
|
|
5297
|
+
"quota",
|
|
5298
|
+
"disabled",
|
|
5299
|
+
"update-required",
|
|
5300
|
+
"locked",
|
|
5301
|
+
"error"
|
|
5302
|
+
]);
|
|
5303
|
+
var phonePairingStatusSchema = z39.enum([
|
|
5304
|
+
"waiting",
|
|
5305
|
+
"handshaking",
|
|
5306
|
+
"confirm",
|
|
5307
|
+
"approving",
|
|
5308
|
+
"approved",
|
|
5309
|
+
"denied",
|
|
5310
|
+
"expired",
|
|
5311
|
+
"cancelled",
|
|
5312
|
+
"failed"
|
|
5313
|
+
]);
|
|
5314
|
+
var phonePairingFailureSchema = z39.enum([
|
|
5315
|
+
"device-limit",
|
|
5316
|
+
"relay-error",
|
|
5317
|
+
"timeout",
|
|
5318
|
+
"cancelled",
|
|
5319
|
+
"contested",
|
|
5320
|
+
"bad-payload",
|
|
5321
|
+
"tunnel-unsupported",
|
|
5322
|
+
"phone-left"
|
|
5323
|
+
]);
|
|
5324
|
+
var phonePairingSchema = z39.object({
|
|
5325
|
+
id: z39.string(),
|
|
5326
|
+
status: phonePairingStatusSchema,
|
|
5327
|
+
expiresAt: z39.string(),
|
|
5328
|
+
method: z39.enum(["qr", "code"]).optional(),
|
|
5329
|
+
phone: z39.object({ name: z39.string(), platform: phonePlatformSchema }).optional(),
|
|
5330
|
+
digits: z39.string().optional(),
|
|
5331
|
+
failure: phonePairingFailureSchema.optional()
|
|
5332
|
+
});
|
|
5333
|
+
var phoneSchema = z39.object({
|
|
5334
|
+
deviceId: z39.string(),
|
|
5335
|
+
label: z39.string(),
|
|
5336
|
+
platform: phonePlatformSchema,
|
|
5337
|
+
addedAt: z39.string(),
|
|
5338
|
+
lastSeenAt: z39.string().optional(),
|
|
5339
|
+
connected: z39.boolean()
|
|
5340
|
+
});
|
|
5341
|
+
var relayAddressSourceSchema = z39.enum(["env", "env-invalid", "settings", "default", "none"]);
|
|
5342
|
+
var phonesResponseSchema = z39.object({
|
|
5343
|
+
/** Empty only for an invalid `CEZ_RELAY_URL`, which `relaySource` says. */
|
|
5344
|
+
relayOrigin: z39.string(),
|
|
5345
|
+
relaySource: relayAddressSourceSchema,
|
|
5346
|
+
relay: z39.object({ status: relayStatusSchema, detail: z39.string().optional() }),
|
|
5347
|
+
phones: z39.array(phoneSchema),
|
|
5348
|
+
pairing: phonePairingSchema.nullable(),
|
|
5349
|
+
/** Grants a `too-many-grants` answer left alive, kept for R5 and shown as a warning. */
|
|
5350
|
+
undeniedGrants: z39.number().optional()
|
|
5351
|
+
});
|
|
5352
|
+
var startPhonePairingResponseSchema = z39.object({
|
|
5353
|
+
id: z39.string(),
|
|
5354
|
+
qr: z39.string(),
|
|
5355
|
+
relayOrigin: z39.string(),
|
|
5356
|
+
expiresAt: z39.string()
|
|
5357
|
+
});
|
|
5358
|
+
var phonePairingCodeResponseSchema = z39.object({ code: z39.string(), relayOrigin: z39.string() });
|
|
5359
|
+
var renamePhoneInputSchema = z39.object({ label: z39.string().trim().min(1).max(64) }).strict();
|
|
5360
|
+
var relayAddressSchema = z39.string().trim().min(1).max(300);
|
|
5361
|
+
var setRelayAddressInputSchema = z39.object({
|
|
5362
|
+
address: relayAddressSchema.nullable(),
|
|
5363
|
+
dropPhones: z39.boolean().optional()
|
|
5364
|
+
}).strict();
|
|
5365
|
+
var testRelayAddressInputSchema = z39.object({ address: relayAddressSchema }).strict();
|
|
5366
|
+
var relayTestFailureSchema = z39.enum([
|
|
5367
|
+
"invalid-address",
|
|
5368
|
+
"unreachable",
|
|
5369
|
+
"not-a-relay",
|
|
5370
|
+
"incompatible",
|
|
5371
|
+
"rate-limited",
|
|
5372
|
+
"disabled",
|
|
5373
|
+
"refused"
|
|
5374
|
+
]);
|
|
5375
|
+
var testRelayAddressResponseSchema = z39.discriminatedUnion("ok", [
|
|
5376
|
+
z39.object({ ok: z39.literal(true), origin: z39.string(), protocol: z39.number() }),
|
|
5377
|
+
z39.object({ ok: z39.literal(false), reason: relayTestFailureSchema })
|
|
5378
|
+
]);
|
|
5379
|
+
var phoneOkResponseSchema = z39.object({ ok: z39.literal(true) });
|
|
5380
|
+
var phonePairingEventSchema = z39.object({ pairing: phonePairingSchema.nullable() });
|
|
5278
5381
|
export {
|
|
5279
5382
|
ADD_PROJECT_DIALOGS,
|
|
5280
5383
|
ATTACHMENT_COUNT_BUCKETS,
|
|
@@ -5654,6 +5757,17 @@ export {
|
|
|
5654
5757
|
parseScheduleDate,
|
|
5655
5758
|
parsedWorkflowSchema,
|
|
5656
5759
|
patchRunInputSchema,
|
|
5760
|
+
phoneDeviceParamSchema,
|
|
5761
|
+
phoneOkResponseSchema,
|
|
5762
|
+
phonePairingCodeResponseSchema,
|
|
5763
|
+
phonePairingEventSchema,
|
|
5764
|
+
phonePairingFailureSchema,
|
|
5765
|
+
phonePairingParamSchema,
|
|
5766
|
+
phonePairingSchema,
|
|
5767
|
+
phonePairingStatusSchema,
|
|
5768
|
+
phonePlatformSchema,
|
|
5769
|
+
phoneSchema,
|
|
5770
|
+
phonesResponseSchema,
|
|
5657
5771
|
pickVariantResponseSchema,
|
|
5658
5772
|
planResponseSchema,
|
|
5659
5773
|
processUsageSchema,
|
|
@@ -5676,11 +5790,15 @@ export {
|
|
|
5676
5790
|
referenceStatusesByProjectSchema,
|
|
5677
5791
|
registerProjectInputSchema,
|
|
5678
5792
|
registerProjectResponseSchema,
|
|
5793
|
+
relayAddressSourceSchema,
|
|
5794
|
+
relayStatusSchema,
|
|
5795
|
+
relayTestFailureSchema,
|
|
5679
5796
|
removeAgentProfileResponseSchema,
|
|
5680
5797
|
removeProjectResponseSchema,
|
|
5681
5798
|
removeQueuedMessageResponseSchema,
|
|
5682
5799
|
removeTodoResponseSchema,
|
|
5683
5800
|
removeWorktreeResponseSchema,
|
|
5801
|
+
renamePhoneInputSchema,
|
|
5684
5802
|
repoBranchResponseSchema,
|
|
5685
5803
|
repoCommitPayloadSchema,
|
|
5686
5804
|
repoFileQuerySchema,
|
|
@@ -5749,6 +5867,7 @@ export {
|
|
|
5749
5867
|
setAgentConfigInputSchema,
|
|
5750
5868
|
setConfigInputSchema,
|
|
5751
5869
|
setConfigResponseSchema,
|
|
5870
|
+
setRelayAddressInputSchema,
|
|
5752
5871
|
setRunDraftInputSchema,
|
|
5753
5872
|
setTelemetryConsentInputSchema,
|
|
5754
5873
|
setWorkspaceConfigInputSchema,
|
|
@@ -5767,6 +5886,7 @@ export {
|
|
|
5767
5886
|
startConditionSchema,
|
|
5768
5887
|
startLifecycleRemovalInputSchema,
|
|
5769
5888
|
startNowResponseSchema,
|
|
5889
|
+
startPhonePairingResponseSchema,
|
|
5770
5890
|
startTodoResponseSchema,
|
|
5771
5891
|
statusEntrySchema,
|
|
5772
5892
|
stepSecretBindingSchema,
|
|
@@ -5791,6 +5911,8 @@ export {
|
|
|
5791
5911
|
terminalSessionParamsSchema,
|
|
5792
5912
|
terminalSessionSchema,
|
|
5793
5913
|
terminalStateSchema,
|
|
5914
|
+
testRelayAddressInputSchema,
|
|
5915
|
+
testRelayAddressResponseSchema,
|
|
5794
5916
|
timeZoneOffsetMs,
|
|
5795
5917
|
todoItemSchema,
|
|
5796
5918
|
trackerAccessSchema,
|
|
@@ -0,0 +1,287 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/** Settings > Connect a phone (spec `.ai/specs/2026-11-01-relay-qr-pairing.md`). */
|
|
3
|
+
export declare const phonePlatformSchema: z.ZodEnum<{
|
|
4
|
+
android: "android";
|
|
5
|
+
ios: "ios";
|
|
6
|
+
}>;
|
|
7
|
+
export type PhonePlatform = z.infer<typeof phonePlatformSchema>;
|
|
8
|
+
export declare const phoneDeviceParamSchema: z.ZodObject<{
|
|
9
|
+
deviceId: z.ZodString;
|
|
10
|
+
}, z.core.$strip>;
|
|
11
|
+
export declare const phonePairingParamSchema: z.ZodObject<{
|
|
12
|
+
id: z.ZodUUID;
|
|
13
|
+
}, z.core.$strip>;
|
|
14
|
+
/** `off` means no socket, which is the normal state with no phone paired. */
|
|
15
|
+
export declare const relayStatusSchema: z.ZodEnum<{
|
|
16
|
+
connected: "connected";
|
|
17
|
+
connecting: "connecting";
|
|
18
|
+
disabled: "disabled";
|
|
19
|
+
error: "error";
|
|
20
|
+
locked: "locked";
|
|
21
|
+
off: "off";
|
|
22
|
+
quota: "quota";
|
|
23
|
+
"rate-limited": "rate-limited";
|
|
24
|
+
replaced: "replaced";
|
|
25
|
+
unreachable: "unreachable";
|
|
26
|
+
"update-required": "update-required";
|
|
27
|
+
}>;
|
|
28
|
+
export type RelayStatus = z.infer<typeof relayStatusSchema>;
|
|
29
|
+
export declare const phonePairingStatusSchema: z.ZodEnum<{
|
|
30
|
+
approved: "approved";
|
|
31
|
+
approving: "approving";
|
|
32
|
+
cancelled: "cancelled";
|
|
33
|
+
confirm: "confirm";
|
|
34
|
+
denied: "denied";
|
|
35
|
+
expired: "expired";
|
|
36
|
+
failed: "failed";
|
|
37
|
+
handshaking: "handshaking";
|
|
38
|
+
waiting: "waiting";
|
|
39
|
+
}>;
|
|
40
|
+
export type PhonePairingStatus = z.infer<typeof phonePairingStatusSchema>;
|
|
41
|
+
export declare const phonePairingFailureSchema: z.ZodEnum<{
|
|
42
|
+
"bad-payload": "bad-payload";
|
|
43
|
+
cancelled: "cancelled";
|
|
44
|
+
contested: "contested";
|
|
45
|
+
"device-limit": "device-limit";
|
|
46
|
+
"phone-left": "phone-left";
|
|
47
|
+
"relay-error": "relay-error";
|
|
48
|
+
timeout: "timeout";
|
|
49
|
+
"tunnel-unsupported": "tunnel-unsupported";
|
|
50
|
+
}>;
|
|
51
|
+
export type PhonePairingFailure = z.infer<typeof phonePairingFailureSchema>;
|
|
52
|
+
/** Never the secret, the code or the QR string: this shape rides SSE and `GET /workspace/phones`. */
|
|
53
|
+
export declare const phonePairingSchema: z.ZodObject<{
|
|
54
|
+
id: z.ZodString;
|
|
55
|
+
status: z.ZodEnum<{
|
|
56
|
+
approved: "approved";
|
|
57
|
+
approving: "approving";
|
|
58
|
+
cancelled: "cancelled";
|
|
59
|
+
confirm: "confirm";
|
|
60
|
+
denied: "denied";
|
|
61
|
+
expired: "expired";
|
|
62
|
+
failed: "failed";
|
|
63
|
+
handshaking: "handshaking";
|
|
64
|
+
waiting: "waiting";
|
|
65
|
+
}>;
|
|
66
|
+
expiresAt: z.ZodString;
|
|
67
|
+
method: z.ZodOptional<z.ZodEnum<{
|
|
68
|
+
code: "code";
|
|
69
|
+
qr: "qr";
|
|
70
|
+
}>>;
|
|
71
|
+
phone: z.ZodOptional<z.ZodObject<{
|
|
72
|
+
name: z.ZodString;
|
|
73
|
+
platform: z.ZodEnum<{
|
|
74
|
+
android: "android";
|
|
75
|
+
ios: "ios";
|
|
76
|
+
}>;
|
|
77
|
+
}, z.core.$strip>>;
|
|
78
|
+
digits: z.ZodOptional<z.ZodString>;
|
|
79
|
+
failure: z.ZodOptional<z.ZodEnum<{
|
|
80
|
+
"bad-payload": "bad-payload";
|
|
81
|
+
cancelled: "cancelled";
|
|
82
|
+
contested: "contested";
|
|
83
|
+
"device-limit": "device-limit";
|
|
84
|
+
"phone-left": "phone-left";
|
|
85
|
+
"relay-error": "relay-error";
|
|
86
|
+
timeout: "timeout";
|
|
87
|
+
"tunnel-unsupported": "tunnel-unsupported";
|
|
88
|
+
}>>;
|
|
89
|
+
}, z.core.$strip>;
|
|
90
|
+
export type PhonePairing = z.infer<typeof phonePairingSchema>;
|
|
91
|
+
export declare const phoneSchema: z.ZodObject<{
|
|
92
|
+
deviceId: z.ZodString;
|
|
93
|
+
label: z.ZodString;
|
|
94
|
+
platform: z.ZodEnum<{
|
|
95
|
+
android: "android";
|
|
96
|
+
ios: "ios";
|
|
97
|
+
}>;
|
|
98
|
+
addedAt: z.ZodString;
|
|
99
|
+
lastSeenAt: z.ZodOptional<z.ZodString>;
|
|
100
|
+
connected: z.ZodBoolean;
|
|
101
|
+
}, z.core.$strip>;
|
|
102
|
+
export type Phone = z.infer<typeof phoneSchema>;
|
|
103
|
+
/** Where `relayOrigin` came from. `env-invalid` is a set `CEZ_RELAY_URL` that § 9.1 refuses; `none` is `CEZ_RELAY=0`. */
|
|
104
|
+
export declare const relayAddressSourceSchema: z.ZodEnum<{
|
|
105
|
+
default: "default";
|
|
106
|
+
env: "env";
|
|
107
|
+
"env-invalid": "env-invalid";
|
|
108
|
+
none: "none";
|
|
109
|
+
settings: "settings";
|
|
110
|
+
}>;
|
|
111
|
+
export type RelayAddressSource = z.infer<typeof relayAddressSourceSchema>;
|
|
112
|
+
export declare const phonesResponseSchema: z.ZodObject<{
|
|
113
|
+
relayOrigin: z.ZodString;
|
|
114
|
+
relaySource: z.ZodEnum<{
|
|
115
|
+
default: "default";
|
|
116
|
+
env: "env";
|
|
117
|
+
"env-invalid": "env-invalid";
|
|
118
|
+
none: "none";
|
|
119
|
+
settings: "settings";
|
|
120
|
+
}>;
|
|
121
|
+
relay: z.ZodObject<{
|
|
122
|
+
status: z.ZodEnum<{
|
|
123
|
+
connected: "connected";
|
|
124
|
+
connecting: "connecting";
|
|
125
|
+
disabled: "disabled";
|
|
126
|
+
error: "error";
|
|
127
|
+
locked: "locked";
|
|
128
|
+
off: "off";
|
|
129
|
+
quota: "quota";
|
|
130
|
+
"rate-limited": "rate-limited";
|
|
131
|
+
replaced: "replaced";
|
|
132
|
+
unreachable: "unreachable";
|
|
133
|
+
"update-required": "update-required";
|
|
134
|
+
}>;
|
|
135
|
+
detail: z.ZodOptional<z.ZodString>;
|
|
136
|
+
}, z.core.$strip>;
|
|
137
|
+
phones: z.ZodArray<z.ZodObject<{
|
|
138
|
+
deviceId: z.ZodString;
|
|
139
|
+
label: z.ZodString;
|
|
140
|
+
platform: z.ZodEnum<{
|
|
141
|
+
android: "android";
|
|
142
|
+
ios: "ios";
|
|
143
|
+
}>;
|
|
144
|
+
addedAt: z.ZodString;
|
|
145
|
+
lastSeenAt: z.ZodOptional<z.ZodString>;
|
|
146
|
+
connected: z.ZodBoolean;
|
|
147
|
+
}, z.core.$strip>>;
|
|
148
|
+
pairing: z.ZodNullable<z.ZodObject<{
|
|
149
|
+
id: z.ZodString;
|
|
150
|
+
status: z.ZodEnum<{
|
|
151
|
+
approved: "approved";
|
|
152
|
+
approving: "approving";
|
|
153
|
+
cancelled: "cancelled";
|
|
154
|
+
confirm: "confirm";
|
|
155
|
+
denied: "denied";
|
|
156
|
+
expired: "expired";
|
|
157
|
+
failed: "failed";
|
|
158
|
+
handshaking: "handshaking";
|
|
159
|
+
waiting: "waiting";
|
|
160
|
+
}>;
|
|
161
|
+
expiresAt: z.ZodString;
|
|
162
|
+
method: z.ZodOptional<z.ZodEnum<{
|
|
163
|
+
code: "code";
|
|
164
|
+
qr: "qr";
|
|
165
|
+
}>>;
|
|
166
|
+
phone: z.ZodOptional<z.ZodObject<{
|
|
167
|
+
name: z.ZodString;
|
|
168
|
+
platform: z.ZodEnum<{
|
|
169
|
+
android: "android";
|
|
170
|
+
ios: "ios";
|
|
171
|
+
}>;
|
|
172
|
+
}, z.core.$strip>>;
|
|
173
|
+
digits: z.ZodOptional<z.ZodString>;
|
|
174
|
+
failure: z.ZodOptional<z.ZodEnum<{
|
|
175
|
+
"bad-payload": "bad-payload";
|
|
176
|
+
cancelled: "cancelled";
|
|
177
|
+
contested: "contested";
|
|
178
|
+
"device-limit": "device-limit";
|
|
179
|
+
"phone-left": "phone-left";
|
|
180
|
+
"relay-error": "relay-error";
|
|
181
|
+
timeout: "timeout";
|
|
182
|
+
"tunnel-unsupported": "tunnel-unsupported";
|
|
183
|
+
}>>;
|
|
184
|
+
}, z.core.$strip>>;
|
|
185
|
+
undeniedGrants: z.ZodOptional<z.ZodNumber>;
|
|
186
|
+
}, z.core.$strip>;
|
|
187
|
+
export type PhonesResponse = z.infer<typeof phonesResponseSchema>;
|
|
188
|
+
/** Carries a credential, like the code below. Sent once, `no-store`, and never logged. */
|
|
189
|
+
export declare const startPhonePairingResponseSchema: z.ZodObject<{
|
|
190
|
+
id: z.ZodString;
|
|
191
|
+
qr: z.ZodString;
|
|
192
|
+
relayOrigin: z.ZodString;
|
|
193
|
+
expiresAt: z.ZodString;
|
|
194
|
+
}, z.core.$strip>;
|
|
195
|
+
export type StartPhonePairingResponse = z.infer<typeof startPhonePairingResponseSchema>;
|
|
196
|
+
/** The typed code, opened only on request so an unused one costs the relay nothing (§ 9.2). */
|
|
197
|
+
export declare const phonePairingCodeResponseSchema: z.ZodObject<{
|
|
198
|
+
code: z.ZodString;
|
|
199
|
+
relayOrigin: z.ZodString;
|
|
200
|
+
}, z.core.$strip>;
|
|
201
|
+
export type PhonePairingCodeResponse = z.infer<typeof phonePairingCodeResponseSchema>;
|
|
202
|
+
export declare const renamePhoneInputSchema: z.ZodObject<{
|
|
203
|
+
label: z.ZodString;
|
|
204
|
+
}, z.core.$strict>;
|
|
205
|
+
export type RenamePhoneInput = z.infer<typeof renamePhoneInputSchema>;
|
|
206
|
+
/** `null` goes back to the default. `dropPhones` is the user's answer to the warning: without it, paired phones refuse the change. */
|
|
207
|
+
export declare const setRelayAddressInputSchema: z.ZodObject<{
|
|
208
|
+
address: z.ZodNullable<z.ZodString>;
|
|
209
|
+
dropPhones: z.ZodOptional<z.ZodBoolean>;
|
|
210
|
+
}, z.core.$strict>;
|
|
211
|
+
export type SetRelayAddressInput = z.infer<typeof setRelayAddressInputSchema>;
|
|
212
|
+
export declare const testRelayAddressInputSchema: z.ZodObject<{
|
|
213
|
+
address: z.ZodString;
|
|
214
|
+
}, z.core.$strict>;
|
|
215
|
+
export type TestRelayAddressInput = z.infer<typeof testRelayAddressInputSchema>;
|
|
216
|
+
export declare const relayTestFailureSchema: z.ZodEnum<{
|
|
217
|
+
disabled: "disabled";
|
|
218
|
+
incompatible: "incompatible";
|
|
219
|
+
"invalid-address": "invalid-address";
|
|
220
|
+
"not-a-relay": "not-a-relay";
|
|
221
|
+
"rate-limited": "rate-limited";
|
|
222
|
+
refused: "refused";
|
|
223
|
+
unreachable: "unreachable";
|
|
224
|
+
}>;
|
|
225
|
+
export type RelayTestFailure = z.infer<typeof relayTestFailureSchema>;
|
|
226
|
+
export declare const testRelayAddressResponseSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
227
|
+
ok: z.ZodLiteral<true>;
|
|
228
|
+
origin: z.ZodString;
|
|
229
|
+
protocol: z.ZodNumber;
|
|
230
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
231
|
+
ok: z.ZodLiteral<false>;
|
|
232
|
+
reason: z.ZodEnum<{
|
|
233
|
+
disabled: "disabled";
|
|
234
|
+
incompatible: "incompatible";
|
|
235
|
+
"invalid-address": "invalid-address";
|
|
236
|
+
"not-a-relay": "not-a-relay";
|
|
237
|
+
"rate-limited": "rate-limited";
|
|
238
|
+
refused: "refused";
|
|
239
|
+
unreachable: "unreachable";
|
|
240
|
+
}>;
|
|
241
|
+
}, z.core.$strip>], "ok">;
|
|
242
|
+
export type TestRelayAddressResponse = z.infer<typeof testRelayAddressResponseSchema>;
|
|
243
|
+
export declare const phoneOkResponseSchema: z.ZodObject<{
|
|
244
|
+
ok: z.ZodLiteral<true>;
|
|
245
|
+
}, z.core.$strip>;
|
|
246
|
+
export type PhoneOkResponse = z.infer<typeof phoneOkResponseSchema>;
|
|
247
|
+
/** `phone-pairing` on `/workspace/events`: something on the screen changed. Withheld from a relay scope. */
|
|
248
|
+
export declare const phonePairingEventSchema: z.ZodObject<{
|
|
249
|
+
pairing: z.ZodNullable<z.ZodObject<{
|
|
250
|
+
id: z.ZodString;
|
|
251
|
+
status: z.ZodEnum<{
|
|
252
|
+
approved: "approved";
|
|
253
|
+
approving: "approving";
|
|
254
|
+
cancelled: "cancelled";
|
|
255
|
+
confirm: "confirm";
|
|
256
|
+
denied: "denied";
|
|
257
|
+
expired: "expired";
|
|
258
|
+
failed: "failed";
|
|
259
|
+
handshaking: "handshaking";
|
|
260
|
+
waiting: "waiting";
|
|
261
|
+
}>;
|
|
262
|
+
expiresAt: z.ZodString;
|
|
263
|
+
method: z.ZodOptional<z.ZodEnum<{
|
|
264
|
+
code: "code";
|
|
265
|
+
qr: "qr";
|
|
266
|
+
}>>;
|
|
267
|
+
phone: z.ZodOptional<z.ZodObject<{
|
|
268
|
+
name: z.ZodString;
|
|
269
|
+
platform: z.ZodEnum<{
|
|
270
|
+
android: "android";
|
|
271
|
+
ios: "ios";
|
|
272
|
+
}>;
|
|
273
|
+
}, z.core.$strip>>;
|
|
274
|
+
digits: z.ZodOptional<z.ZodString>;
|
|
275
|
+
failure: z.ZodOptional<z.ZodEnum<{
|
|
276
|
+
"bad-payload": "bad-payload";
|
|
277
|
+
cancelled: "cancelled";
|
|
278
|
+
contested: "contested";
|
|
279
|
+
"device-limit": "device-limit";
|
|
280
|
+
"phone-left": "phone-left";
|
|
281
|
+
"relay-error": "relay-error";
|
|
282
|
+
timeout: "timeout";
|
|
283
|
+
"tunnel-unsupported": "tunnel-unsupported";
|
|
284
|
+
}>>;
|
|
285
|
+
}, z.core.$strip>>;
|
|
286
|
+
}, z.core.$strip>;
|
|
287
|
+
export type PhonePairingEvent = z.infer<typeof phonePairingEventSchema>;
|
package/dist/index.js
CHANGED
|
@@ -21,6 +21,7 @@ import { RunStore } from './runs/store.js';
|
|
|
21
21
|
import { RunManager } from './workflows/run.js';
|
|
22
22
|
import { loadWorkflows } from './workflows/load.js';
|
|
23
23
|
import { resolveCapabilities } from './server/capabilities.js';
|
|
24
|
+
import { narrowForRelay } from './relay/scope.js';
|
|
24
25
|
import { startServer, WorkspaceEventBus } from './server/server.js';
|
|
25
26
|
import { ProviderRuntimeAuthObserver, recoverWithProviderRuntimeAuthObservation, } from './server/provider-auth-runtime.js';
|
|
26
27
|
import { providersRequiredByWorkflow, unavailableProviderMessage, withSelectedAccounts, } from './server/provider-action-gate.js';
|
|
@@ -422,7 +423,7 @@ async function serveCommand(repoRoot, preferredPort, openBrowser, bindHost) {
|
|
|
422
423
|
runs: semaphore,
|
|
423
424
|
// The server's own predicate, not a second spelling of it: the `/apply` guard decides hosted
|
|
424
425
|
// mode through `resolveCapabilities`, and the two must never disagree (they did, on 127.0.0.2).
|
|
425
|
-
trimPaths: () => !resolveCapabilities(process.env, bindHost).localHandoff,
|
|
426
|
+
trimPaths: () => !narrowForRelay(resolveCapabilities(process.env, bindHost)).localHandoff,
|
|
426
427
|
restart: () => {
|
|
427
428
|
void (httpServer?.shutdownLifecycle() ?? manager.lifecycle.shutdown()).then(() => {
|
|
428
429
|
store.flush({ pretty: true });
|