@immediately-run/sandbox-protocol 0.4.0 → 0.5.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/dist/sandbox.js +1 -1
- package/dist/sdk.d.ts +13 -1
- package/dist/sdk.js +6 -3
- package/package.json +1 -1
- package/snapshots/sdk.json +44 -0
package/dist/sandbox.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// GENERATED by scripts/generate.mjs — DO NOT EDIT.
|
|
3
3
|
// Source of truth: src/descriptors.protocol.mjs (@immediately-run/sandbox-protocol)
|
|
4
|
-
// descriptorsHash:
|
|
4
|
+
// descriptorsHash: 02b97d7ee61b5716
|
|
5
5
|
//
|
|
6
6
|
// The sandbox↔SDK wire vocabulary (PLATFORM_LAYERING_SPEC §2 / S1). Import the
|
|
7
7
|
// constants instead of writing the string: a rename then has ONE edit site and
|
package/dist/sdk.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Every wire name this side speaks, as a union. */
|
|
2
|
-
export type WireName = 'api-catalog' | 'auth-state' | 'compile' | 'debug-enabled' | 'debug-log' | 'debug-query' | 'debug-query-result' | 'diagnostics' | 'dnd-cancel' | 'dropped-item' | 'editor-context' | 'form-factor' | 'fs-change' | 'host-attention' | 'invitations' | 'launch-dismiss' | 'launch-ended' | 'llm-provider' | 'metadata-update' | 'mount-add' | 'mount-remove' | 'protocol-contribute' | 'protocol-dnd' | 'protocol-editor' | 'protocol-fetch' | 'protocol-ipc' | 'protocol-launch' | 'protocol-llm' | 'protocol-secrets' | 'protocol-settings' | 'protocol-spaces' | 'protocol-task' | 'protocol-theme' | 'protocol-vcs' | 'region-message' | 'request-api-catalog' | 'request-auth-state' | 'request-debug-enabled' | 'request-diagnostics' | 'request-editor-context' | 'request-form-factor' | 'request-handshake' | 'request-host-attention' | 'request-invitations' | 'request-llm-provider' | 'request-mounts' | 'request-secrets-metadata' | 'request-session-mounts' | 'request-theme' | 'request-vcs-state' | 'sdk-handshake' | 'secrets-metadata' | 'session-mounts' | 'task-cancel' | 'task-complete' | 'task-input' | 'theme' | 'urlchange' | 'vcs-state';
|
|
2
|
+
export type WireName = 'api-catalog' | 'auth-state' | 'compile' | 'debug-enabled' | 'debug-log' | 'debug-query' | 'debug-query-result' | 'diagnostics' | 'dnd-cancel' | 'dropped-item' | 'editor-context' | 'form-factor' | 'fs-change' | 'host-attention' | 'invitations' | 'launch-dismiss' | 'launch-ended' | 'llm-provider' | 'metadata-update' | 'mount-add' | 'mount-remove' | 'protocol-analytics' | 'protocol-contribute' | 'protocol-dnd' | 'protocol-editor' | 'protocol-fetch' | 'protocol-ipc' | 'protocol-launch' | 'protocol-llm' | 'protocol-secrets' | 'protocol-settings' | 'protocol-spaces' | 'protocol-task' | 'protocol-theme' | 'protocol-vcs' | 'region-message' | 'request-api-catalog' | 'request-auth-state' | 'request-debug-enabled' | 'request-diagnostics' | 'request-editor-context' | 'request-form-factor' | 'request-handshake' | 'request-host-attention' | 'request-invitations' | 'request-llm-provider' | 'request-mounts' | 'request-secrets-metadata' | 'request-session-mounts' | 'request-theme' | 'request-vcs-state' | 'sdk-handshake' | 'secrets-metadata' | 'session-mounts' | 'task-cancel' | 'task-complete' | 'task-input' | 'theme' | 'urlchange' | 'vcs-state';
|
|
3
3
|
/** `api-catalog` — push · host->app. polled with `request-api-catalog`. */
|
|
4
4
|
export declare const API_CATALOG = "api-catalog";
|
|
5
5
|
/** Read off this message today: `methods`. */
|
|
@@ -91,6 +91,17 @@ export declare const MOUNT_ADD = "mount-add";
|
|
|
91
91
|
/** `mount-remove` — message · host->app. */
|
|
92
92
|
export declare const MOUNT_REMOVE = "mount-remove";
|
|
93
93
|
/** Read off this message today: `id`, `path`, `reason`. */
|
|
94
|
+
/** `protocol-analytics` — request · app->host. */
|
|
95
|
+
export declare const PROTOCOL_ANALYTICS = "protocol-analytics";
|
|
96
|
+
/** Params of `protocol-analytics` method `emit`. */
|
|
97
|
+
export interface ProtocolAnalyticsEmitParams {
|
|
98
|
+
name: string;
|
|
99
|
+
props?: unknown | undefined;
|
|
100
|
+
}
|
|
101
|
+
/** Params of `protocol-analytics` method `route`. */
|
|
102
|
+
export interface ProtocolAnalyticsRouteParams {
|
|
103
|
+
path: string;
|
|
104
|
+
}
|
|
94
105
|
/** `protocol-contribute` — stream · app->host. */
|
|
95
106
|
export declare const PROTOCOL_CONTRIBUTE = "protocol-contribute";
|
|
96
107
|
/** Params of `protocol-contribute` method `run`. */
|
|
@@ -345,6 +356,7 @@ export declare const WIRE_NAMES: {
|
|
|
345
356
|
readonly METADATA_UPDATE: "metadata-update";
|
|
346
357
|
readonly MOUNT_ADD: "mount-add";
|
|
347
358
|
readonly MOUNT_REMOVE: "mount-remove";
|
|
359
|
+
readonly PROTOCOL_ANALYTICS: "protocol-analytics";
|
|
348
360
|
readonly PROTOCOL_CONTRIBUTE: "protocol-contribute";
|
|
349
361
|
readonly PROTOCOL_DND: "protocol-dnd";
|
|
350
362
|
readonly PROTOCOL_EDITOR: "protocol-editor";
|
package/dist/sdk.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// GENERATED by scripts/generate.mjs — DO NOT EDIT.
|
|
3
3
|
// Source of truth: src/descriptors.protocol.mjs (@immediately-run/sandbox-protocol)
|
|
4
|
-
// descriptorsHash:
|
|
4
|
+
// descriptorsHash: 02b97d7ee61b5716
|
|
5
5
|
//
|
|
6
6
|
// The sandbox↔SDK wire vocabulary (PLATFORM_LAYERING_SPEC §2 / S1). Import the
|
|
7
7
|
// constants instead of writing the string: a rename then has ONE edit site and
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
// that has a declared shape; a name handled as `any` today gets its read field
|
|
10
10
|
// list in the doc comment instead (R3-274e is where those grow real types).
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
13
|
-
exports.WIRE_NAMES = exports.VCS_STATE = exports.URLCHANGE = exports.THEME = exports.TASK_INPUT = exports.TASK_COMPLETE = exports.TASK_CANCEL = exports.SESSION_MOUNTS = exports.SECRETS_METADATA = exports.SDK_HANDSHAKE = void 0;
|
|
12
|
+
exports.REQUEST_THEME = exports.REQUEST_SESSION_MOUNTS = exports.REQUEST_SECRETS_METADATA = exports.REQUEST_MOUNTS = exports.REQUEST_LLM_PROVIDER = exports.REQUEST_INVITATIONS = exports.REQUEST_HOST_ATTENTION = exports.REQUEST_HANDSHAKE = exports.REQUEST_FORM_FACTOR = exports.REQUEST_EDITOR_CONTEXT = exports.REQUEST_DIAGNOSTICS = exports.REQUEST_DEBUG_ENABLED = exports.REQUEST_AUTH_STATE = exports.REQUEST_API_CATALOG = exports.REGION_MESSAGE = exports.PROTOCOL_VCS = exports.PROTOCOL_THEME = exports.PROTOCOL_TASK = exports.PROTOCOL_SPACES = exports.PROTOCOL_SETTINGS = exports.PROTOCOL_SECRETS = exports.PROTOCOL_LLM = exports.PROTOCOL_LAUNCH = exports.PROTOCOL_IPC = exports.PROTOCOL_FETCH = exports.PROTOCOL_EDITOR = exports.PROTOCOL_DND = exports.PROTOCOL_CONTRIBUTE = exports.PROTOCOL_ANALYTICS = exports.MOUNT_REMOVE = exports.MOUNT_ADD = exports.METADATA_UPDATE = exports.LLM_PROVIDER = exports.LAUNCH_ENDED = exports.LAUNCH_DISMISS = exports.INVITATIONS = exports.HOST_ATTENTION = exports.FS_CHANGE = exports.FORM_FACTOR = exports.EDITOR_CONTEXT = exports.DROPPED_ITEM = exports.DND_CANCEL = exports.DIAGNOSTICS = exports.DEBUG_QUERY_RESULT = exports.DEBUG_QUERY = exports.DEBUG_LOG = exports.DEBUG_ENABLED = exports.COMPILE = exports.AUTH_STATE = exports.API_CATALOG = void 0;
|
|
13
|
+
exports.WIRE_NAMES = exports.VCS_STATE = exports.URLCHANGE = exports.THEME = exports.TASK_INPUT = exports.TASK_COMPLETE = exports.TASK_CANCEL = exports.SESSION_MOUNTS = exports.SECRETS_METADATA = exports.SDK_HANDSHAKE = exports.REQUEST_VCS_STATE = void 0;
|
|
14
14
|
/** `api-catalog` — push · host->app. polled with `request-api-catalog`. */
|
|
15
15
|
exports.API_CATALOG = 'api-catalog';
|
|
16
16
|
/** Read off this message today: `methods`. */
|
|
@@ -65,6 +65,8 @@ exports.MOUNT_ADD = 'mount-add';
|
|
|
65
65
|
/** `mount-remove` — message · host->app. */
|
|
66
66
|
exports.MOUNT_REMOVE = 'mount-remove';
|
|
67
67
|
/** Read off this message today: `id`, `path`, `reason`. */
|
|
68
|
+
/** `protocol-analytics` — request · app->host. */
|
|
69
|
+
exports.PROTOCOL_ANALYTICS = 'protocol-analytics';
|
|
68
70
|
/** `protocol-contribute` — stream · app->host. */
|
|
69
71
|
exports.PROTOCOL_CONTRIBUTE = 'protocol-contribute';
|
|
70
72
|
/** `protocol-dnd` — request · app->host. */
|
|
@@ -168,6 +170,7 @@ exports.WIRE_NAMES = {
|
|
|
168
170
|
METADATA_UPDATE: exports.METADATA_UPDATE,
|
|
169
171
|
MOUNT_ADD: exports.MOUNT_ADD,
|
|
170
172
|
MOUNT_REMOVE: exports.MOUNT_REMOVE,
|
|
173
|
+
PROTOCOL_ANALYTICS: exports.PROTOCOL_ANALYTICS,
|
|
171
174
|
PROTOCOL_CONTRIBUTE: exports.PROTOCOL_CONTRIBUTE,
|
|
172
175
|
PROTOCOL_DND: exports.PROTOCOL_DND,
|
|
173
176
|
PROTOCOL_EDITOR: exports.PROTOCOL_EDITOR,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@immediately-run/sandbox-protocol",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "The sandbox<->SDK wire protocol: ONE descriptor set, projected into the wire-name constants, the payload types, and the per-side snapshots both repos gate against (PLATFORM_LAYERING_SPEC S1). Consumed by sandbox and immediately-run-sdk so a wire change is a version bump, not a hand-copied file.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"repository": {
|
package/snapshots/sdk.json
CHANGED
|
@@ -753,6 +753,49 @@
|
|
|
753
753
|
"src/mounts.ts"
|
|
754
754
|
]
|
|
755
755
|
},
|
|
756
|
+
"protocol-analytics": {
|
|
757
|
+
"kind": "request",
|
|
758
|
+
"direction": "app->host",
|
|
759
|
+
"methods": {
|
|
760
|
+
"emit": {
|
|
761
|
+
"payload": {
|
|
762
|
+
"fields": [
|
|
763
|
+
{
|
|
764
|
+
"name": "name",
|
|
765
|
+
"optional": false,
|
|
766
|
+
"type": "string"
|
|
767
|
+
},
|
|
768
|
+
{
|
|
769
|
+
"name": "props",
|
|
770
|
+
"optional": true,
|
|
771
|
+
"union": [
|
|
772
|
+
{
|
|
773
|
+
"type": "Record<string, AnalyticsPropValue>"
|
|
774
|
+
},
|
|
775
|
+
{
|
|
776
|
+
"type": "undefined"
|
|
777
|
+
}
|
|
778
|
+
]
|
|
779
|
+
}
|
|
780
|
+
]
|
|
781
|
+
}
|
|
782
|
+
},
|
|
783
|
+
"route": {
|
|
784
|
+
"payload": {
|
|
785
|
+
"fields": [
|
|
786
|
+
{
|
|
787
|
+
"name": "path",
|
|
788
|
+
"optional": false,
|
|
789
|
+
"type": "string"
|
|
790
|
+
}
|
|
791
|
+
]
|
|
792
|
+
}
|
|
793
|
+
}
|
|
794
|
+
},
|
|
795
|
+
"sites": [
|
|
796
|
+
"src/analytics.ts"
|
|
797
|
+
]
|
|
798
|
+
},
|
|
756
799
|
"protocol-contribute": {
|
|
757
800
|
"kind": "stream",
|
|
758
801
|
"direction": "app->host",
|
|
@@ -2071,6 +2114,7 @@
|
|
|
2071
2114
|
"dynamicFamilies": {
|
|
2072
2115
|
"protocol-<scheme>": {
|
|
2073
2116
|
"schemes": [
|
|
2117
|
+
"analytics",
|
|
2074
2118
|
"contribute",
|
|
2075
2119
|
"dnd",
|
|
2076
2120
|
"editor",
|