@stamn/stamn-plugin 0.1.0-alpha.0 → 0.1.0-alpha.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stamn/stamn-plugin",
3
- "version": "0.1.0-alpha.0",
3
+ "version": "0.1.0-alpha.2",
4
4
  "description": "Stamn plugin for OpenClaw",
5
5
  "type": "module",
6
6
  "openclaw": {
@@ -33,7 +33,7 @@
33
33
  "format": [
34
34
  "esm"
35
35
  ],
36
- "dts": true,
36
+ "dts": false,
37
37
  "clean": true,
38
38
  "sourcemap": true,
39
39
  "noExternal": [
package/dist/index.d.ts DELETED
@@ -1,63 +0,0 @@
1
- import { StamnConfig, ConfigAdapter } from '@stamn/cli';
2
-
3
- interface PluginLogger {
4
- info(msg: string, ...args: unknown[]): void;
5
- warn(msg: string, ...args: unknown[]): void;
6
- error(msg: string, ...args: unknown[]): void;
7
- debug(msg: string, ...args: unknown[]): void;
8
- }
9
- interface ToolParameterProperty {
10
- type: string;
11
- description?: string;
12
- enum?: string[];
13
- }
14
- interface ToolParameters {
15
- type: 'object';
16
- properties: Record<string, ToolParameterProperty>;
17
- required?: string[];
18
- }
19
- interface ToolResultContent {
20
- type: 'text';
21
- text: string;
22
- }
23
- interface ToolResult {
24
- content: ToolResultContent[];
25
- }
26
- interface PluginApi {
27
- logger: PluginLogger;
28
- config: Record<string, unknown>;
29
- registerService(service: {
30
- id: string;
31
- start: () => void | Promise<void>;
32
- stop: () => void | Promise<void>;
33
- }): void;
34
- registerCli(fn: (ctx: {
35
- program: unknown;
36
- }) => void, opts: {
37
- commands: string[];
38
- }): void;
39
- registerCommand(cmd: {
40
- name: string;
41
- description: string;
42
- acceptsArgs?: boolean;
43
- handler: (ctx: {
44
- args?: string;
45
- }) => {
46
- text: string;
47
- } | Promise<{
48
- text: string;
49
- }>;
50
- }): void;
51
- registerTool(tool: {
52
- name: string;
53
- description: string;
54
- parameters: ToolParameters;
55
- execute: (args: Record<string, unknown>) => ToolResult | Promise<ToolResult>;
56
- }): void;
57
- }
58
-
59
- declare function registerCli(api: PluginApi, config: StamnConfig): void;
60
-
61
- declare function createOpenclawAdapter(): ConfigAdapter;
62
-
63
- export { type PluginApi, type PluginLogger, type ToolParameterProperty, type ToolParameters, type ToolResult, type ToolResultContent, createOpenclawAdapter, registerCli };