mindwire 0.1.52 → 0.1.53
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 +97 -2
- package/dist/apps.d.ts +94 -0
- package/dist/bots.d.ts +168 -0
- package/dist/{chunk-RTMQJIKW.js → chunk-MZ4OTZFH.js} +4 -10
- package/dist/chunk-MZ4OTZFH.js.map +1 -0
- package/dist/{chunk-4XL565EU.js → chunk-O5DWL7MH.js} +176 -7
- package/dist/chunk-O5DWL7MH.js.map +1 -0
- package/dist/cli.js +21 -25
- package/dist/cli.js.map +1 -1
- package/dist/client.d.ts +6 -0
- package/dist/{connection-change-6E7QLJFC.js → connection-change-EGOCFEPP.js} +3 -3
- package/dist/{connection-change-6E7QLJFC.js.map → connection-change-EGOCFEPP.js.map} +1 -1
- package/dist/{controller-566LDBZD.js → controller-WUR6XGOM.js} +4 -4
- package/dist/{controller-566LDBZD.js.map → controller-WUR6XGOM.js.map} +1 -1
- package/dist/{controller-handoff-KNEQ5W6J.js → controller-handoff-SJ3A4NEC.js} +3 -3
- package/dist/{controller-handoff-KNEQ5W6J.js.map → controller-handoff-SJ3A4NEC.js.map} +1 -1
- package/dist/index.cjs +195 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.js +186 -10
- package/dist/index.js.map +1 -1
- package/dist/integrations.d.ts +72 -0
- package/dist/target/docker.d.ts +9 -1
- package/dist/types.d.ts +17 -1
- package/dist/workspace.d.ts +13 -0
- package/package.json +10 -11
- package/dist/chunk-4XL565EU.js.map +0 -1
- package/dist/chunk-RTMQJIKW.js.map +0 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import type { Mindwire } from "./client.js";
|
|
2
|
+
import type { Condition } from "./types.js";
|
|
3
|
+
export type IntegrationProvider = "slack" | "teams" | "discord" | "telegram";
|
|
4
|
+
export type IntegrationMode = "notifications" | "commands" | "chat" | "trigger";
|
|
5
|
+
/** Write-only credentials, stored on the daemon. Omitted fields preserve saved values. */
|
|
6
|
+
export interface IntegrationCredentials {
|
|
7
|
+
botToken?: string;
|
|
8
|
+
signingSecret?: string;
|
|
9
|
+
webhookSecret?: string;
|
|
10
|
+
publicKey?: string;
|
|
11
|
+
clientSecret?: string;
|
|
12
|
+
}
|
|
13
|
+
export interface IntegrationSpec {
|
|
14
|
+
name: string;
|
|
15
|
+
provider: IntegrationProvider;
|
|
16
|
+
botId: string;
|
|
17
|
+
mode: IntegrationMode;
|
|
18
|
+
enabled: boolean;
|
|
19
|
+
/** Explicit allowlist. Empty lists are rejected. */
|
|
20
|
+
channelIds: string[];
|
|
21
|
+
userIds?: string[];
|
|
22
|
+
/** Slack team, Discord guild, or Microsoft Entra tenant ID. */
|
|
23
|
+
workspaceId?: string;
|
|
24
|
+
applicationId?: string;
|
|
25
|
+
command?: string;
|
|
26
|
+
/** Forward this bot's lifecycle notifications to destination. */
|
|
27
|
+
notify: boolean;
|
|
28
|
+
conditions?: Condition[];
|
|
29
|
+
destination?: string;
|
|
30
|
+
/** Owner-configured Microsoft Teams connector URL. */
|
|
31
|
+
serviceUrl?: string;
|
|
32
|
+
expectedRevision?: number;
|
|
33
|
+
credentials?: IntegrationCredentials;
|
|
34
|
+
}
|
|
35
|
+
export interface Integration extends Omit<IntegrationSpec, "credentials" | "expectedRevision"> {
|
|
36
|
+
id: string;
|
|
37
|
+
revision: number;
|
|
38
|
+
hasCredentials: boolean;
|
|
39
|
+
webhookPath: string;
|
|
40
|
+
}
|
|
41
|
+
export interface IntegrationReceipt {
|
|
42
|
+
id: string;
|
|
43
|
+
integrationId: string;
|
|
44
|
+
channelId: string;
|
|
45
|
+
userId: string;
|
|
46
|
+
state: "queued" | "running" | "delivered" | "failed";
|
|
47
|
+
chatId?: string;
|
|
48
|
+
runId?: string;
|
|
49
|
+
error?: string;
|
|
50
|
+
createdAt: string;
|
|
51
|
+
}
|
|
52
|
+
/** Persistent messaging connections shared with the app and daemon. */
|
|
53
|
+
export declare class IntegrationsApi {
|
|
54
|
+
private readonly mw;
|
|
55
|
+
constructor(mw: Mindwire);
|
|
56
|
+
list(): Promise<Integration[]>;
|
|
57
|
+
get(id: string): Promise<Integration>;
|
|
58
|
+
create(spec: IntegrationSpec): Promise<Integration>;
|
|
59
|
+
/** Complete replacement with optimistic concurrency; omit credentials to preserve them. */
|
|
60
|
+
update(id: string, spec: IntegrationSpec & {
|
|
61
|
+
expectedRevision: number;
|
|
62
|
+
}): Promise<Integration>;
|
|
63
|
+
delete(id: string): Promise<void>;
|
|
64
|
+
/** Sends to the configured destination, also useful as a connection test. */
|
|
65
|
+
send(id: string, text: string): Promise<{
|
|
66
|
+
sent: boolean;
|
|
67
|
+
}>;
|
|
68
|
+
/** Latest 100 redacted delivery receipts. */
|
|
69
|
+
events(id: string): Promise<IntegrationReceipt[]>;
|
|
70
|
+
retry(id: string, eventId: string): Promise<IntegrationReceipt>;
|
|
71
|
+
private path;
|
|
72
|
+
}
|
package/dist/target/docker.d.ts
CHANGED
|
@@ -36,7 +36,7 @@ export interface DockerConfig {
|
|
|
36
36
|
docker?: DockerodeLike;
|
|
37
37
|
/** How to reach the Docker engine (remote host / socket / TLS). Ignored when `docker` is passed. */
|
|
38
38
|
engine?: DockerEngineOptions;
|
|
39
|
-
/** Create + own a container from this image. Defaults to the
|
|
39
|
+
/** Create + own a container from this image. Defaults to Node 24 on Debian; the matching released daemon is installed separately. */
|
|
40
40
|
image?: string;
|
|
41
41
|
/** Image acquisition policy for a container MindWire creates. Defaults to pulling only when absent. */
|
|
42
42
|
pull?: "missing" | "always" | "never";
|
|
@@ -104,6 +104,14 @@ interface ContainerLike {
|
|
|
104
104
|
};
|
|
105
105
|
}
|
|
106
106
|
export interface DockerodeLike {
|
|
107
|
+
modem: {
|
|
108
|
+
followProgress(stream: DuplexLike, done: (error: Error | null, output?: Array<{
|
|
109
|
+
error?: string;
|
|
110
|
+
errorDetail?: {
|
|
111
|
+
message?: string;
|
|
112
|
+
};
|
|
113
|
+
}>) => void): void;
|
|
114
|
+
};
|
|
107
115
|
getContainer(id: string): ContainerLike;
|
|
108
116
|
getImage(name: string): {
|
|
109
117
|
inspect(): Promise<unknown>;
|
package/dist/types.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Wire types for the mindwire daemon, mirrored 1:1 from the Go structs in
|
|
3
|
-
* `daemon/internal/agent` and `daemon/internal/session`. The daemon normalizes every
|
|
3
|
+
* `packages/daemon/internal/agent` and `packages/daemon/internal/session`. The daemon normalizes every
|
|
4
4
|
* agent's native output into these shapes, so the client renders one protocol regardless
|
|
5
5
|
* of which harness (Claude Code, Codex, Copilot CLI, opencode, …) actually ran.
|
|
6
6
|
*
|
|
@@ -320,6 +320,8 @@ export interface CommandInvocation {
|
|
|
320
320
|
}
|
|
321
321
|
/** Per-agent feature matrix. The core switches on some fields; the client reads the rest as UI hints. */
|
|
322
322
|
export interface Capabilities {
|
|
323
|
+
/** Saved bot instructions and native management tools remain available on resumed turns. */
|
|
324
|
+
botProfiles?: boolean;
|
|
323
325
|
/** Static harness hint; check nativeSessions.activity() for this session's controls. */
|
|
324
326
|
nativeSession?: import("./native-sessions.js").NativeSessionCapabilities;
|
|
325
327
|
protocol: Protocol;
|
|
@@ -463,6 +465,8 @@ export interface CatalogEntry {
|
|
|
463
465
|
id: string;
|
|
464
466
|
name: string;
|
|
465
467
|
tagline: string;
|
|
468
|
+
/** Supports persistent Mindwire bot profiles, including subsequent turns. */
|
|
469
|
+
botProfiles?: boolean;
|
|
466
470
|
}
|
|
467
471
|
/**
|
|
468
472
|
* Which persistent layer a memory file or prompt template lives at. `project` = a working directory
|
|
@@ -693,6 +697,15 @@ export interface Notification {
|
|
|
693
697
|
title: string;
|
|
694
698
|
body: string;
|
|
695
699
|
agent?: string;
|
|
700
|
+
/** Saved bot identity; agent remains the underlying engine for routing rules. */
|
|
701
|
+
botId?: string;
|
|
702
|
+
botName?: string;
|
|
703
|
+
botIcon?: string;
|
|
704
|
+
appId?: string;
|
|
705
|
+
appName?: string;
|
|
706
|
+
appIcon?: string;
|
|
707
|
+
eventId?: string;
|
|
708
|
+
workspaceId?: string;
|
|
696
709
|
chatId?: string;
|
|
697
710
|
runId?: string;
|
|
698
711
|
actions?: Action[];
|
|
@@ -1106,6 +1119,9 @@ export interface Health {
|
|
|
1106
1119
|
localDesktopVersion?: number;
|
|
1107
1120
|
/** Workspace registry protocol version; absent on daemons predating workspace metadata. */
|
|
1108
1121
|
workspaceMetadataVersion?: number;
|
|
1122
|
+
botsVersion?: number;
|
|
1123
|
+
appsVersion?: number;
|
|
1124
|
+
integrationsVersion?: number;
|
|
1109
1125
|
/** Native installed-harness discovery and atomic workspace.ensureAgent(). */
|
|
1110
1126
|
agentDiscoveryVersion?: number;
|
|
1111
1127
|
/** Durable project folders, membership and ordering, with conditional edits. */
|
package/dist/workspace.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import type { Mindwire } from "./client.js";
|
|
2
|
+
import type { Bot } from "./bots.js";
|
|
3
|
+
import type { AppShortcut } from "./apps.js";
|
|
2
4
|
import { ProjectSyncApi } from "./project-sync.js";
|
|
3
5
|
import { ConversationsApi } from "./conversations.js";
|
|
4
6
|
/** Write-only credentials. Never persisted in operation snapshots or conversation state. */
|
|
@@ -185,6 +187,7 @@ export interface ProjectIcon {
|
|
|
185
187
|
}
|
|
186
188
|
/** Chat membership; transcript content continues to come from /chats/:id/messages. */
|
|
187
189
|
export interface WorkspaceChat extends WorkspaceRecord {
|
|
190
|
+
botId?: string;
|
|
188
191
|
/** Logical conversation identity; the local id remains unique per workspace. */
|
|
189
192
|
syncId?: string;
|
|
190
193
|
agentId: string;
|
|
@@ -205,6 +208,7 @@ export type WorkspaceInput<T extends WorkspaceRecord> = Omit<T, "id" | "workspac
|
|
|
205
208
|
};
|
|
206
209
|
/** Additive migration. Existing records and deletion tombstones always win over these values. */
|
|
207
210
|
export interface WorkspaceImport {
|
|
211
|
+
bots?: Bot[];
|
|
208
212
|
agents?: (WorkspaceInput<WorkspaceAgent> & {
|
|
209
213
|
id: string;
|
|
210
214
|
})[];
|
|
@@ -242,6 +246,8 @@ export interface ProjectLibraryEdit {
|
|
|
242
246
|
importIfEmpty?: boolean;
|
|
243
247
|
}
|
|
244
248
|
export interface WorkspaceSnapshot {
|
|
249
|
+
apps?: AppShortcut[];
|
|
250
|
+
bots?: Bot[];
|
|
245
251
|
version: number;
|
|
246
252
|
workspaceId: string;
|
|
247
253
|
revision: number;
|
|
@@ -308,6 +314,13 @@ export declare class WorkspaceApi {
|
|
|
308
314
|
editLibrary(edit: ProjectLibraryEdit): Promise<ProjectLibrary>;
|
|
309
315
|
/** Read the saved icon, or preview a candidate relative path within the project. Requires projectIconsVersion >= 1. */
|
|
310
316
|
projectIcon(projectId: string, path?: string): Promise<ProjectIcon>;
|
|
317
|
+
/** Upload a validated image (base64 content, at most 1 MB). Requires projectIconsVersion >= 2.
|
|
318
|
+
* Stores the image inside the project; set projects.put(..., { iconPath: result.path }) to select it.
|
|
319
|
+
*/
|
|
320
|
+
uploadProjectIcon(projectId: string, image: {
|
|
321
|
+
name: string;
|
|
322
|
+
content: string;
|
|
323
|
+
}): Promise<ProjectIcon>;
|
|
311
324
|
/** Start an operation owned by the daemon. The same ID/payload returns the existing operation. */
|
|
312
325
|
createProject(request: ProjectRequest): Promise<ProjectOperation>;
|
|
313
326
|
/** Permanently remove the confirmed project's directory and membership.
|
package/package.json
CHANGED
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mindwire",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.53",
|
|
4
4
|
"main": "./dist/index.cjs",
|
|
5
5
|
"module": "./dist/index.js",
|
|
6
6
|
"bin": {
|
|
7
7
|
"mindwire": "./dist/cli.js"
|
|
8
8
|
},
|
|
9
9
|
"devDependencies": {
|
|
10
|
-
"@types/node": "26.
|
|
11
|
-
"@types/qrcode": "^1.5.
|
|
12
|
-
"@types/ws": "^8.18.
|
|
13
|
-
"tsup": "
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"typescript": "5.9.3"
|
|
10
|
+
"@types/node": "26.6.5",
|
|
11
|
+
"@types/qrcode": "^1.5.6",
|
|
12
|
+
"@types/ws": "^8.18.2",
|
|
13
|
+
"tsup": "9.0.0",
|
|
14
|
+
"typescript": "7.0.2",
|
|
15
|
+
"dockerode": "^5.0.1"
|
|
17
16
|
},
|
|
18
17
|
"peerDependencies": {
|
|
19
18
|
"dockerode": ">=4.0.0",
|
|
@@ -34,7 +33,7 @@
|
|
|
34
33
|
"require": "./dist/index.cjs"
|
|
35
34
|
}
|
|
36
35
|
},
|
|
37
|
-
"description": "
|
|
36
|
+
"description": "Build personal assistants and coding tools on native agent harnesses with one Mindwire runtime API.",
|
|
38
37
|
"engines": {
|
|
39
38
|
"node": ">=18"
|
|
40
39
|
},
|
|
@@ -74,9 +73,9 @@
|
|
|
74
73
|
"type": "module",
|
|
75
74
|
"types": "./dist/index.d.ts",
|
|
76
75
|
"dependencies": {
|
|
77
|
-
"oblien": "^2.
|
|
76
|
+
"oblien": "^2.10.0",
|
|
78
77
|
"qrcode": "^1.5.4",
|
|
79
|
-
"ws": "^8.
|
|
78
|
+
"ws": "^8.22.0"
|
|
80
79
|
},
|
|
81
80
|
"optionalDependencies": {
|
|
82
81
|
"@ngrok/ngrok": "^1.7.0"
|