@eworkbase/sdk 0.3.2 → 0.3.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/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as
|
|
1
|
+
import { $ as PluginAgentPolicy, A as PluginLifecycleOutcome, At as RoleToolEnvironment, B as PluginSetupHooks, C as PluginExecutionStatus, Ct as PluginTaskResult, D as PluginInvocationContext, Dt as PluginToastOptions, E as PluginHookResult, Et as PluginToastLevel, F as PluginProcessResult, Ft as roleToolsProposalSchema, G as PluginToolContribution, H as PluginSharedChanges, I as PluginProcessRunOptions, J as PluginViewLayout, K as PluginViewContribution, L as PluginProject, M as PluginLifecycleStatus, Mt as RoleToolsProposal, N as PluginLogger, Nt as roleToolEnvironmentSchema, O as PluginLifecycleDispatchResult, Ot as PluginViewCatalogEntry, P as PluginProcessApi, Pt as roleToolsAppliedSchema, Q as PluginAgentContextCatalogEntry, R as PluginRepository, S as PluginExecutionSnapshot, St as PluginTaskDescriptor, T as PluginHookId, Tt as PluginToastApi, U as PluginStatusContribution, V as PluginSharedChangeKind, W as PluginStatusDefinition, X as PluginWorkspace, Y as PluginViewRequest, Z as WorkbasePluginDefinition, _ as PluginContext, _t as PluginPromptType, a as PluginCapabilityReference, at as PluginCommandCatalogEntry, b as PluginDisposable, bt as PluginStoreApi, c as PluginCommandContext, ct as PluginHostServices, d as PluginCommandDetails, dt as PluginLogQueryRequest, et as PluginCapabilityCatalog, f as PluginCommandEffect, ft as PluginLogQueryResult, g as PluginCommandTransaction, gt as PluginPromptQuestion, h as PluginCommandOption, ht as PluginPromptChoice, i as PluginCapabilityKind, it as PluginColoredMessage, j as PluginLifecyclePolicy, jt as RoleToolsApplied, k as PluginLifecycleHook, kt as PluginToolsService, l as PluginCommandContribution, lt as PluginInteractiveLogger, m as PluginCommandExecutionResult, mt as PluginPromptApi, n as PluginAgentContextDefinition, nt as PluginCapabilityResolveRequest, o as PluginCommandArgument, ot as PluginConfigApi, p as PluginCommandExecutionMode, pt as PluginLogService, q as PluginViewDefinition, r as PluginAgentScope, rt as PluginCapabilityService, s as PluginCommandCategory, st as PluginExecutionService, t as PluginAgentContextContribution, tt as PluginCapabilityCommandRequest, u as PluginCommandDefinition, ut as PluginLogEntry, v as PluginContextExposure, vt as PluginPromptViewRequest, w as PluginFileChange, wt as PluginTaskService, x as PluginExecutionEvidence, xt as PluginSystemContextService, y as PluginContributionSnapshot, yt as PluginStatusCatalogEntry, z as PluginRepositoryStatus } from "./types-Cmfedh3f.js";
|
|
2
2
|
export * from "zod";
|
|
3
3
|
//#region src/definition.d.ts
|
|
4
4
|
export declare const PLUGIN_API_VERSION = 2;
|
|
@@ -6,4 +6,4 @@ type DefinedWorkbasePlugin = Readonly<WorkbasePluginDefinition>;
|
|
|
6
6
|
export declare function definePlugin(definition: WorkbasePluginDefinition): DefinedWorkbasePlugin;
|
|
7
7
|
export declare function isDefinedPlugin(value: unknown): value is DefinedWorkbasePlugin;
|
|
8
8
|
//#endregion
|
|
9
|
-
export { type DefinedWorkbasePlugin, type PluginAgentContextCatalogEntry, type PluginAgentContextContribution, type PluginAgentContextDefinition, type PluginAgentPolicy, type PluginCapabilityCatalog, type PluginCapabilityCommandRequest, type PluginCapabilityResolveRequest, type PluginCapabilityService, type PluginColoredMessage, type PluginCommandArgument, type PluginCommandCatalogEntry, PluginCommandCategory, type PluginCommandContext, type PluginCommandContribution, type PluginCommandDefinition, type PluginCommandDetails, PluginCommandEffect, PluginCommandExecutionMode, type PluginCommandExecutionResult, type PluginCommandOption, PluginCommandTransaction, type PluginConfigApi, type PluginContext, PluginContextExposure, type PluginContributionSnapshot, type PluginDisposable, type PluginExecutionService, type PluginExecutionSnapshot, PluginExecutionStatus, type PluginFileChange, PluginHookId, type PluginHookResult, type PluginHostServices, type PluginInteractiveLogger, type PluginInvocationContext, type PluginLifecycleDispatchResult, type PluginLifecycleHook, type PluginLifecycleOutcome, PluginLifecyclePolicy, PluginLifecycleStatus, type PluginLogEntry, type PluginLogQueryRequest, type PluginLogQueryResult, type PluginLogService, type PluginLogger, type PluginProcessApi, type PluginProcessResult, type PluginProcessRunOptions, type PluginProject, type PluginPromptApi, type PluginPromptChoice, type PluginPromptQuestion, type PluginPromptType, type PluginPromptViewRequest, type PluginRepository, PluginRepositoryStatus, type PluginSetupHooks, PluginSharedChangeKind, type PluginSharedChanges, type PluginStatusCatalogEntry, type PluginStatusContribution, type PluginStatusDefinition, type PluginStoreApi, type PluginSystemContextService, type PluginTaskDescriptor, type PluginTaskResult, type PluginTaskService, type PluginToastApi, type PluginToastLevel, type PluginToastOptions, type PluginToolContribution, PluginToolsService, type PluginViewCatalogEntry, type PluginViewContribution, type PluginViewDefinition, PluginViewLayout, type PluginViewRequest, type PluginWorkspace, RoleToolEnvironment, RoleToolsApplied, RoleToolsProposal, type WorkbasePluginDefinition, roleToolEnvironmentSchema, roleToolsAppliedSchema, roleToolsProposalSchema };
|
|
9
|
+
export { type DefinedWorkbasePlugin, type PluginAgentContextCatalogEntry, type PluginAgentContextContribution, type PluginAgentContextDefinition, type PluginAgentPolicy, PluginAgentScope, type PluginCapabilityCatalog, type PluginCapabilityCommandRequest, PluginCapabilityKind, type PluginCapabilityReference, type PluginCapabilityResolveRequest, type PluginCapabilityService, type PluginColoredMessage, type PluginCommandArgument, type PluginCommandCatalogEntry, PluginCommandCategory, type PluginCommandContext, type PluginCommandContribution, type PluginCommandDefinition, type PluginCommandDetails, PluginCommandEffect, PluginCommandExecutionMode, type PluginCommandExecutionResult, type PluginCommandOption, PluginCommandTransaction, type PluginConfigApi, type PluginContext, PluginContextExposure, type PluginContributionSnapshot, type PluginDisposable, type PluginExecutionEvidence, type PluginExecutionService, type PluginExecutionSnapshot, PluginExecutionStatus, type PluginFileChange, PluginHookId, type PluginHookResult, type PluginHostServices, type PluginInteractiveLogger, type PluginInvocationContext, type PluginLifecycleDispatchResult, type PluginLifecycleHook, type PluginLifecycleOutcome, PluginLifecyclePolicy, PluginLifecycleStatus, type PluginLogEntry, type PluginLogQueryRequest, type PluginLogQueryResult, type PluginLogService, type PluginLogger, type PluginProcessApi, type PluginProcessResult, type PluginProcessRunOptions, type PluginProject, type PluginPromptApi, type PluginPromptChoice, type PluginPromptQuestion, type PluginPromptType, type PluginPromptViewRequest, type PluginRepository, PluginRepositoryStatus, type PluginSetupHooks, PluginSharedChangeKind, type PluginSharedChanges, type PluginStatusCatalogEntry, type PluginStatusContribution, type PluginStatusDefinition, type PluginStoreApi, type PluginSystemContextService, type PluginTaskDescriptor, type PluginTaskResult, type PluginTaskService, type PluginToastApi, type PluginToastLevel, type PluginToastOptions, type PluginToolContribution, PluginToolsService, type PluginViewCatalogEntry, type PluginViewContribution, type PluginViewDefinition, PluginViewLayout, type PluginViewRequest, type PluginWorkspace, RoleToolEnvironment, RoleToolsApplied, RoleToolsProposal, type WorkbasePluginDefinition, roleToolEnvironmentSchema, roleToolsAppliedSchema, roleToolsProposalSchema };
|
package/dist/index.js
CHANGED
|
@@ -53,6 +53,17 @@ let PluginExecutionStatus = /* @__PURE__ */ function(PluginExecutionStatus) {
|
|
|
53
53
|
PluginExecutionStatus["Interrupted"] = "interrupted";
|
|
54
54
|
return PluginExecutionStatus;
|
|
55
55
|
}({});
|
|
56
|
+
let PluginCapabilityKind = /* @__PURE__ */ function(PluginCapabilityKind) {
|
|
57
|
+
PluginCapabilityKind["Command"] = "command";
|
|
58
|
+
PluginCapabilityKind["Status"] = "status";
|
|
59
|
+
PluginCapabilityKind["Context"] = "context";
|
|
60
|
+
return PluginCapabilityKind;
|
|
61
|
+
}({});
|
|
62
|
+
let PluginAgentScope = /* @__PURE__ */ function(PluginAgentScope) {
|
|
63
|
+
PluginAgentScope["Workspace"] = "workspace";
|
|
64
|
+
PluginAgentScope["Execution"] = "execution";
|
|
65
|
+
return PluginAgentScope;
|
|
66
|
+
}({});
|
|
56
67
|
let PluginCommandEffect = /* @__PURE__ */ function(PluginCommandEffect) {
|
|
57
68
|
PluginCommandEffect["Immediate"] = "immediate";
|
|
58
69
|
PluginCommandEffect["LongRunning"] = "longRunning";
|
|
@@ -189,4 +200,4 @@ const roleToolsAppliedSchema = z.object({
|
|
|
189
200
|
requiresPreparation: z.boolean()
|
|
190
201
|
});
|
|
191
202
|
//#endregion
|
|
192
|
-
export { PLUGIN_API_VERSION, PluginCommandCategory, PluginCommandEffect, PluginCommandExecutionMode, PluginCommandTransaction, PluginContextExposure, PluginExecutionStatus, PluginHookId, PluginLifecyclePolicy, PluginLifecycleStatus, PluginRepositoryStatus, PluginSharedChangeKind, PluginViewLayout, definePlugin, isDefinedPlugin, roleToolEnvironmentSchema, roleToolsAppliedSchema, roleToolsProposalSchema };
|
|
203
|
+
export { PLUGIN_API_VERSION, PluginAgentScope, PluginCapabilityKind, PluginCommandCategory, PluginCommandEffect, PluginCommandExecutionMode, PluginCommandTransaction, PluginContextExposure, PluginExecutionStatus, PluginHookId, PluginLifecyclePolicy, PluginLifecycleStatus, PluginRepositoryStatus, PluginSharedChangeKind, PluginViewLayout, definePlugin, isDefinedPlugin, roleToolEnvironmentSchema, roleToolsAppliedSchema, roleToolsProposalSchema };
|
|
@@ -188,6 +188,7 @@ interface PluginCommandCatalogEntry {
|
|
|
188
188
|
readonly transaction: PluginCommandTransaction;
|
|
189
189
|
}
|
|
190
190
|
interface PluginAgentPolicy {
|
|
191
|
+
readonly scope?: PluginAgentScope;
|
|
191
192
|
readonly callable: boolean;
|
|
192
193
|
readonly destructive?: boolean;
|
|
193
194
|
readonly idempotent?: boolean;
|
|
@@ -292,10 +293,16 @@ interface PluginExecutionService {
|
|
|
292
293
|
readonly grant: (options: {
|
|
293
294
|
readonly readOnly: boolean;
|
|
294
295
|
readonly tasks: readonly string[];
|
|
296
|
+
readonly capabilities: readonly PluginCapabilityReference[];
|
|
295
297
|
}) => Promise<string>;
|
|
298
|
+
/** Verified parent, available only inside a host-delegated command. */
|
|
299
|
+
readonly identity: () => Promise<{
|
|
300
|
+
readonly executionId: string;
|
|
301
|
+
readonly pluginId: string;
|
|
302
|
+
} | null>;
|
|
296
303
|
readonly revoke: (token: string) => Promise<void>;
|
|
297
304
|
readonly delegate: (token: string, request: {
|
|
298
|
-
readonly method: "tasks.list" | "tasks.run" | "commands.execute" | "commands.start" | "commands.query";
|
|
305
|
+
readonly method: "capabilities.list" | "statuses.resolve" | "contexts.resolve" | "tasks.list" | "tasks.run" | "commands.execute" | "commands.start" | "commands.query";
|
|
299
306
|
readonly input: unknown;
|
|
300
307
|
}) => Promise<unknown>;
|
|
301
308
|
}
|
|
@@ -334,7 +341,35 @@ declare enum PluginExecutionStatus {
|
|
|
334
341
|
Cancelled = "cancelled",
|
|
335
342
|
Interrupted = "interrupted"
|
|
336
343
|
}
|
|
344
|
+
declare enum PluginCapabilityKind {
|
|
345
|
+
Command = "command",
|
|
346
|
+
Status = "status",
|
|
347
|
+
Context = "context"
|
|
348
|
+
}
|
|
349
|
+
declare enum PluginAgentScope {
|
|
350
|
+
Workspace = "workspace",
|
|
351
|
+
Execution = "execution"
|
|
352
|
+
}
|
|
353
|
+
interface PluginCapabilityReference {
|
|
354
|
+
readonly pluginId: string;
|
|
355
|
+
readonly kind: PluginCapabilityKind;
|
|
356
|
+
readonly id: string;
|
|
357
|
+
}
|
|
358
|
+
/** Host-owned receipts; plugin progress and Agent output cannot replace these. */
|
|
359
|
+
interface PluginExecutionEvidence {
|
|
360
|
+
readonly callId: string;
|
|
361
|
+
readonly kind: PluginCapabilityKind | "task";
|
|
362
|
+
readonly pluginId: string;
|
|
363
|
+
readonly id: string;
|
|
364
|
+
readonly status: "running" | "succeeded" | "failed";
|
|
365
|
+
readonly time: string;
|
|
366
|
+
readonly childExecutionId?: string | null;
|
|
367
|
+
readonly logId?: string | null;
|
|
368
|
+
readonly error?: string | null;
|
|
369
|
+
}
|
|
337
370
|
interface PluginExecutionSnapshot {
|
|
371
|
+
readonly evidence?: readonly PluginExecutionEvidence[];
|
|
372
|
+
readonly evidenceIncomplete?: boolean;
|
|
338
373
|
readonly afterExecutionId?: string | null;
|
|
339
374
|
readonly revision: number;
|
|
340
375
|
readonly tasks: readonly {
|
|
@@ -478,6 +513,7 @@ interface PluginCommandDetails {
|
|
|
478
513
|
readonly warnings?: readonly string[];
|
|
479
514
|
}
|
|
480
515
|
interface PluginCommandExecutionResult<Value = unknown> {
|
|
516
|
+
readonly success?: boolean | null;
|
|
481
517
|
readonly value: Value;
|
|
482
518
|
readonly executionId: string;
|
|
483
519
|
readonly parentExecutionId: string | null;
|
|
@@ -649,4 +685,4 @@ interface PluginContributionSnapshot {
|
|
|
649
685
|
readonly views: readonly PluginViewContribution[];
|
|
650
686
|
}
|
|
651
687
|
//#endregion
|
|
652
|
-
export {
|
|
688
|
+
export { PluginAgentPolicy as $, PluginLifecycleOutcome as A, RoleToolEnvironment as At, PluginSetupHooks as B, PluginExecutionStatus as C, PluginTaskResult as Ct, PluginInvocationContext as D, PluginToastOptions as Dt, PluginHookResult as E, PluginToastLevel as Et, PluginProcessResult as F, roleToolsProposalSchema as Ft, PluginToolContribution as G, PluginSharedChanges as H, PluginProcessRunOptions as I, PluginViewLayout as J, PluginViewContribution as K, PluginProject as L, PluginLifecycleStatus as M, RoleToolsProposal as Mt, PluginLogger as N, roleToolEnvironmentSchema as Nt, PluginLifecycleDispatchResult as O, PluginViewCatalogEntry as Ot, PluginProcessApi as P, roleToolsAppliedSchema as Pt, PluginAgentContextCatalogEntry as Q, PluginRepository as R, PluginExecutionSnapshot as S, PluginTaskDescriptor as St, PluginHookId as T, PluginToastApi as Tt, PluginStatusContribution as U, PluginSharedChangeKind as V, PluginStatusDefinition as W, PluginWorkspace as X, PluginViewRequest as Y, WorkbasePluginDefinition as Z, PluginContext as _, PluginPromptType as _t, PluginCapabilityReference as a, PluginCommandCatalogEntry as at, PluginDisposable as b, PluginStoreApi as bt, PluginCommandContext as c, PluginHostServices as ct, PluginCommandDetails as d, PluginLogQueryRequest as dt, PluginCapabilityCatalog as et, PluginCommandEffect as f, PluginLogQueryResult as ft, PluginCommandTransaction as g, PluginPromptQuestion as gt, PluginCommandOption as h, PluginPromptChoice as ht, PluginCapabilityKind as i, PluginColoredMessage as it, PluginLifecyclePolicy as j, RoleToolsApplied as jt, PluginLifecycleHook as k, PluginToolsService as kt, PluginCommandContribution as l, PluginInteractiveLogger as lt, PluginCommandExecutionResult as m, PluginPromptApi as mt, PluginAgentContextDefinition as n, PluginCapabilityResolveRequest as nt, PluginCommandArgument as o, PluginConfigApi as ot, PluginCommandExecutionMode as p, PluginLogService as pt, PluginViewDefinition as q, PluginAgentScope as r, PluginCapabilityService as rt, PluginCommandCategory as s, PluginExecutionService as st, PluginAgentContextContribution as t, PluginCapabilityCommandRequest as tt, PluginCommandDefinition as u, PluginLogEntry as ut, PluginContextExposure as v, PluginPromptViewRequest as vt, PluginFileChange as w, PluginTaskService as wt, PluginExecutionEvidence as x, PluginSystemContextService as xt, PluginContributionSnapshot as y, PluginStatusCatalogEntry as yt, PluginRepositoryStatus as z };
|
package/dist/ui/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { S as PluginExecutionSnapshot, m as PluginCommandExecutionResult } from "../types-Cmfedh3f.js";
|
|
2
2
|
//#region src/ui/types.d.ts
|
|
3
3
|
/**
|
|
4
4
|
* Browser authoring API and transport contracts for Workbase plugin views.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eworkbase/sdk",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -25,6 +25,11 @@
|
|
|
25
25
|
},
|
|
26
26
|
"./ui/theme.css": "./dist/ui/theme.css"
|
|
27
27
|
},
|
|
28
|
+
"scripts": {
|
|
29
|
+
"build": "tsdown",
|
|
30
|
+
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
31
|
+
"pack:local": "pnpm build && pnpm pack"
|
|
32
|
+
},
|
|
28
33
|
"engines": {
|
|
29
34
|
"node": ">=22"
|
|
30
35
|
},
|
|
@@ -42,10 +47,5 @@
|
|
|
42
47
|
"@types/node": "^24.0.3",
|
|
43
48
|
"tsdown": "0.23.0",
|
|
44
49
|
"typescript": "^5.8.3"
|
|
45
|
-
},
|
|
46
|
-
"scripts": {
|
|
47
|
-
"build": "tsdown",
|
|
48
|
-
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
49
|
-
"pack:local": "pnpm build && pnpm pack"
|
|
50
50
|
}
|
|
51
|
-
}
|
|
51
|
+
}
|