toolcraft 0.0.1
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 +91 -0
- package/dist/cli.compile-check.d.ts +1 -0
- package/dist/cli.compile-check.js +26 -0
- package/dist/cli.d.ts +12 -0
- package/dist/cli.js +1312 -0
- package/dist/index.compile-check.d.ts +1 -0
- package/dist/index.compile-check.js +50 -0
- package/dist/index.d.ts +164 -0
- package/dist/index.js +366 -0
- package/dist/mcp.compile-check.d.ts +1 -0
- package/dist/mcp.compile-check.js +26 -0
- package/dist/mcp.d.ts +31 -0
- package/dist/mcp.js +354 -0
- package/dist/number-schema.d.ts +3 -0
- package/dist/number-schema.js +8 -0
- package/dist/renderer.d.ts +5 -0
- package/dist/renderer.js +148 -0
- package/dist/schema-scope.d.ts +4 -0
- package/dist/schema-scope.js +34 -0
- package/dist/sdk.compile-check.d.ts +1 -0
- package/dist/sdk.compile-check.js +79 -0
- package/dist/sdk.d.ts +63 -0
- package/dist/sdk.js +218 -0
- package/node_modules/@poe-code/design-system/dist/acp/components.d.ts +11 -0
- package/node_modules/@poe-code/design-system/dist/acp/components.js +121 -0
- package/node_modules/@poe-code/design-system/dist/acp/index.d.ts +3 -0
- package/node_modules/@poe-code/design-system/dist/acp/index.js +2 -0
- package/node_modules/@poe-code/design-system/dist/acp/writer.d.ts +13 -0
- package/node_modules/@poe-code/design-system/dist/acp/writer.js +21 -0
- package/node_modules/@poe-code/design-system/dist/components/command-errors.d.ts +16 -0
- package/node_modules/@poe-code/design-system/dist/components/command-errors.js +22 -0
- package/node_modules/@poe-code/design-system/dist/components/help-formatter.d.ts +20 -0
- package/node_modules/@poe-code/design-system/dist/components/help-formatter.js +27 -0
- package/node_modules/@poe-code/design-system/dist/components/index.d.ts +10 -0
- package/node_modules/@poe-code/design-system/dist/components/index.js +7 -0
- package/node_modules/@poe-code/design-system/dist/components/logger.d.ts +11 -0
- package/node_modules/@poe-code/design-system/dist/components/logger.js +60 -0
- package/node_modules/@poe-code/design-system/dist/components/symbols.d.ts +12 -0
- package/node_modules/@poe-code/design-system/dist/components/symbols.js +71 -0
- package/node_modules/@poe-code/design-system/dist/components/table.d.ts +13 -0
- package/node_modules/@poe-code/design-system/dist/components/table.js +74 -0
- package/node_modules/@poe-code/design-system/dist/components/text.d.ts +14 -0
- package/node_modules/@poe-code/design-system/dist/components/text.js +104 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/ansi.d.ts +18 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/ansi.js +298 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/buffer.d.ts +25 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/buffer.js +189 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/border.d.ts +9 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/border.js +123 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/footer.d.ts +8 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/footer.js +57 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/output-pane.d.ts +12 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/output-pane.js +254 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/stats-pane.d.ts +7 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/components/stats-pane.js +121 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/dashboard.d.ts +20 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/dashboard.js +167 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/demo.d.ts +13 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/demo.js +145 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/index.d.ts +8 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/index.js +4 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/keymap.d.ts +3 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/keymap.js +99 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/layout.d.ts +25 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/layout.js +79 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/should-use-dashboard.d.ts +10 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/should-use-dashboard.js +7 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/snapshot.d.ts +10 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/snapshot.js +68 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/store.d.ts +8 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/store.js +51 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/terminal.d.ts +37 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/terminal.js +233 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/types.d.ts +36 -0
- package/node_modules/@poe-code/design-system/dist/dashboard/types.js +1 -0
- package/node_modules/@poe-code/design-system/dist/index.d.ts +33 -0
- package/node_modules/@poe-code/design-system/dist/index.js +31 -0
- package/node_modules/@poe-code/design-system/dist/internal/output-format.d.ts +6 -0
- package/node_modules/@poe-code/design-system/dist/internal/output-format.js +22 -0
- package/node_modules/@poe-code/design-system/dist/internal/strip-ansi.d.ts +1 -0
- package/node_modules/@poe-code/design-system/dist/internal/strip-ansi.js +3 -0
- package/node_modules/@poe-code/design-system/dist/internal/theme-detect.d.ts +11 -0
- package/node_modules/@poe-code/design-system/dist/internal/theme-detect.js +49 -0
- package/node_modules/@poe-code/design-system/dist/prompts/index.d.ts +66 -0
- package/node_modules/@poe-code/design-system/dist/prompts/index.js +132 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/cancel.d.ts +2 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/cancel.js +9 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/intro.d.ts +1 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/intro.js +15 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/log.d.ts +18 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/log.js +101 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/note.d.ts +1 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/note.js +39 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/outro.d.ts +1 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/outro.js +16 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/spinner.d.ts +6 -0
- package/node_modules/@poe-code/design-system/dist/prompts/primitives/spinner.js +74 -0
- package/node_modules/@poe-code/design-system/dist/prompts/theme.d.ts +11 -0
- package/node_modules/@poe-code/design-system/dist/prompts/theme.js +12 -0
- package/node_modules/@poe-code/design-system/dist/static/index.d.ts +4 -0
- package/node_modules/@poe-code/design-system/dist/static/index.js +2 -0
- package/node_modules/@poe-code/design-system/dist/static/menu.d.ts +11 -0
- package/node_modules/@poe-code/design-system/dist/static/menu.js +36 -0
- package/node_modules/@poe-code/design-system/dist/static/spinner.d.ts +14 -0
- package/node_modules/@poe-code/design-system/dist/static/spinner.js +46 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/ast.d.ts +92 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/ast.js +1 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/demo-content.d.ts +2 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/demo-content.js +139 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/index.d.ts +6 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/index.js +8 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser/block.d.ts +7 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser/block.js +1495 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser/frontmatter.d.ts +8 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser/frontmatter.js +412 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser/inline.d.ts +10 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser/inline.js +1166 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser.d.ts +5 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/parser.js +42 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/renderer.d.ts +6 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/renderer.js +572 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/testing/theme-render-fixture.d.ts +1 -0
- package/node_modules/@poe-code/design-system/dist/terminal-markdown/testing/theme-render-fixture.js +27 -0
- package/node_modules/@poe-code/design-system/dist/tokens/colors.d.ts +35 -0
- package/node_modules/@poe-code/design-system/dist/tokens/colors.js +34 -0
- package/node_modules/@poe-code/design-system/dist/tokens/index.d.ts +4 -0
- package/node_modules/@poe-code/design-system/dist/tokens/index.js +4 -0
- package/node_modules/@poe-code/design-system/dist/tokens/spacing.d.ts +6 -0
- package/node_modules/@poe-code/design-system/dist/tokens/spacing.js +6 -0
- package/node_modules/@poe-code/design-system/dist/tokens/typography.d.ts +7 -0
- package/node_modules/@poe-code/design-system/dist/tokens/typography.js +8 -0
- package/node_modules/@poe-code/design-system/dist/tokens/widths.d.ts +5 -0
- package/node_modules/@poe-code/design-system/dist/tokens/widths.js +5 -0
- package/node_modules/@poe-code/design-system/package.json +25 -0
- package/package.json +57 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { S } from "agent-kit-schema";
|
|
2
|
+
import { defineCommand, defineGroup } from "./index.js";
|
|
3
|
+
const ignoredScope = ["cli", "sdk"];
|
|
4
|
+
const ignoredSecrets = {
|
|
5
|
+
apiKey: { env: "API_KEY" },
|
|
6
|
+
sessionToken: { env: "SESSION_TOKEN", optional: true },
|
|
7
|
+
};
|
|
8
|
+
const ignoredCommand = defineCommand({
|
|
9
|
+
name: "deploy",
|
|
10
|
+
params: S.Object({
|
|
11
|
+
name: S.String(),
|
|
12
|
+
force: S.Optional(S.Boolean()),
|
|
13
|
+
}),
|
|
14
|
+
secrets: ignoredSecrets,
|
|
15
|
+
requires: {
|
|
16
|
+
auth: true,
|
|
17
|
+
},
|
|
18
|
+
render: {
|
|
19
|
+
json: (result) => result,
|
|
20
|
+
},
|
|
21
|
+
handler: async ({ params, secrets, fetch, fs, env, progress }) => {
|
|
22
|
+
progress(params.name);
|
|
23
|
+
await fs.exists("/tmp");
|
|
24
|
+
env.get("HOME");
|
|
25
|
+
void fetch;
|
|
26
|
+
return {
|
|
27
|
+
authenticated: Boolean(secrets.apiKey),
|
|
28
|
+
force: params.force ?? false,
|
|
29
|
+
};
|
|
30
|
+
},
|
|
31
|
+
});
|
|
32
|
+
const ignoredGroup = defineGroup({
|
|
33
|
+
name: "root",
|
|
34
|
+
scope: ignoredScope,
|
|
35
|
+
secrets: {
|
|
36
|
+
rootToken: { env: "ROOT_TOKEN" },
|
|
37
|
+
},
|
|
38
|
+
children: [ignoredCommand],
|
|
39
|
+
default: ignoredCommand,
|
|
40
|
+
});
|
|
41
|
+
const ignoredStringSchema = S.String();
|
|
42
|
+
const ignoredNumberSchema = S.Number();
|
|
43
|
+
const ignoredBooleanSchema = S.Boolean();
|
|
44
|
+
const ignoredEnumSchema = S.Enum(["cli", "sdk"]);
|
|
45
|
+
const ignoredArraySchema = S.Array(S.String());
|
|
46
|
+
const ignoredObjectSchema = S.Object({
|
|
47
|
+
name: S.String(),
|
|
48
|
+
enabled: S.Optional(S.Boolean()),
|
|
49
|
+
});
|
|
50
|
+
const ignoredOptionalSchema = S.Optional(S.Number());
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
import type { ObjectSchema, Static } from "agent-kit-schema";
|
|
2
|
+
import type { LoggerOutput, RenderTableOptions, ThemePalette } from "@poe-code/design-system";
|
|
3
|
+
type ScopeValue = "cli" | "mcp" | "sdk";
|
|
4
|
+
type AnyObjectSchema = ObjectSchema<Record<string, never>>;
|
|
5
|
+
type EmptyServices = Record<string, never>;
|
|
6
|
+
type ScopeInput = readonly Scope[] | undefined;
|
|
7
|
+
export type Scope = ScopeValue;
|
|
8
|
+
export interface SecretDefinition {
|
|
9
|
+
env: string;
|
|
10
|
+
description?: string;
|
|
11
|
+
optional?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export type SecretDeclarations = Record<string, SecretDefinition>;
|
|
14
|
+
type OptionalSecretKeys<TSecrets extends SecretDeclarations> = {
|
|
15
|
+
[TKey in keyof TSecrets]: TSecrets[TKey] extends {
|
|
16
|
+
optional: true;
|
|
17
|
+
} ? TKey : never;
|
|
18
|
+
}[keyof TSecrets];
|
|
19
|
+
type RequiredSecretKeys<TSecrets extends SecretDeclarations> = Exclude<keyof TSecrets, OptionalSecretKeys<TSecrets>>;
|
|
20
|
+
export type InferSecrets<TSecrets extends SecretDeclarations | undefined> = TSecrets extends SecretDeclarations ? {
|
|
21
|
+
[TKey in RequiredSecretKeys<TSecrets>]: string;
|
|
22
|
+
} & {
|
|
23
|
+
[TKey in OptionalSecretKeys<TSecrets>]?: string;
|
|
24
|
+
} : Record<string, never>;
|
|
25
|
+
export interface HandlerFs {
|
|
26
|
+
readFile(path: string, encoding?: BufferEncoding): Promise<string>;
|
|
27
|
+
writeFile(path: string, contents: string): Promise<void>;
|
|
28
|
+
exists(path: string): Promise<boolean>;
|
|
29
|
+
}
|
|
30
|
+
export interface HandlerEnv {
|
|
31
|
+
get(key: string): string | undefined;
|
|
32
|
+
}
|
|
33
|
+
export interface RenderPrimitives {
|
|
34
|
+
logger: LoggerOutput;
|
|
35
|
+
renderTable(options: RenderTableOptions): string;
|
|
36
|
+
getTheme(): ThemePalette;
|
|
37
|
+
note(message: string, title?: string): void;
|
|
38
|
+
}
|
|
39
|
+
export interface CheckResult {
|
|
40
|
+
ok: boolean;
|
|
41
|
+
message?: string;
|
|
42
|
+
}
|
|
43
|
+
export type GroupCheckContext<TServices extends object = EmptyServices> = TServices & {
|
|
44
|
+
params?: unknown;
|
|
45
|
+
secrets?: Record<string, string | undefined>;
|
|
46
|
+
fetch: typeof globalThis.fetch;
|
|
47
|
+
fs: HandlerFs;
|
|
48
|
+
env: HandlerEnv;
|
|
49
|
+
progress(message: string): void;
|
|
50
|
+
};
|
|
51
|
+
export type CommandCheckContext<TParamsSchema extends ObjectSchema<any> = AnyObjectSchema, TSecrets extends SecretDeclarations | undefined = undefined, TServices extends object = EmptyServices> = TServices & {
|
|
52
|
+
params?: Static<TParamsSchema>;
|
|
53
|
+
secrets?: InferSecrets<TSecrets>;
|
|
54
|
+
fetch: typeof globalThis.fetch;
|
|
55
|
+
fs: HandlerFs;
|
|
56
|
+
env: HandlerEnv;
|
|
57
|
+
progress(message: string): void;
|
|
58
|
+
};
|
|
59
|
+
export interface Requires<TContext = unknown> {
|
|
60
|
+
auth?: boolean;
|
|
61
|
+
apiVersion?: string;
|
|
62
|
+
check?: (ctx: TContext) => Promise<CheckResult>;
|
|
63
|
+
}
|
|
64
|
+
export interface Renderers<TResult> {
|
|
65
|
+
rich?: (result: TResult, primitives: RenderPrimitives) => void;
|
|
66
|
+
markdown?: (result: TResult, primitives: RenderPrimitives) => string;
|
|
67
|
+
json?: (result: TResult, primitives: RenderPrimitives) => unknown;
|
|
68
|
+
}
|
|
69
|
+
export type HandlerContext<TParamsSchema extends ObjectSchema<any> = AnyObjectSchema, TSecrets extends SecretDeclarations | undefined = undefined, TServices extends object = EmptyServices> = TServices & {
|
|
70
|
+
params: Static<TParamsSchema>;
|
|
71
|
+
secrets: InferSecrets<TSecrets>;
|
|
72
|
+
fetch: typeof globalThis.fetch;
|
|
73
|
+
fs: HandlerFs;
|
|
74
|
+
env: HandlerEnv;
|
|
75
|
+
progress(message: string): void;
|
|
76
|
+
};
|
|
77
|
+
export interface CommandConfig<TServices extends object, TParamsSchema extends ObjectSchema<any>, TSecrets extends SecretDeclarations | undefined, TResult> {
|
|
78
|
+
name: string;
|
|
79
|
+
description?: string;
|
|
80
|
+
aliases?: string[];
|
|
81
|
+
positional?: string[];
|
|
82
|
+
params: TParamsSchema;
|
|
83
|
+
secrets?: TSecrets;
|
|
84
|
+
scope?: Scope[];
|
|
85
|
+
confirm?: boolean;
|
|
86
|
+
requires?: Requires<CommandCheckContext<TParamsSchema, TSecrets, TServices>>;
|
|
87
|
+
handler: (ctx: HandlerContext<TParamsSchema, TSecrets, TServices>) => Promise<TResult>;
|
|
88
|
+
render?: Renderers<TResult>;
|
|
89
|
+
}
|
|
90
|
+
export interface Command<TServices extends object = EmptyServices, TParamsSchema extends ObjectSchema<any> = AnyObjectSchema, TSecrets extends SecretDeclarations | undefined = undefined, TResult = unknown> {
|
|
91
|
+
kind: "command";
|
|
92
|
+
name: string;
|
|
93
|
+
description?: string;
|
|
94
|
+
aliases: string[];
|
|
95
|
+
positional: string[];
|
|
96
|
+
params: TParamsSchema;
|
|
97
|
+
secrets: SecretDeclarations;
|
|
98
|
+
scope: Scope[];
|
|
99
|
+
confirm: boolean;
|
|
100
|
+
requires?: Requires<any>;
|
|
101
|
+
handler: (ctx: HandlerContext<TParamsSchema, TSecrets, TServices>) => Promise<TResult>;
|
|
102
|
+
render?: Renderers<TResult>;
|
|
103
|
+
}
|
|
104
|
+
export interface GroupConfig<TServices extends object> {
|
|
105
|
+
name: string;
|
|
106
|
+
description?: string;
|
|
107
|
+
aliases?: string[];
|
|
108
|
+
scope?: Scope[];
|
|
109
|
+
secrets?: SecretDeclarations;
|
|
110
|
+
requires?: Requires<GroupCheckContext<TServices>>;
|
|
111
|
+
children: Array<CommandNode<TServices>>;
|
|
112
|
+
default?: Command<TServices, any, any, any>;
|
|
113
|
+
}
|
|
114
|
+
export interface Group<TServices extends object = EmptyServices> {
|
|
115
|
+
kind: "group";
|
|
116
|
+
name: string;
|
|
117
|
+
description?: string;
|
|
118
|
+
aliases: string[];
|
|
119
|
+
scope?: Scope[];
|
|
120
|
+
secrets: SecretDeclarations;
|
|
121
|
+
requires?: Requires<any>;
|
|
122
|
+
children: Array<CommandNode<TServices>>;
|
|
123
|
+
default?: Command<TServices, any, any, any>;
|
|
124
|
+
}
|
|
125
|
+
export type CommandNode<TServices extends object = EmptyServices> = Command<TServices, any, any, any> | Group<TServices>;
|
|
126
|
+
export interface CommandTypeInfo<TName extends string = string, TParamsSchema extends ObjectSchema<any> = AnyObjectSchema, TResult = unknown, TOwnScope extends ScopeInput = ScopeInput> {
|
|
127
|
+
name: TName;
|
|
128
|
+
params: TParamsSchema;
|
|
129
|
+
result: TResult;
|
|
130
|
+
ownScope: TOwnScope;
|
|
131
|
+
}
|
|
132
|
+
export interface GroupTypeInfo<TServices extends object = EmptyServices, TName extends string = string, TChildren extends readonly unknown[] = readonly CommandNode<TServices>[], TOwnScope extends ScopeInput = ScopeInput> {
|
|
133
|
+
name: TName;
|
|
134
|
+
children: TChildren;
|
|
135
|
+
ownScope: TOwnScope;
|
|
136
|
+
}
|
|
137
|
+
type TypedCommandMetadata<TName extends string, TParamsSchema extends ObjectSchema<any>, TResult, TOwnScope extends ScopeInput> = {
|
|
138
|
+
readonly __agentKitCommandTypeInfo: CommandTypeInfo<TName, TParamsSchema, TResult, TOwnScope>;
|
|
139
|
+
};
|
|
140
|
+
type TypedGroupMetadata<TServices extends object, TName extends string, TChildren extends readonly unknown[], TOwnScope extends ScopeInput> = {
|
|
141
|
+
readonly __agentKitGroupTypeInfo: GroupTypeInfo<TServices, TName, TChildren, TOwnScope>;
|
|
142
|
+
};
|
|
143
|
+
export declare class UserError extends Error {
|
|
144
|
+
constructor(message: string);
|
|
145
|
+
}
|
|
146
|
+
export interface CommandRequirementOptions {
|
|
147
|
+
apiVersion?: string;
|
|
148
|
+
authEnvVar?: string;
|
|
149
|
+
env?: Record<string, string | undefined>;
|
|
150
|
+
}
|
|
151
|
+
export declare function resolveCommandSecrets(command: Command<any, any, any, any>, env?: Record<string, string | undefined>): Record<string, string | undefined>;
|
|
152
|
+
export declare function assertCommandRequirements(command: Command<any, any, any, any>, context: GroupCheckContext<any>, options?: CommandRequirementOptions): Promise<void>;
|
|
153
|
+
export declare function defineCommand<TServices extends object = EmptyServices, TName extends string = string, TParamsSchema extends ObjectSchema<any> = AnyObjectSchema, TSecrets extends SecretDeclarations | undefined = undefined, TResult = unknown, TOwnScope extends ScopeInput = undefined>(config: Omit<CommandConfig<TServices, TParamsSchema, TSecrets, TResult>, "name" | "scope"> & {
|
|
154
|
+
name: TName;
|
|
155
|
+
scope?: TOwnScope;
|
|
156
|
+
}): Command<TServices, TParamsSchema, TSecrets, TResult> & TypedCommandMetadata<TName, TParamsSchema, TResult, TOwnScope>;
|
|
157
|
+
export declare function defineGroup<TServices extends object = EmptyServices, TName extends string = string, TChildren extends readonly unknown[] = readonly CommandNode<TServices>[], TOwnScope extends ScopeInput = undefined>(config: Omit<GroupConfig<TServices>, "name" | "children" | "scope"> & {
|
|
158
|
+
name: TName;
|
|
159
|
+
children: TChildren & readonly CommandNode<TServices>[];
|
|
160
|
+
scope?: TOwnScope;
|
|
161
|
+
}): Group<TServices> & TypedGroupMetadata<TServices, TName, TChildren, TOwnScope>;
|
|
162
|
+
export declare function getCommandSourcePath(command: Command<any, any, any, any>): string | undefined;
|
|
163
|
+
export { S, toJsonSchema } from "agent-kit-schema";
|
|
164
|
+
export type { AnySchema, ArraySchema, BooleanSchema, EnumSchema, JsonSchema, NumberSchema, ObjectSchema, OptionalSchema, Static, StringSchema } from "agent-kit-schema";
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,366 @@
|
|
|
1
|
+
import { fileURLToPath } from "node:url";
|
|
2
|
+
const commandConfigSymbol = Symbol("agent-kit.command.config");
|
|
3
|
+
const groupConfigSymbol = Symbol("agent-kit.group.config");
|
|
4
|
+
const commandSourcePathSymbol = Symbol("agent-kit.command.sourcePath");
|
|
5
|
+
export class UserError extends Error {
|
|
6
|
+
constructor(message) {
|
|
7
|
+
super(message);
|
|
8
|
+
this.name = "UserError";
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
function cloneScope(scope) {
|
|
12
|
+
return scope === undefined ? undefined : [...scope];
|
|
13
|
+
}
|
|
14
|
+
function cloneSecretDefinition(secret) {
|
|
15
|
+
return {
|
|
16
|
+
env: secret.env,
|
|
17
|
+
description: secret.description,
|
|
18
|
+
optional: secret.optional,
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function cloneSecrets(secrets) {
|
|
22
|
+
if (secrets === undefined) {
|
|
23
|
+
return {};
|
|
24
|
+
}
|
|
25
|
+
return Object.fromEntries(Object.entries(secrets).map(([key, secret]) => [key, cloneSecretDefinition(secret)]));
|
|
26
|
+
}
|
|
27
|
+
function cloneRequires(requires) {
|
|
28
|
+
if (requires === undefined) {
|
|
29
|
+
return undefined;
|
|
30
|
+
}
|
|
31
|
+
return {
|
|
32
|
+
auth: requires.auth,
|
|
33
|
+
apiVersion: requires.apiVersion,
|
|
34
|
+
check: requires.check,
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
function parseStackPath(candidate) {
|
|
38
|
+
if (candidate.startsWith("file://")) {
|
|
39
|
+
try {
|
|
40
|
+
return fileURLToPath(candidate);
|
|
41
|
+
}
|
|
42
|
+
catch {
|
|
43
|
+
return undefined;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
if (candidate.startsWith("/")) {
|
|
47
|
+
return candidate;
|
|
48
|
+
}
|
|
49
|
+
return undefined;
|
|
50
|
+
}
|
|
51
|
+
function extractStackPath(line) {
|
|
52
|
+
const trimmed = line.trim();
|
|
53
|
+
const fileIndex = trimmed.indexOf("file://");
|
|
54
|
+
if (fileIndex >= 0) {
|
|
55
|
+
const location = trimmed.slice(fileIndex);
|
|
56
|
+
const separatorIndex = location.lastIndexOf(":");
|
|
57
|
+
const previousSeparatorIndex = separatorIndex >= 0 ? location.lastIndexOf(":", separatorIndex - 1) : -1;
|
|
58
|
+
const candidate = separatorIndex >= 0 && previousSeparatorIndex >= 0
|
|
59
|
+
? location.slice(0, previousSeparatorIndex)
|
|
60
|
+
: location;
|
|
61
|
+
return parseStackPath(candidate);
|
|
62
|
+
}
|
|
63
|
+
const slashIndex = trimmed.indexOf("/");
|
|
64
|
+
if (slashIndex < 0) {
|
|
65
|
+
return undefined;
|
|
66
|
+
}
|
|
67
|
+
const location = trimmed.slice(slashIndex);
|
|
68
|
+
const separatorIndex = location.lastIndexOf(":");
|
|
69
|
+
const previousSeparatorIndex = separatorIndex >= 0 ? location.lastIndexOf(":", separatorIndex - 1) : -1;
|
|
70
|
+
const candidate = separatorIndex >= 0 && previousSeparatorIndex >= 0
|
|
71
|
+
? location.slice(0, previousSeparatorIndex)
|
|
72
|
+
: location;
|
|
73
|
+
return parseStackPath(candidate);
|
|
74
|
+
}
|
|
75
|
+
function inferCommandSourcePath() {
|
|
76
|
+
const stack = new Error().stack;
|
|
77
|
+
if (typeof stack !== "string") {
|
|
78
|
+
return undefined;
|
|
79
|
+
}
|
|
80
|
+
for (const line of stack.split("\n").slice(1)) {
|
|
81
|
+
const candidate = extractStackPath(line);
|
|
82
|
+
if (candidate === undefined) {
|
|
83
|
+
continue;
|
|
84
|
+
}
|
|
85
|
+
if (candidate.includes("/packages/agent-kit/src/index.ts") ||
|
|
86
|
+
candidate.includes("/packages/agent-kit/dist/index.js") ||
|
|
87
|
+
candidate.includes("/node_modules/agent-kit/dist/index.js")) {
|
|
88
|
+
continue;
|
|
89
|
+
}
|
|
90
|
+
return candidate;
|
|
91
|
+
}
|
|
92
|
+
return undefined;
|
|
93
|
+
}
|
|
94
|
+
function composeChecks(parentCheck, childCheck) {
|
|
95
|
+
if (parentCheck === undefined) {
|
|
96
|
+
return childCheck;
|
|
97
|
+
}
|
|
98
|
+
if (childCheck === undefined) {
|
|
99
|
+
return parentCheck;
|
|
100
|
+
}
|
|
101
|
+
return async (ctx) => {
|
|
102
|
+
const parentResult = await parentCheck(ctx);
|
|
103
|
+
if (!parentResult.ok) {
|
|
104
|
+
return parentResult;
|
|
105
|
+
}
|
|
106
|
+
return childCheck(ctx);
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
function mergeRequires(parent, child) {
|
|
110
|
+
if (parent === undefined && child === undefined) {
|
|
111
|
+
return undefined;
|
|
112
|
+
}
|
|
113
|
+
const merged = {
|
|
114
|
+
auth: child?.auth ?? parent?.auth,
|
|
115
|
+
apiVersion: child?.apiVersion ?? parent?.apiVersion,
|
|
116
|
+
check: composeChecks(parent?.check, child?.check),
|
|
117
|
+
};
|
|
118
|
+
if (merged.auth === undefined &&
|
|
119
|
+
merged.apiVersion === undefined &&
|
|
120
|
+
merged.check === undefined) {
|
|
121
|
+
return undefined;
|
|
122
|
+
}
|
|
123
|
+
return merged;
|
|
124
|
+
}
|
|
125
|
+
function parseSimpleSemver(value) {
|
|
126
|
+
const parts = value.split(".");
|
|
127
|
+
if (parts.length !== 3) {
|
|
128
|
+
return undefined;
|
|
129
|
+
}
|
|
130
|
+
const parsed = parts.map((part) => {
|
|
131
|
+
if (part.length === 0) {
|
|
132
|
+
return Number.NaN;
|
|
133
|
+
}
|
|
134
|
+
for (const char of part) {
|
|
135
|
+
if (char < "0" || char > "9") {
|
|
136
|
+
return Number.NaN;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
return Number(part);
|
|
140
|
+
});
|
|
141
|
+
if (parsed.some((part) => !Number.isInteger(part) || part < 0)) {
|
|
142
|
+
return undefined;
|
|
143
|
+
}
|
|
144
|
+
return parsed;
|
|
145
|
+
}
|
|
146
|
+
function parseMinimumApiVersion(requirement) {
|
|
147
|
+
if (!requirement.startsWith(">=")) {
|
|
148
|
+
return undefined;
|
|
149
|
+
}
|
|
150
|
+
return parseSimpleSemver(requirement.slice(2).trim());
|
|
151
|
+
}
|
|
152
|
+
function compareSemver(left, right) {
|
|
153
|
+
for (let index = 0; index < left.length; index += 1) {
|
|
154
|
+
if (left[index] === right[index]) {
|
|
155
|
+
continue;
|
|
156
|
+
}
|
|
157
|
+
return left[index] > right[index] ? 1 : -1;
|
|
158
|
+
}
|
|
159
|
+
return 0;
|
|
160
|
+
}
|
|
161
|
+
export function resolveCommandSecrets(command, env = process.env) {
|
|
162
|
+
const secrets = {};
|
|
163
|
+
for (const [name, secret] of Object.entries(command.secrets)) {
|
|
164
|
+
const value = env[secret.env];
|
|
165
|
+
if (value === undefined && secret.optional !== true) {
|
|
166
|
+
const details = secret.description ? `\n ${secret.description}` : "";
|
|
167
|
+
throw new UserError(`Error: Missing required secret ${secret.env}${details}`);
|
|
168
|
+
}
|
|
169
|
+
secrets[name] = value;
|
|
170
|
+
}
|
|
171
|
+
return secrets;
|
|
172
|
+
}
|
|
173
|
+
export async function assertCommandRequirements(command, context, options = {}) {
|
|
174
|
+
const requires = command.requires;
|
|
175
|
+
if (requires === undefined) {
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
const env = options.env ?? process.env;
|
|
179
|
+
const authEnvVar = options.authEnvVar ?? "POE_API_KEY";
|
|
180
|
+
if (requires.auth === true && env[authEnvVar] === undefined) {
|
|
181
|
+
throw new UserError(`Error: Command "${command.name}" requires authentication.\n Run 'poe-code login' first.`);
|
|
182
|
+
}
|
|
183
|
+
if (requires.apiVersion !== undefined) {
|
|
184
|
+
const minimumVersion = parseMinimumApiVersion(requires.apiVersion);
|
|
185
|
+
if (minimumVersion === undefined) {
|
|
186
|
+
throw new UserError(`Error: Command "${command.name}" has invalid apiVersion requirement "${requires.apiVersion}". Expected format ">=X.Y.Z".`);
|
|
187
|
+
}
|
|
188
|
+
if (options.apiVersion === undefined) {
|
|
189
|
+
throw new UserError(`Error: Command "${command.name}" requires API version ${requires.apiVersion}, but no runner API version was provided.`);
|
|
190
|
+
}
|
|
191
|
+
const runnerVersion = parseSimpleSemver(options.apiVersion);
|
|
192
|
+
if (runnerVersion === undefined) {
|
|
193
|
+
throw new UserError(`Error: Command "${command.name}" requires API version ${requires.apiVersion}, but runner API version "${options.apiVersion}" is not valid semver.`);
|
|
194
|
+
}
|
|
195
|
+
if (compareSemver(runnerVersion, minimumVersion) < 0) {
|
|
196
|
+
throw new UserError(`Error: Command "${command.name}" requires API version ${requires.apiVersion}, but runner API version is ${options.apiVersion}.`);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
const checkResult = await requires.check?.(context);
|
|
200
|
+
if (checkResult && !checkResult.ok) {
|
|
201
|
+
throw new UserError(checkResult.message ?? "Command precondition failed.");
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
function mergeSecrets(parent, child) {
|
|
205
|
+
return cloneSecrets({
|
|
206
|
+
...parent,
|
|
207
|
+
...child,
|
|
208
|
+
});
|
|
209
|
+
}
|
|
210
|
+
function resolveCommandScope(ownScope, inheritedScope) {
|
|
211
|
+
return cloneScope(ownScope ?? inheritedScope) ?? ["cli", "sdk"];
|
|
212
|
+
}
|
|
213
|
+
function resolveGroupScope(ownScope, inheritedScope) {
|
|
214
|
+
return cloneScope(ownScope ?? inheritedScope);
|
|
215
|
+
}
|
|
216
|
+
function createBaseCommand(config) {
|
|
217
|
+
const command = {
|
|
218
|
+
kind: "command",
|
|
219
|
+
name: config.name,
|
|
220
|
+
description: config.description,
|
|
221
|
+
aliases: [...(config.aliases ?? [])],
|
|
222
|
+
positional: [...(config.positional ?? [])],
|
|
223
|
+
params: config.params,
|
|
224
|
+
secrets: cloneSecrets(config.secrets),
|
|
225
|
+
scope: resolveCommandScope(config.scope, undefined),
|
|
226
|
+
confirm: config.confirm ?? false,
|
|
227
|
+
requires: cloneRequires(config.requires),
|
|
228
|
+
handler: config.handler,
|
|
229
|
+
render: config.render,
|
|
230
|
+
};
|
|
231
|
+
Object.defineProperty(command, commandConfigSymbol, {
|
|
232
|
+
value: {
|
|
233
|
+
scope: cloneScope(config.scope),
|
|
234
|
+
secrets: cloneSecrets(config.secrets),
|
|
235
|
+
requires: cloneRequires(config.requires),
|
|
236
|
+
sourcePath: inferCommandSourcePath(),
|
|
237
|
+
},
|
|
238
|
+
});
|
|
239
|
+
return command;
|
|
240
|
+
}
|
|
241
|
+
function createBaseGroup(config) {
|
|
242
|
+
const group = {
|
|
243
|
+
kind: "group",
|
|
244
|
+
name: config.name,
|
|
245
|
+
description: config.description,
|
|
246
|
+
aliases: [...(config.aliases ?? [])],
|
|
247
|
+
scope: resolveGroupScope(config.scope, undefined),
|
|
248
|
+
secrets: cloneSecrets(config.secrets),
|
|
249
|
+
requires: cloneRequires(config.requires),
|
|
250
|
+
children: [],
|
|
251
|
+
default: undefined,
|
|
252
|
+
};
|
|
253
|
+
Object.defineProperty(group, groupConfigSymbol, {
|
|
254
|
+
value: {
|
|
255
|
+
scope: cloneScope(config.scope),
|
|
256
|
+
secrets: cloneSecrets(config.secrets),
|
|
257
|
+
requires: cloneRequires(config.requires),
|
|
258
|
+
children: [...config.children],
|
|
259
|
+
default: config.default,
|
|
260
|
+
},
|
|
261
|
+
});
|
|
262
|
+
return group;
|
|
263
|
+
}
|
|
264
|
+
function getInternalCommandConfig(command) {
|
|
265
|
+
return command[commandConfigSymbol];
|
|
266
|
+
}
|
|
267
|
+
function getInternalGroupConfig(group) {
|
|
268
|
+
return group[groupConfigSymbol];
|
|
269
|
+
}
|
|
270
|
+
function materializeCommand(command, inherited) {
|
|
271
|
+
const internal = getInternalCommandConfig(command);
|
|
272
|
+
const materialized = {
|
|
273
|
+
kind: "command",
|
|
274
|
+
name: command.name,
|
|
275
|
+
description: command.description,
|
|
276
|
+
aliases: [...command.aliases],
|
|
277
|
+
positional: [...command.positional],
|
|
278
|
+
params: command.params,
|
|
279
|
+
secrets: mergeSecrets(inherited.secrets, internal.secrets),
|
|
280
|
+
scope: resolveCommandScope(internal.scope, inherited.scope),
|
|
281
|
+
confirm: command.confirm,
|
|
282
|
+
requires: mergeRequires(inherited.requires, internal.requires),
|
|
283
|
+
handler: command.handler,
|
|
284
|
+
render: command.render,
|
|
285
|
+
};
|
|
286
|
+
Object.defineProperty(materialized, commandConfigSymbol, {
|
|
287
|
+
value: {
|
|
288
|
+
scope: cloneScope(internal.scope),
|
|
289
|
+
secrets: cloneSecrets(internal.secrets),
|
|
290
|
+
requires: cloneRequires(internal.requires),
|
|
291
|
+
sourcePath: internal.sourcePath,
|
|
292
|
+
},
|
|
293
|
+
});
|
|
294
|
+
Object.defineProperty(materialized, commandSourcePathSymbol, {
|
|
295
|
+
value: internal.sourcePath,
|
|
296
|
+
});
|
|
297
|
+
return materialized;
|
|
298
|
+
}
|
|
299
|
+
function materializeGroup(group, inherited) {
|
|
300
|
+
const internal = getInternalGroupConfig(group);
|
|
301
|
+
const scope = resolveGroupScope(internal.scope, inherited.scope);
|
|
302
|
+
const secrets = mergeSecrets(inherited.secrets, internal.secrets);
|
|
303
|
+
const requires = mergeRequires(inherited.requires, internal.requires);
|
|
304
|
+
const materializedChildren = internal.children.map((child) => materializeNode(child, {
|
|
305
|
+
scope,
|
|
306
|
+
secrets,
|
|
307
|
+
requires,
|
|
308
|
+
}));
|
|
309
|
+
let defaultChild;
|
|
310
|
+
if (internal.default !== undefined) {
|
|
311
|
+
const defaultIndex = internal.children.indexOf(internal.default);
|
|
312
|
+
if (defaultIndex === -1) {
|
|
313
|
+
throw new UserError(`Default command "${internal.default.name}" must be listed in children.`);
|
|
314
|
+
}
|
|
315
|
+
const resolvedDefault = materializedChildren[defaultIndex];
|
|
316
|
+
if (resolvedDefault?.kind !== "command") {
|
|
317
|
+
throw new UserError(`Default child "${internal.default.name}" must be a command.`);
|
|
318
|
+
}
|
|
319
|
+
defaultChild = resolvedDefault;
|
|
320
|
+
}
|
|
321
|
+
const materialized = {
|
|
322
|
+
kind: "group",
|
|
323
|
+
name: group.name,
|
|
324
|
+
description: group.description,
|
|
325
|
+
aliases: [...group.aliases],
|
|
326
|
+
scope,
|
|
327
|
+
secrets,
|
|
328
|
+
requires,
|
|
329
|
+
children: materializedChildren,
|
|
330
|
+
default: defaultChild,
|
|
331
|
+
};
|
|
332
|
+
Object.defineProperty(materialized, groupConfigSymbol, {
|
|
333
|
+
value: {
|
|
334
|
+
scope: cloneScope(internal.scope),
|
|
335
|
+
secrets: cloneSecrets(internal.secrets),
|
|
336
|
+
requires: cloneRequires(internal.requires),
|
|
337
|
+
children: [...internal.children],
|
|
338
|
+
default: internal.default,
|
|
339
|
+
},
|
|
340
|
+
});
|
|
341
|
+
return materialized;
|
|
342
|
+
}
|
|
343
|
+
function materializeNode(node, inherited) {
|
|
344
|
+
if (node.kind === "command") {
|
|
345
|
+
return materializeCommand(node, inherited);
|
|
346
|
+
}
|
|
347
|
+
return materializeGroup(node, inherited);
|
|
348
|
+
}
|
|
349
|
+
export function defineCommand(config) {
|
|
350
|
+
return materializeCommand(createBaseCommand(config), {
|
|
351
|
+
scope: undefined,
|
|
352
|
+
secrets: {},
|
|
353
|
+
requires: undefined,
|
|
354
|
+
});
|
|
355
|
+
}
|
|
356
|
+
export function defineGroup(config) {
|
|
357
|
+
return materializeGroup(createBaseGroup(config), {
|
|
358
|
+
scope: undefined,
|
|
359
|
+
secrets: {},
|
|
360
|
+
requires: undefined,
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
export function getCommandSourcePath(command) {
|
|
364
|
+
return command[commandSourcePathSymbol];
|
|
365
|
+
}
|
|
366
|
+
export { S, toJsonSchema } from "agent-kit-schema";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { S } from "agent-kit-schema";
|
|
2
|
+
import { defineCommand, defineGroup } from "./index.js";
|
|
3
|
+
import { createMCPServer, runMCP } from "./mcp.js";
|
|
4
|
+
const ignoredRoot = defineGroup({
|
|
5
|
+
name: "root",
|
|
6
|
+
children: [
|
|
7
|
+
defineCommand({
|
|
8
|
+
name: "usage",
|
|
9
|
+
scope: ["mcp"],
|
|
10
|
+
params: S.Object({
|
|
11
|
+
dryRun: S.Boolean(),
|
|
12
|
+
}),
|
|
13
|
+
handler: async ({ params }) => params,
|
|
14
|
+
}),
|
|
15
|
+
],
|
|
16
|
+
});
|
|
17
|
+
const ignoredOptions = {
|
|
18
|
+
name: "cmdkit-test",
|
|
19
|
+
version: "1.0.0",
|
|
20
|
+
tools: ["usage"],
|
|
21
|
+
casing: "snake",
|
|
22
|
+
};
|
|
23
|
+
const ignoredServer = createMCPServer(ignoredRoot, ignoredOptions);
|
|
24
|
+
const ignoredServerArray = createMCPServer([ignoredRoot], ignoredOptions);
|
|
25
|
+
const ignoredRun = runMCP(ignoredRoot, ignoredOptions);
|
|
26
|
+
const ignoredRunArray = runMCP([ignoredRoot], ignoredOptions);
|
package/dist/mcp.d.ts
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { type SDKTransport, type Server as TinyServer } from "tiny-stdio-mcp-server";
|
|
2
|
+
import type { Group } from "./index.js";
|
|
3
|
+
type Casing = "snake" | "camel";
|
|
4
|
+
type CmdkitServer = Omit<TinyServer, "connect"> & {
|
|
5
|
+
connect(transport: SDKTransport): Promise<void>;
|
|
6
|
+
};
|
|
7
|
+
export interface RunMCPOptions<TServices extends object = Record<string, unknown>> {
|
|
8
|
+
name: string;
|
|
9
|
+
version: string;
|
|
10
|
+
/**
|
|
11
|
+
* Optional allowlist of MCP tool names or group prefixes.
|
|
12
|
+
*
|
|
13
|
+
* Tool names always use `__`-joined snake_case path segments, for example
|
|
14
|
+
* `root__bot__create`.
|
|
15
|
+
*
|
|
16
|
+
* Passing a group prefix like `root__bot` includes every descendant tool in
|
|
17
|
+
* that subtree.
|
|
18
|
+
*/
|
|
19
|
+
tools?: string[];
|
|
20
|
+
services?: TServices;
|
|
21
|
+
/**
|
|
22
|
+
* Controls MCP input-schema key casing and accepted argument-key casing.
|
|
23
|
+
*
|
|
24
|
+
* This does not change tool names. Tool names always stay `__`-joined
|
|
25
|
+
* snake_case path segments.
|
|
26
|
+
*/
|
|
27
|
+
casing?: Casing;
|
|
28
|
+
}
|
|
29
|
+
export declare function createMCPServer<TServices extends object = Record<string, unknown>>(roots: Group<TServices> | Group<TServices>[], options: RunMCPOptions<TServices>): CmdkitServer;
|
|
30
|
+
export declare function runMCP<TServices extends object = Record<string, unknown>>(roots: Group<TServices> | Group<TServices>[], options: RunMCPOptions<TServices>): Promise<void>;
|
|
31
|
+
export {};
|