@mentra/sdk 2.1.31-beta.6 → 3.0.0-alpha.3
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/README.md +54 -9
- package/dist/MiniAppServer.d.ts +58 -0
- package/dist/MiniAppServer.d.ts.map +1 -0
- package/dist/app/server/index.d.ts +143 -88
- package/dist/app/server/index.d.ts.map +1 -1
- package/dist/app/session/events.d.ts +20 -3
- package/dist/app/session/events.d.ts.map +1 -1
- package/dist/app/session/index.d.ts +56 -3
- package/dist/app/session/index.d.ts.map +1 -1
- package/dist/app/session/modules/audio-output-stream.d.ts +108 -0
- package/dist/app/session/modules/audio-output-stream.d.ts.map +1 -0
- package/dist/app/session/modules/audio.d.ts +36 -1
- package/dist/app/session/modules/audio.d.ts.map +1 -1
- package/dist/app/session/modules/camera-managed-extension.d.ts +37 -33
- package/dist/app/session/modules/camera-managed-extension.d.ts.map +1 -1
- package/dist/app/session/modules/camera.d.ts +108 -50
- package/dist/app/session/modules/camera.d.ts.map +1 -1
- package/dist/app/session/modules/index.d.ts +4 -3
- package/dist/app/session/modules/index.d.ts.map +1 -1
- package/dist/app/session/modules/led.d.ts.map +1 -1
- package/dist/app/session/modules/location.d.ts.map +1 -1
- package/dist/app/session/settings.d.ts +5 -1
- package/dist/app/session/settings.d.ts.map +1 -1
- package/dist/app/webview/index.d.ts +67 -9
- package/dist/app/webview/index.d.ts.map +1 -1
- package/dist/constants/log-messages/updates.d.ts +32 -9
- package/dist/constants/log-messages/updates.d.ts.map +1 -1
- package/dist/constants/log-messages/warning.d.ts +12 -0
- package/dist/constants/log-messages/warning.d.ts.map +1 -1
- package/dist/display-utils.d.ts +3 -1
- package/dist/display-utils.d.ts.map +1 -1
- package/dist/display-utils.js +443 -26
- package/dist/display-utils.js.map +10 -6
- package/dist/index.d.ts +22 -14
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8877 -4236
- package/dist/index.js.map +63 -31
- package/dist/internal/_SessionManager.d.ts +76 -0
- package/dist/internal/_SessionManager.d.ts.map +1 -0
- package/dist/logging/clean-transport.d.ts +50 -0
- package/dist/logging/clean-transport.d.ts.map +1 -0
- package/dist/logging/errors.d.ts +90 -0
- package/dist/logging/errors.d.ts.map +1 -0
- package/dist/logging/logger.d.ts +72 -1
- package/dist/logging/logger.d.ts.map +1 -1
- package/dist/logging/telemetry-transport.d.ts +51 -0
- package/dist/logging/telemetry-transport.d.ts.map +1 -0
- package/dist/session/DataStreamRouter.d.ts +219 -0
- package/dist/session/DataStreamRouter.d.ts.map +1 -0
- package/dist/session/MentraSession.d.ts +102 -0
- package/dist/session/MentraSession.d.ts.map +1 -0
- package/dist/session/index.d.ts +2 -0
- package/dist/session/index.d.ts.map +1 -0
- package/dist/session/internal/_ConnectionManager.d.ts +43 -0
- package/dist/session/internal/_ConnectionManager.d.ts.map +1 -0
- package/dist/session/internal/_MessageRouter.d.ts +11 -0
- package/dist/session/internal/_MessageRouter.d.ts.map +1 -0
- package/dist/session/internal/_SubscriptionManager.d.ts +32 -0
- package/dist/session/internal/_SubscriptionManager.d.ts.map +1 -0
- package/dist/session/internal/_V2AudioStreamShim.d.ts +12 -0
- package/dist/session/internal/_V2AudioStreamShim.d.ts.map +1 -0
- package/dist/session/internal/_V2CameraShim.d.ts +51 -0
- package/dist/session/internal/_V2CameraShim.d.ts.map +1 -0
- package/dist/session/internal/_V2EventManagerShim.d.ts +51 -0
- package/dist/session/internal/_V2EventManagerShim.d.ts.map +1 -0
- package/dist/session/internal/_V2SessionShim.d.ts +165 -0
- package/dist/session/internal/_V2SessionShim.d.ts.map +1 -0
- package/dist/session/internal/_V2SettingsShim.d.ts +17 -0
- package/dist/session/internal/_V2SettingsShim.d.ts.map +1 -0
- package/dist/session/managers/CameraManager.d.ts +197 -0
- package/dist/session/managers/CameraManager.d.ts.map +1 -0
- package/dist/session/managers/DashboardManager.d.ts +131 -0
- package/dist/session/managers/DashboardManager.d.ts.map +1 -0
- package/dist/session/managers/DeviceManager.d.ts +332 -0
- package/dist/session/managers/DeviceManager.d.ts.map +1 -0
- package/dist/session/managers/DisplayManager.d.ts +171 -0
- package/dist/session/managers/DisplayManager.d.ts.map +1 -0
- package/dist/session/managers/LedManager.d.ts +131 -0
- package/dist/session/managers/LedManager.d.ts.map +1 -0
- package/dist/session/managers/LocationManager.d.ts +255 -0
- package/dist/session/managers/LocationManager.d.ts.map +1 -0
- package/dist/session/managers/MicManager.d.ts +252 -0
- package/dist/session/managers/MicManager.d.ts.map +1 -0
- package/dist/session/managers/PermissionsManager.d.ts +182 -0
- package/dist/session/managers/PermissionsManager.d.ts.map +1 -0
- package/dist/session/managers/PhoneManager.d.ts +295 -0
- package/dist/session/managers/PhoneManager.d.ts.map +1 -0
- package/dist/session/managers/SpeakerManager.d.ts +285 -0
- package/dist/session/managers/SpeakerManager.d.ts.map +1 -0
- package/dist/session/managers/StorageManager.d.ts +289 -0
- package/dist/session/managers/StorageManager.d.ts.map +1 -0
- package/dist/session/managers/TimeUtils.d.ts +175 -0
- package/dist/session/managers/TimeUtils.d.ts.map +1 -0
- package/dist/session/managers/TranscriptionManager.d.ts +195 -0
- package/dist/session/managers/TranscriptionManager.d.ts.map +1 -0
- package/dist/session/managers/TranslationManager.d.ts +189 -0
- package/dist/session/managers/TranslationManager.d.ts.map +1 -0
- package/dist/session.d.ts +41 -0
- package/dist/session.d.ts.map +1 -0
- package/dist/session.js +4168 -0
- package/dist/session.js.map +44 -0
- package/dist/transport/Transport.d.ts +119 -0
- package/dist/transport/Transport.d.ts.map +1 -0
- package/dist/transport/WebSocketTransport.d.ts +73 -0
- package/dist/transport/WebSocketTransport.d.ts.map +1 -0
- package/dist/types/index.d.ts +31 -5
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/message-types.d.ts +25 -9
- package/dist/types/message-types.d.ts.map +1 -1
- package/dist/types/messages/app-to-cloud.d.ts +113 -16
- package/dist/types/messages/app-to-cloud.d.ts.map +1 -1
- package/dist/types/messages/cloud-to-app.d.ts +50 -4
- package/dist/types/messages/cloud-to-app.d.ts.map +1 -1
- package/dist/types/messages/cloud-to-glasses.d.ts +43 -14
- package/dist/types/messages/cloud-to-glasses.d.ts.map +1 -1
- package/dist/types/messages/glasses-to-cloud.d.ts +5 -5
- package/dist/types/messages/glasses-to-cloud.d.ts.map +1 -1
- package/dist/types/models.d.ts +17 -0
- package/dist/types/models.d.ts.map +1 -1
- package/dist/types/rtmp-stream.d.ts +4 -4
- package/dist/types/rtmp-stream.d.ts.map +1 -1
- package/dist/types/streams.d.ts +6 -1
- package/dist/types/streams.d.ts.map +1 -1
- package/dist/types/webhooks.d.ts +11 -0
- package/dist/types/webhooks.d.ts.map +1 -1
- package/dist/utils/error-utils.d.ts +139 -0
- package/dist/utils/error-utils.d.ts.map +1 -0
- package/dist/utils/permissions-utils.d.ts +30 -7
- package/dist/utils/permissions-utils.d.ts.map +1 -1
- package/node_modules/@mentra/types/dist/applet.d.ts +5 -1
- package/node_modules/@mentra/types/dist/applet.d.ts.map +1 -1
- package/node_modules/@mentra/types/dist/capabilities/even-realities-g2.d.ts +12 -0
- package/node_modules/@mentra/types/dist/capabilities/even-realities-g2.d.ts.map +1 -0
- package/node_modules/@mentra/types/dist/capabilities/even-realities-g2.js +61 -0
- package/node_modules/@mentra/types/dist/capabilities/mentra-display.d.ts +12 -0
- package/node_modules/@mentra/types/dist/capabilities/mentra-display.d.ts.map +1 -0
- package/node_modules/@mentra/types/dist/capabilities/mentra-display.js +54 -0
- package/node_modules/@mentra/types/dist/capabilities/none.d.ts +13 -0
- package/node_modules/@mentra/types/dist/capabilities/none.d.ts.map +1 -0
- package/node_modules/@mentra/types/dist/capabilities/none.js +67 -0
- package/node_modules/@mentra/types/dist/enums.d.ts +8 -2
- package/node_modules/@mentra/types/dist/enums.d.ts.map +1 -1
- package/node_modules/@mentra/types/dist/enums.js +9 -2
- package/node_modules/@mentra/types/dist/hardware.d.ts +3 -1
- package/node_modules/@mentra/types/dist/hardware.d.ts.map +1 -1
- package/node_modules/@mentra/types/dist/hardware.js +12 -2
- package/node_modules/@mentra/types/dist/index.d.ts +1 -1
- package/node_modules/@mentra/types/dist/index.d.ts.map +1 -1
- package/node_modules/@mentra/types/dist/index.js +2 -1
- package/node_modules/@mentra/types/package.json +2 -2
- package/package.json +24 -12
- package/dist/examples/managed-rtmp-streaming-example.d.ts +0 -2
- package/dist/examples/managed-rtmp-streaming-example.d.ts.map +0 -1
- package/dist/examples/managed-rtmp-streaming-with-restream-example.d.ts +0 -11
- package/dist/examples/managed-rtmp-streaming-with-restream-example.d.ts.map +0 -1
- package/dist/examples/rtmp-streaming-example.d.ts +0 -2
- package/dist/examples/rtmp-streaming-example.d.ts.map +0 -1
- package/node_modules/@mentra/types/src/applet.ts +0 -51
- package/node_modules/@mentra/types/src/capabilities/even-realities-g1.ts +0 -63
- package/node_modules/@mentra/types/src/capabilities/mentra-live.ts +0 -103
- package/node_modules/@mentra/types/src/capabilities/simulated-glasses.ts +0 -76
- package/node_modules/@mentra/types/src/capabilities/vuzix-z100.ts +0 -60
- package/node_modules/@mentra/types/src/cli.ts +0 -169
- package/node_modules/@mentra/types/src/device.ts +0 -43
- package/node_modules/@mentra/types/src/enums.ts +0 -36
- package/node_modules/@mentra/types/src/hardware.ts +0 -172
- package/node_modules/@mentra/types/src/index.ts +0 -64
- package/node_modules/@mentra/types/tsconfig.json +0 -22
- package/node_modules/@mentra/types/tsconfig.tsbuildinfo +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mentra/types",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.2",
|
|
4
4
|
"description": "Shared TypeScript types for MentraOS client and cloud",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
"scripts": {
|
|
20
|
-
"build": "rm -rf dist && bun x tsc -p tsconfig.json",
|
|
20
|
+
"build": "rm -rf dist tsconfig.tsbuildinfo && bun x tsc -p tsconfig.json",
|
|
21
21
|
"dev": "bun x tsc --watch",
|
|
22
22
|
"typecheck": "bun x tsc --noEmit",
|
|
23
23
|
"prepare": "bun run build"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mentra/sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0-alpha.3",
|
|
4
4
|
"description": "Build apps for MentraOS smartglasses. This SDK provides everything you need to create real-time smartglasses applications.",
|
|
5
5
|
"source": "src/index.ts",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -18,6 +18,18 @@
|
|
|
18
18
|
"types": "./dist/index.d.ts"
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
|
+
"./session": {
|
|
22
|
+
"development": {
|
|
23
|
+
"import": "./src/session.ts",
|
|
24
|
+
"require": "./src/session.ts",
|
|
25
|
+
"types": "./src/session.ts"
|
|
26
|
+
},
|
|
27
|
+
"default": {
|
|
28
|
+
"import": "./dist/session.js",
|
|
29
|
+
"require": "./dist/session.js",
|
|
30
|
+
"types": "./dist/session.d.ts"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
21
33
|
"./display-utils": {
|
|
22
34
|
"development": {
|
|
23
35
|
"import": "./src/display-utils.ts",
|
|
@@ -32,11 +44,12 @@
|
|
|
32
44
|
}
|
|
33
45
|
},
|
|
34
46
|
"scripts": {
|
|
35
|
-
"build": "bun run
|
|
36
|
-
"build:js-only": "bun run
|
|
37
|
-
"build:full": "bun run
|
|
38
|
-
"clean": "
|
|
39
|
-
"
|
|
47
|
+
"build": "bun run build:js && bun run build:types",
|
|
48
|
+
"build:js-only": "bun run build:js",
|
|
49
|
+
"build:full": "bun run build:js && bun run build:types",
|
|
50
|
+
"build:clean": "bun run clean && bun run build",
|
|
51
|
+
"clean": "rm -rf dist .dist-tmp",
|
|
52
|
+
"build:js": "rm -rf .dist-tmp && bun build src/index.ts src/session.ts src/display-utils.ts --outdir .dist-tmp --target node --format esm --sourcemap=external --external @logtail/pino --external axios --external chalk --external dotenv --external hono --external jimp --external jsonwebtoken --external jsrsasign --external lamejs --external pino --external pino-pretty --external strip-ansi --external ws && rm -rf dist && mv .dist-tmp dist",
|
|
40
53
|
"build:types": "bun x tsc --build --force",
|
|
41
54
|
"dev": "echo 'No build needed in dev mode - using source files directly'",
|
|
42
55
|
"prepare": "bun run build",
|
|
@@ -46,26 +59,25 @@
|
|
|
46
59
|
"@logtail/pino": "^0.5.4",
|
|
47
60
|
"@mentra/types": "^1.0.0-beta.1",
|
|
48
61
|
"axios": "^1.8.1",
|
|
49
|
-
"boxen": "^8.0.1",
|
|
50
62
|
"chalk": "^5.6.2",
|
|
51
|
-
"cookie-parser": "^1.4.7",
|
|
52
63
|
"dotenv": "^16.4.0",
|
|
53
|
-
"
|
|
64
|
+
"hono": "^4.11.3",
|
|
54
65
|
"jimp": "^1.6.0",
|
|
55
66
|
"jsonwebtoken": "^8.5.1",
|
|
56
67
|
"jsrsasign": "^11.1.0",
|
|
57
|
-
"multer": "^2.0.1",
|
|
58
68
|
"pino": "^9.6.0",
|
|
59
|
-
"pino-pretty": "^13.0.0",
|
|
60
69
|
"strip-ansi": "^7.1.2",
|
|
70
|
+
"lamejs": "^1.2.1",
|
|
61
71
|
"ws": "^8.18.2"
|
|
62
72
|
},
|
|
73
|
+
"optionalDependencies": {
|
|
74
|
+
"pino-pretty": "^13.0.0"
|
|
75
|
+
},
|
|
63
76
|
"bundledDependencies": [
|
|
64
77
|
"@mentra/types"
|
|
65
78
|
],
|
|
66
79
|
"devDependencies": {
|
|
67
80
|
"@types/babel__core": "^7.20.5",
|
|
68
|
-
"@types/express": "^4.17.17",
|
|
69
81
|
"@types/jsonwebtoken": "^9.0.2",
|
|
70
82
|
"@types/jsrsasign": "^10.5.15",
|
|
71
83
|
"@types/node": "^20.0.0",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"managed-rtmp-streaming-example.d.ts","sourceRoot":"","sources":["../../src/examples/managed-rtmp-streaming-example.ts"],"names":[],"mappings":""}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Example: Managed RTMP Streaming with Re-streaming to Multiple Platforms
|
|
3
|
-
*
|
|
4
|
-
* This example demonstrates how to use the managed streaming feature with
|
|
5
|
-
* automatic re-streaming to platforms like YouTube, Twitch, and Facebook.
|
|
6
|
-
*
|
|
7
|
-
* The cloud handles all RTMP endpoints and automatically forwards your stream
|
|
8
|
-
* to the specified destinations.
|
|
9
|
-
*/
|
|
10
|
-
export {};
|
|
11
|
-
//# sourceMappingURL=managed-rtmp-streaming-with-restream-example.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"managed-rtmp-streaming-with-restream-example.d.ts","sourceRoot":"","sources":["../../src/examples/managed-rtmp-streaming-with-restream-example.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"rtmp-streaming-example.d.ts","sourceRoot":"","sources":["../../src/examples/rtmp-streaming-example.ts"],"names":[],"mappings":""}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @mentra/types - App/Applet types for client interfaces
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import {HardwareRequirement} from "./hardware"
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* App execution model types
|
|
9
|
-
*/
|
|
10
|
-
export type AppletType = "standard" | "background" | "system_dashboard";
|
|
11
|
-
|
|
12
|
-
/**
|
|
13
|
-
* Permission types that apps can request
|
|
14
|
-
*/
|
|
15
|
-
export type AppPermissionType =
|
|
16
|
-
| "ALL"
|
|
17
|
-
| "MICROPHONE"
|
|
18
|
-
| "CAMERA"
|
|
19
|
-
| "CALENDAR"
|
|
20
|
-
| "LOCATION"
|
|
21
|
-
| "BACKGROUND_LOCATION"
|
|
22
|
-
| "READ_NOTIFICATIONS"
|
|
23
|
-
| "POST_NOTIFICATIONS";
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Permission object with type and description
|
|
27
|
-
*/
|
|
28
|
-
export interface AppletPermission {
|
|
29
|
-
type: AppPermissionType;
|
|
30
|
-
description?: string;
|
|
31
|
-
required?: boolean;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
/**
|
|
35
|
-
* Minimal app interface for client home screen display
|
|
36
|
-
* Optimized for fast rendering - only essential fields (9 fields)
|
|
37
|
-
*
|
|
38
|
-
* This is the client-facing interface used by mobile apps.
|
|
39
|
-
* Internal cloud services use AppI from models (more fields).
|
|
40
|
-
*/
|
|
41
|
-
export interface AppletInterface {
|
|
42
|
-
packageName: string;
|
|
43
|
-
name: string;
|
|
44
|
-
webviewUrl: string;
|
|
45
|
-
logoUrl: string;
|
|
46
|
-
type: AppletType;
|
|
47
|
-
permissions: AppletPermission[];
|
|
48
|
-
running: boolean;
|
|
49
|
-
healthy: boolean;
|
|
50
|
-
hardwareRequirements: HardwareRequirement[];
|
|
51
|
-
}
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @fileoverview Even Realities G1 Hardware Capabilities
|
|
3
|
-
*
|
|
4
|
-
* Capability profile for the Even Realities G1 smart glasses model.
|
|
5
|
-
* Defines the hardware and software features available on this device.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
import type { Capabilities } from "../hardware";
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Even Realities G1 capability profile
|
|
12
|
-
*/
|
|
13
|
-
export const evenRealitiesG1: Capabilities = {
|
|
14
|
-
modelName: "Even Realities G1",
|
|
15
|
-
|
|
16
|
-
// Camera capabilities - G1 does not have a camera
|
|
17
|
-
hasCamera: false,
|
|
18
|
-
camera: null,
|
|
19
|
-
|
|
20
|
-
// Display capabilities - G1 has a green monochrome display
|
|
21
|
-
hasDisplay: true,
|
|
22
|
-
display: {
|
|
23
|
-
count: 2,
|
|
24
|
-
isColor: false,
|
|
25
|
-
color: "green",
|
|
26
|
-
canDisplayBitmap: true,
|
|
27
|
-
resolution: { width: 640, height: 200 },
|
|
28
|
-
fieldOfView: { horizontal: 25 },
|
|
29
|
-
maxTextLines: 5,
|
|
30
|
-
adjustBrightness: true,
|
|
31
|
-
},
|
|
32
|
-
|
|
33
|
-
// Microphone capabilities - G1 has one microphone without VAD
|
|
34
|
-
hasMicrophone: true,
|
|
35
|
-
microphone: {
|
|
36
|
-
count: 1,
|
|
37
|
-
hasVAD: false,
|
|
38
|
-
},
|
|
39
|
-
|
|
40
|
-
// Speaker capabilities - G1 does not have a speaker
|
|
41
|
-
hasSpeaker: false,
|
|
42
|
-
speaker: null,
|
|
43
|
-
|
|
44
|
-
// IMU capabilities - G1 has IMU for head-up/down detection but raw data not exposed to apps
|
|
45
|
-
hasIMU: true,
|
|
46
|
-
imu: null,
|
|
47
|
-
|
|
48
|
-
// Button capabilities - G1 does not have buttons
|
|
49
|
-
hasButton: false,
|
|
50
|
-
button: null,
|
|
51
|
-
|
|
52
|
-
// Light capabilities - G1 does not have lights
|
|
53
|
-
hasLight: false,
|
|
54
|
-
light: null,
|
|
55
|
-
|
|
56
|
-
// Power capabilities - G1 does not have external battery
|
|
57
|
-
power: {
|
|
58
|
-
hasExternalBattery: false,
|
|
59
|
-
},
|
|
60
|
-
|
|
61
|
-
// WiFi capabilities - G1 does not support WiFi
|
|
62
|
-
hasWifi: false,
|
|
63
|
-
};
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @fileoverview Mentra Live Hardware Capabilities
|
|
3
|
-
*
|
|
4
|
-
* Capability profile for the Mentra Live smart glasses model.
|
|
5
|
-
* Defines the hardware and software features available on this device.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
import type { Capabilities } from "../hardware";
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Mentra Live capability profile
|
|
12
|
-
*/
|
|
13
|
-
export const mentraLive: Capabilities = {
|
|
14
|
-
modelName: "Mentra Live",
|
|
15
|
-
|
|
16
|
-
// Camera capabilities - Mentra Live has camera with streaming
|
|
17
|
-
hasCamera: true,
|
|
18
|
-
camera: {
|
|
19
|
-
resolution: { width: 1920, height: 1080 },
|
|
20
|
-
hasHDR: false,
|
|
21
|
-
hasFocus: true,
|
|
22
|
-
video: {
|
|
23
|
-
canRecord: true,
|
|
24
|
-
canStream: true,
|
|
25
|
-
supportedStreamTypes: ["rtmp"],
|
|
26
|
-
supportedResolutions: [
|
|
27
|
-
{ width: 1920, height: 1080 },
|
|
28
|
-
{ width: 1280, height: 720 },
|
|
29
|
-
{ width: 640, height: 480 },
|
|
30
|
-
],
|
|
31
|
-
},
|
|
32
|
-
},
|
|
33
|
-
|
|
34
|
-
// Display capabilities - Mentra Live does not have a display
|
|
35
|
-
hasDisplay: false,
|
|
36
|
-
display: null,
|
|
37
|
-
|
|
38
|
-
// Microphone capabilities - Mentra Live has one microphone with VAD
|
|
39
|
-
hasMicrophone: true,
|
|
40
|
-
microphone: {
|
|
41
|
-
count: 1,
|
|
42
|
-
hasVAD: true,
|
|
43
|
-
},
|
|
44
|
-
|
|
45
|
-
// Speaker capabilities - Mentra Live has one standard speaker
|
|
46
|
-
hasSpeaker: true,
|
|
47
|
-
speaker: {
|
|
48
|
-
count: 1,
|
|
49
|
-
isPrivate: false,
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
// IMU capabilities - Mentra Live has 6-axis IMU
|
|
53
|
-
hasIMU: true,
|
|
54
|
-
imu: {
|
|
55
|
-
axisCount: 6,
|
|
56
|
-
hasAccelerometer: true,
|
|
57
|
-
hasCompass: false,
|
|
58
|
-
hasGyroscope: true,
|
|
59
|
-
},
|
|
60
|
-
|
|
61
|
-
// Button capabilities - Mentra Live has one physical button
|
|
62
|
-
hasButton: true,
|
|
63
|
-
button: {
|
|
64
|
-
count: 1,
|
|
65
|
-
buttons: [
|
|
66
|
-
{
|
|
67
|
-
type: "press",
|
|
68
|
-
events: ["press", "double_press", "long_press"],
|
|
69
|
-
isCapacitive: false,
|
|
70
|
-
},
|
|
71
|
-
],
|
|
72
|
-
},
|
|
73
|
-
|
|
74
|
-
// Light capabilities - Mentra Live has two lights: privacy light + RGB LED
|
|
75
|
-
hasLight: true,
|
|
76
|
-
light: {
|
|
77
|
-
count: 2,
|
|
78
|
-
lights: [
|
|
79
|
-
{
|
|
80
|
-
id: "privacy",
|
|
81
|
-
purpose: "privacy",
|
|
82
|
-
isFullColor: false,
|
|
83
|
-
color: "white",
|
|
84
|
-
position: "front_facing",
|
|
85
|
-
},
|
|
86
|
-
{
|
|
87
|
-
id: "user_feedback",
|
|
88
|
-
purpose: "user_feedback",
|
|
89
|
-
isFullColor: true,
|
|
90
|
-
color: "rgb",
|
|
91
|
-
position: "user_facing",
|
|
92
|
-
},
|
|
93
|
-
],
|
|
94
|
-
},
|
|
95
|
-
|
|
96
|
-
// Power capabilities - Mentra Live does not have external battery
|
|
97
|
-
power: {
|
|
98
|
-
hasExternalBattery: false,
|
|
99
|
-
},
|
|
100
|
-
|
|
101
|
-
// WiFi capabilities - Mentra Live supports WiFi
|
|
102
|
-
hasWifi: true,
|
|
103
|
-
};
|
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @fileoverview Simulated Glasses Hardware Capabilities
|
|
3
|
-
*
|
|
4
|
-
* Capability profile for the Simulated Glasses model.
|
|
5
|
-
* Defines the hardware and software features available on this device.
|
|
6
|
-
* This profile matches the Vuzix Z100 capabilities for testing purposes.
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
import type { Capabilities } from "../hardware";
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Simulated Glasses capability profile
|
|
13
|
-
*/
|
|
14
|
-
export const simulatedGlasses: Capabilities = {
|
|
15
|
-
modelName: "Simulated Glasses",
|
|
16
|
-
|
|
17
|
-
// Camera capabilities - does not have a camera
|
|
18
|
-
hasCamera: false,
|
|
19
|
-
camera: null,
|
|
20
|
-
|
|
21
|
-
// Display capabilities - has a green monochrome display
|
|
22
|
-
hasDisplay: true,
|
|
23
|
-
display: {
|
|
24
|
-
count: 1,
|
|
25
|
-
isColor: false,
|
|
26
|
-
color: "green",
|
|
27
|
-
canDisplayBitmap: false,
|
|
28
|
-
resolution: { width: 640, height: 480 },
|
|
29
|
-
fieldOfView: { horizontal: 30 },
|
|
30
|
-
maxTextLines: 7,
|
|
31
|
-
adjustBrightness: true,
|
|
32
|
-
},
|
|
33
|
-
|
|
34
|
-
// Microphone capabilities - has a microphone (phone mic)
|
|
35
|
-
hasMicrophone: true,
|
|
36
|
-
microphone: {
|
|
37
|
-
count: 1,
|
|
38
|
-
hasVAD: false,
|
|
39
|
-
},
|
|
40
|
-
|
|
41
|
-
// Speaker capabilities - has a speaker (phone speaker)
|
|
42
|
-
hasSpeaker: true,
|
|
43
|
-
speaker: {
|
|
44
|
-
count: 1,
|
|
45
|
-
isPrivate: false,
|
|
46
|
-
},
|
|
47
|
-
|
|
48
|
-
// IMU capabilities - does not have an IMU
|
|
49
|
-
hasIMU: false,
|
|
50
|
-
imu: null,
|
|
51
|
-
|
|
52
|
-
// Button capabilities - Has one simulated button
|
|
53
|
-
hasButton: true,
|
|
54
|
-
button: {
|
|
55
|
-
count: 1,
|
|
56
|
-
buttons: [
|
|
57
|
-
{
|
|
58
|
-
type: "press",
|
|
59
|
-
events: ["press"],
|
|
60
|
-
isCapacitive: false,
|
|
61
|
-
},
|
|
62
|
-
],
|
|
63
|
-
},
|
|
64
|
-
|
|
65
|
-
// Light capabilities - does not have lights
|
|
66
|
-
hasLight: false,
|
|
67
|
-
light: null,
|
|
68
|
-
|
|
69
|
-
// Power capabilities - does not have external battery
|
|
70
|
-
power: {
|
|
71
|
-
hasExternalBattery: false,
|
|
72
|
-
},
|
|
73
|
-
|
|
74
|
-
// WiFi capabilities - does not support WiFi
|
|
75
|
-
hasWifi: false,
|
|
76
|
-
};
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @fileoverview Vuzix Z100 Hardware Capabilities
|
|
3
|
-
*
|
|
4
|
-
* Capability profile for the Vuzix Z100 smart glasses model.
|
|
5
|
-
* Defines the hardware and software features available on this device.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
import type { Capabilities } from "../hardware";
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* Vuzix Z100 capability profile
|
|
12
|
-
*/
|
|
13
|
-
export const vuzixZ100: Capabilities = {
|
|
14
|
-
modelName: "Vuzix Z100",
|
|
15
|
-
|
|
16
|
-
// Camera capabilities - does not have a camera
|
|
17
|
-
hasCamera: false,
|
|
18
|
-
camera: null,
|
|
19
|
-
|
|
20
|
-
// Display capabilities - has a green monochrome display
|
|
21
|
-
hasDisplay: true,
|
|
22
|
-
display: {
|
|
23
|
-
count: 1,
|
|
24
|
-
isColor: false,
|
|
25
|
-
color: "green",
|
|
26
|
-
canDisplayBitmap: false,
|
|
27
|
-
resolution: { width: 640, height: 480 },
|
|
28
|
-
fieldOfView: { horizontal: 30 },
|
|
29
|
-
maxTextLines: 7,
|
|
30
|
-
adjustBrightness: true,
|
|
31
|
-
},
|
|
32
|
-
|
|
33
|
-
// Microphone capabilities - does not have a microphone
|
|
34
|
-
hasMicrophone: false,
|
|
35
|
-
microphone: null,
|
|
36
|
-
|
|
37
|
-
// Speaker capabilities - does not have a speaker
|
|
38
|
-
hasSpeaker: false,
|
|
39
|
-
speaker: null,
|
|
40
|
-
|
|
41
|
-
// IMU capabilities - does not have an IMU
|
|
42
|
-
hasIMU: false,
|
|
43
|
-
imu: null,
|
|
44
|
-
|
|
45
|
-
// Button capabilities - does not have buttons
|
|
46
|
-
hasButton: false,
|
|
47
|
-
button: null,
|
|
48
|
-
|
|
49
|
-
// Light capabilities - does not have lights
|
|
50
|
-
hasLight: false,
|
|
51
|
-
light: null,
|
|
52
|
-
|
|
53
|
-
// Power capabilities - does not have external battery
|
|
54
|
-
power: {
|
|
55
|
-
hasExternalBattery: false,
|
|
56
|
-
},
|
|
57
|
-
|
|
58
|
-
// WiFi capabilities - does not support WiFi
|
|
59
|
-
hasWifi: false,
|
|
60
|
-
};
|
|
@@ -1,169 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI API Key Management Types
|
|
3
|
-
*
|
|
4
|
-
* Shared between cloud backend and CLI tool.
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* CLI API Key stored in database
|
|
9
|
-
*/
|
|
10
|
-
export interface CLIApiKey {
|
|
11
|
-
/** Unique key identifier (UUID v4) */
|
|
12
|
-
keyId: string
|
|
13
|
-
|
|
14
|
-
/** User ID who owns this key (ObjectId as string) */
|
|
15
|
-
userId: string
|
|
16
|
-
|
|
17
|
-
/** User email (denormalized for backward compatibility) */
|
|
18
|
-
email: string
|
|
19
|
-
|
|
20
|
-
/** User-friendly name for the key */
|
|
21
|
-
name: string
|
|
22
|
-
|
|
23
|
-
/** SHA-256 hash of the JWT token (for revocation checks) */
|
|
24
|
-
hashedToken: string
|
|
25
|
-
|
|
26
|
-
/** When the key was created */
|
|
27
|
-
createdAt: Date
|
|
28
|
-
|
|
29
|
-
/** When the key was last updated */
|
|
30
|
-
updatedAt: Date
|
|
31
|
-
|
|
32
|
-
/** Last time this key was used (optional tracking) */
|
|
33
|
-
lastUsedAt?: Date
|
|
34
|
-
|
|
35
|
-
/** Optional expiration date */
|
|
36
|
-
expiresAt?: Date
|
|
37
|
-
|
|
38
|
-
/** Whether key is active (false = revoked) */
|
|
39
|
-
isActive: boolean
|
|
40
|
-
|
|
41
|
-
/** Optional metadata */
|
|
42
|
-
metadata?: {
|
|
43
|
-
createdFrom?: string
|
|
44
|
-
userAgent?: string
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
/**
|
|
49
|
-
* Request to generate a new CLI API key
|
|
50
|
-
*/
|
|
51
|
-
export interface GenerateCLIKeyRequest {
|
|
52
|
-
/** User-friendly name for the key */
|
|
53
|
-
name: string
|
|
54
|
-
|
|
55
|
-
/** Optional expiration in days (default: never) */
|
|
56
|
-
expiresInDays?: number
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
/**
|
|
60
|
-
* Response when generating a CLI API key
|
|
61
|
-
* Token is shown ONCE and never retrievable
|
|
62
|
-
*/
|
|
63
|
-
export interface GenerateCLIKeyResponse {
|
|
64
|
-
/** The CLI API key ID */
|
|
65
|
-
keyId: string
|
|
66
|
-
|
|
67
|
-
/** User-friendly name */
|
|
68
|
-
name: string
|
|
69
|
-
|
|
70
|
-
/** JWT token (ONLY shown once!) */
|
|
71
|
-
token: string
|
|
72
|
-
|
|
73
|
-
/** When it was created */
|
|
74
|
-
createdAt: string
|
|
75
|
-
|
|
76
|
-
/** Optional expiration date */
|
|
77
|
-
expiresAt?: string
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
/**
|
|
81
|
-
* CLI API Key list item (token not included)
|
|
82
|
-
*/
|
|
83
|
-
export interface CLIApiKeyListItem {
|
|
84
|
-
/** Key identifier */
|
|
85
|
-
keyId: string
|
|
86
|
-
|
|
87
|
-
/** User-friendly name */
|
|
88
|
-
name: string
|
|
89
|
-
|
|
90
|
-
/** Creation timestamp */
|
|
91
|
-
createdAt: string
|
|
92
|
-
|
|
93
|
-
/** Last usage timestamp (if tracked) */
|
|
94
|
-
lastUsedAt?: string
|
|
95
|
-
|
|
96
|
-
/** Expiration timestamp */
|
|
97
|
-
expiresAt?: string
|
|
98
|
-
|
|
99
|
-
/** Whether key is active */
|
|
100
|
-
isActive: boolean
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
/**
|
|
104
|
-
* Request to update a CLI API key
|
|
105
|
-
*/
|
|
106
|
-
export interface UpdateCLIKeyRequest {
|
|
107
|
-
/** New name for the key */
|
|
108
|
-
name: string
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
/**
|
|
112
|
-
* JWT payload for CLI API keys
|
|
113
|
-
*/
|
|
114
|
-
export interface CLITokenPayload {
|
|
115
|
-
/** User email */
|
|
116
|
-
email: string
|
|
117
|
-
|
|
118
|
-
/** Token type discriminator */
|
|
119
|
-
type: "cli"
|
|
120
|
-
|
|
121
|
-
/** Key ID for revocation lookups */
|
|
122
|
-
keyId: string
|
|
123
|
-
|
|
124
|
-
/** User-friendly key name */
|
|
125
|
-
name: string
|
|
126
|
-
|
|
127
|
-
/** Issued at (Unix timestamp) */
|
|
128
|
-
iat: number
|
|
129
|
-
|
|
130
|
-
/** Optional expiration (Unix timestamp) */
|
|
131
|
-
exp?: number
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
/**
|
|
135
|
-
* CLI credentials stored locally on user's machine
|
|
136
|
-
*/
|
|
137
|
-
export interface CLICredentials {
|
|
138
|
-
/** JWT token */
|
|
139
|
-
token: string
|
|
140
|
-
|
|
141
|
-
/** User email (extracted from token) */
|
|
142
|
-
email: string
|
|
143
|
-
|
|
144
|
-
/** Key name (extracted from token) */
|
|
145
|
-
keyName: string
|
|
146
|
-
|
|
147
|
-
/** Key ID (extracted from token) */
|
|
148
|
-
keyId: string
|
|
149
|
-
|
|
150
|
-
/** When credentials were stored */
|
|
151
|
-
storedAt: string
|
|
152
|
-
|
|
153
|
-
/** Optional expiration timestamp */
|
|
154
|
-
expiresAt?: string
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
/**
|
|
158
|
-
* Cloud environment configuration
|
|
159
|
-
*/
|
|
160
|
-
export interface Cloud {
|
|
161
|
-
/** Display name */
|
|
162
|
-
name: string
|
|
163
|
-
|
|
164
|
-
/** API URL */
|
|
165
|
-
url: string
|
|
166
|
-
|
|
167
|
-
/** Whether this is a built-in cloud */
|
|
168
|
-
builtin?: boolean
|
|
169
|
-
}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Device connection state and metadata types
|
|
3
|
-
* Used for POST /api/client/device/state
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
export interface GlassesInfo {
|
|
7
|
-
// Connection state
|
|
8
|
-
connected: boolean
|
|
9
|
-
|
|
10
|
-
// Device identification
|
|
11
|
-
modelName: string | null
|
|
12
|
-
androidVersion?: string
|
|
13
|
-
fwVersion?: string
|
|
14
|
-
buildNumber?: string
|
|
15
|
-
otaVersionUrl?: string
|
|
16
|
-
appVersion?: string
|
|
17
|
-
bluetoothName?: string
|
|
18
|
-
serialNumber?: string
|
|
19
|
-
style?: string
|
|
20
|
-
color?: string
|
|
21
|
-
|
|
22
|
-
// WiFi info (only for WiFi-capable devices)
|
|
23
|
-
wifiConnected?: boolean
|
|
24
|
-
wifiSsid?: string
|
|
25
|
-
wifiLocalIp?: string
|
|
26
|
-
|
|
27
|
-
// Battery info
|
|
28
|
-
batteryLevel?: number
|
|
29
|
-
charging?: boolean
|
|
30
|
-
caseBatteryLevel?: number
|
|
31
|
-
caseCharging?: boolean
|
|
32
|
-
caseOpen?: boolean
|
|
33
|
-
caseRemoved?: boolean
|
|
34
|
-
|
|
35
|
-
// Hotspot info
|
|
36
|
-
hotspotEnabled?: boolean
|
|
37
|
-
hotspotSsid?: string
|
|
38
|
-
hotspotPassword?: string
|
|
39
|
-
hotspotGatewayIp?: string
|
|
40
|
-
|
|
41
|
-
// Metadata
|
|
42
|
-
timestamp?: string
|
|
43
|
-
}
|