mindwire 0.1.52 → 0.1.54
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-4XL565EU.js → chunk-P3JTWITC.js} +190 -7
- package/dist/chunk-P3JTWITC.js.map +1 -0
- package/dist/{chunk-RTMQJIKW.js → chunk-ZNEFE6KD.js} +4 -10
- package/dist/chunk-ZNEFE6KD.js.map +1 -0
- package/dist/cli.js +21 -25
- package/dist/cli.js.map +1 -1
- package/dist/client.d.ts +12 -0
- package/dist/{connection-change-6E7QLJFC.js → connection-change-RVS6XWTC.js} +3 -3
- package/dist/{connection-change-6E7QLJFC.js.map → connection-change-RVS6XWTC.js.map} +1 -1
- package/dist/{controller-566LDBZD.js → controller-2WCEJ3F2.js} +4 -4
- package/dist/{controller-566LDBZD.js.map → controller-2WCEJ3F2.js.map} +1 -1
- package/dist/{controller-handoff-KNEQ5W6J.js → controller-handoff-7EOSPHSD.js} +3 -3
- package/dist/{controller-handoff-KNEQ5W6J.js.map → controller-handoff-7EOSPHSD.js.map} +1 -1
- package/dist/handoffs.d.ts +91 -0
- package/dist/index.cjs +209 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/index.js +200 -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 +21 -1
- package/dist/workspace.d.ts +14 -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[];
|
|
@@ -721,6 +734,8 @@ export interface ToolPart {
|
|
|
721
734
|
input?: unknown;
|
|
722
735
|
output?: string;
|
|
723
736
|
isError?: boolean;
|
|
737
|
+
/** Explicit native outcome; missing or in-progress is unknown. */
|
|
738
|
+
status?: string;
|
|
724
739
|
/** Deep-normalized view of the tool call; rides alongside the raw name/input/output. */
|
|
725
740
|
action?: ToolAction;
|
|
726
741
|
}
|
|
@@ -1106,6 +1121,9 @@ export interface Health {
|
|
|
1106
1121
|
localDesktopVersion?: number;
|
|
1107
1122
|
/** Workspace registry protocol version; absent on daemons predating workspace metadata. */
|
|
1108
1123
|
workspaceMetadataVersion?: number;
|
|
1124
|
+
botsVersion?: number;
|
|
1125
|
+
appsVersion?: number;
|
|
1126
|
+
integrationsVersion?: number;
|
|
1109
1127
|
/** Native installed-harness discovery and atomic workspace.ensureAgent(). */
|
|
1110
1128
|
agentDiscoveryVersion?: number;
|
|
1111
1129
|
/** Durable project folders, membership and ordering, with conditional edits. */
|
|
@@ -1140,6 +1158,8 @@ export interface Health {
|
|
|
1140
1158
|
/** Live attachment to a native CLI owner without a competing harness process. */
|
|
1141
1159
|
nativeSessionVersion?: number;
|
|
1142
1160
|
chatForkVersion?: number;
|
|
1161
|
+
/** 2 adds portable context, review digests and explicit omissions. */
|
|
1162
|
+
crossAgentHandoffVersion?: number;
|
|
1143
1163
|
/** Image-only input and image attachments retained in message history. */
|
|
1144
1164
|
imageAttachmentsVersion?: number;
|
|
1145
1165
|
attachmentUploadVersion?: number;
|
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,8 @@ 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
|
+
handoffFrom?: import("./handoffs.js").HandoffOrigin;
|
|
191
|
+
botId?: string;
|
|
188
192
|
/** Logical conversation identity; the local id remains unique per workspace. */
|
|
189
193
|
syncId?: string;
|
|
190
194
|
agentId: string;
|
|
@@ -205,6 +209,7 @@ export type WorkspaceInput<T extends WorkspaceRecord> = Omit<T, "id" | "workspac
|
|
|
205
209
|
};
|
|
206
210
|
/** Additive migration. Existing records and deletion tombstones always win over these values. */
|
|
207
211
|
export interface WorkspaceImport {
|
|
212
|
+
bots?: Bot[];
|
|
208
213
|
agents?: (WorkspaceInput<WorkspaceAgent> & {
|
|
209
214
|
id: string;
|
|
210
215
|
})[];
|
|
@@ -242,6 +247,8 @@ export interface ProjectLibraryEdit {
|
|
|
242
247
|
importIfEmpty?: boolean;
|
|
243
248
|
}
|
|
244
249
|
export interface WorkspaceSnapshot {
|
|
250
|
+
apps?: AppShortcut[];
|
|
251
|
+
bots?: Bot[];
|
|
245
252
|
version: number;
|
|
246
253
|
workspaceId: string;
|
|
247
254
|
revision: number;
|
|
@@ -308,6 +315,13 @@ export declare class WorkspaceApi {
|
|
|
308
315
|
editLibrary(edit: ProjectLibraryEdit): Promise<ProjectLibrary>;
|
|
309
316
|
/** Read the saved icon, or preview a candidate relative path within the project. Requires projectIconsVersion >= 1. */
|
|
310
317
|
projectIcon(projectId: string, path?: string): Promise<ProjectIcon>;
|
|
318
|
+
/** Upload a validated image (base64 content, at most 1 MB). Requires projectIconsVersion >= 2.
|
|
319
|
+
* Stores the image inside the project; set projects.put(..., { iconPath: result.path }) to select it.
|
|
320
|
+
*/
|
|
321
|
+
uploadProjectIcon(projectId: string, image: {
|
|
322
|
+
name: string;
|
|
323
|
+
content: string;
|
|
324
|
+
}): Promise<ProjectIcon>;
|
|
311
325
|
/** Start an operation owned by the daemon. The same ID/payload returns the existing operation. */
|
|
312
326
|
createProject(request: ProjectRequest): Promise<ProjectOperation>;
|
|
313
327
|
/** 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.54",
|
|
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"
|