lumiverse-spindle-types 0.6.48 → 0.6.49

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/api.d.ts CHANGED
@@ -4887,6 +4887,15 @@ export type WorkerToHost = import("./decisions.js").DecisionWorkerMessage | impo
4887
4887
  } | {
4888
4888
  type: "version_get_frontend";
4889
4889
  requestId: string;
4890
+ } | {
4891
+ type: "version_get_commit";
4892
+ requestId: string;
4893
+ } | {
4894
+ type: "version_get_branch";
4895
+ requestId: string;
4896
+ } | {
4897
+ type: "version_get_info";
4898
+ requestId: string;
4890
4899
  } | {
4891
4900
  type: "tokens_count_text";
4892
4901
  requestId: string;
package/dist/host.d.ts CHANGED
@@ -13,6 +13,24 @@ export interface SpindleHostDescriptorV1 {
13
13
  readonly capabilities: Readonly<Record<string, number>>;
14
14
  readonly extensionInstallationId: string;
15
15
  }
16
+ /**
17
+ * Version report for the running Lumiverse install, returned by
18
+ * `spindle.version.getInfo()` (free tier — no permission needed).
19
+ */
20
+ export interface LumiverseVersionInfo {
21
+ /** Backend server semantic version (e.g. `"1.2.5"`). */
22
+ readonly backend: string;
23
+ /** Frontend bundle semantic version (e.g. `"1.2.5"`). */
24
+ readonly frontend: string;
25
+ /**
26
+ * Commit the running build was made from (e.g. `"26939aa5"`), or `null`
27
+ * when unavailable — Docker images, detached/non-git installs, and other
28
+ * builds without git metadata report `null` rather than guessing.
29
+ */
30
+ readonly commit: string | null;
31
+ /** Branch the running build was made from, or `null` when unavailable or HEAD is detached. */
32
+ readonly branch: string | null;
33
+ }
16
34
  /** Locale identifiers supplied by the host's active UI locale. */
17
35
  export type SpindleHostLocale = "en" | "zh" | "zh-TW" | "ja" | "fr" | "it";
18
36
  /** Synchronous host locale lookup with a removable live-change subscription. */
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  export type { DecisionJsonValue, DecisionDescription, DecisionState, DecisionQuestion, DecisionAnswer, DecisionAnswerFor, DecisionAnswers, DecisionResult, DecisionEvaluationInput, DecisionConnectionProfileDTO, DecisionModelDTO, DecisionProviderDTO, SpindleDecisionsAPI, DecisionWorkerMessage } from "./decisions.js";
2
2
  export type { SpindleManifest, SpindlePermission, SpindleCapability, } from "./manifest.js";
3
3
  export { IDENTIFIER_PATTERN, validateIdentifier, } from "./manifest.js";
4
- export type { SpindleHostDescriptorV1, SpindleHostLocale, SpindleHostLocaleAPI, } from "./host.js";
4
+ export type { LumiverseVersionInfo, SpindleHostDescriptorV1, SpindleHostLocale, SpindleHostLocaleAPI, } from "./host.js";
5
5
  export type { SpindleFileRef, SpindleFileSource, FileOperationOptions, FileFetchOptions, SpindleFileCreateInput, SpindleFileChunk, SpindleArchiveEntry, ArchiveCreateOptions, ArchiveExtractOptions, SpindleArchiveExtractedEntry, SpindleFilesAPI, SpindleArchivesAPI, SpindleFileDownloadAPI, FileTransferWorkerMessage, } from "./file-transfers.js";
6
6
  export { SPINDLE_FILE_CHUNK_BYTES, SPINDLE_FILE_MAX_BYTES, SPINDLE_FILE_DEFAULT_MAX_BYTES, SPINDLE_FILE_TTL_MS, SPINDLE_FILE_MAX_COUNT, } from "./file-transfers.js";
7
7
  export { SPINDLE_HOST_CAPABILITIES, SPINDLE_COMPATIBILITY_ERROR_CODE, } from "./host.js";
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Gated permissions that extensions must declare in spindle.json.
3
3
  *
4
- * Free tier (no declaration needed): events, storage, macros, dom, variables
4
+ * Free tier (no declaration needed): events, storage, macros, dom, variables, version
5
5
  *
6
6
  * Gated tier (must declare):
7
7
  * - "decisions" — inspect and invoke saved Decision model connections
@@ -1,5 +1,5 @@
1
1
  import type { SpindleManifest } from "./manifest.js";
2
- import type { SpindleHostDescriptorV1 } from "./host.js";
2
+ import type { LumiverseVersionInfo, SpindleHostDescriptorV1 } from "./host.js";
3
3
  import type { SpindleDesktopAPI } from "./desktop-capture.js";
4
4
  import type { SpindleFilesAPI, SpindleArchivesAPI } from "./file-transfers.js";
5
5
  import type { SpindleTextEditorOptions, SpindleTextEditorResult } from "./dom.js";
@@ -2214,13 +2214,24 @@ export interface SpindleAPI {
2214
2214
  /**
2215
2215
  * Lumiverse version info (free tier — no permission needed).
2216
2216
  * Returns the semantic version strings reported by the backend server
2217
- * and frontend bundle. Useful for feature gating or compatibility checks.
2217
+ * and frontend bundle, plus the commit and branch the build was made
2218
+ * from when available. Useful for feature gating or compatibility checks.
2218
2219
  */
2219
2220
  version: {
2220
2221
  /** Get the backend server's semantic version (e.g. `"0.8.7"`). */
2221
2222
  getBackend(): Promise<string>;
2222
2223
  /** Get the frontend's semantic version (e.g. `"0.8.7"`). */
2223
2224
  getFrontend(): Promise<string>;
2225
+ /**
2226
+ * Get the commit the running build was made from (e.g. `"26939aa5"`),
2227
+ * or `null` when unavailable (Docker images and other builds without
2228
+ * git metadata report `null` rather than guessing).
2229
+ */
2230
+ getCommit(): Promise<string | null>;
2231
+ /** Get the branch the running build was made from, or `null` when unavailable or HEAD is detached. */
2232
+ getBranch(): Promise<string | null>;
2233
+ /** Get the backend/frontend semver, commit, and branch as a single report. */
2234
+ getInfo(): Promise<LumiverseVersionInfo>;
2224
2235
  };
2225
2236
  /** This extension's manifest */
2226
2237
  manifest: SpindleManifest;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lumiverse-spindle-types",
3
- "version": "0.6.48",
3
+ "version": "0.6.49",
4
4
  "type": "module",
5
5
  "types": "./dist/index.d.ts",
6
6
  "keywords": [