@studiometa/productive-mcp 0.10.13 → 0.10.15
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/handlers/api-read.d.ts +2 -1
- package/dist/handlers/api-read.d.ts.map +1 -1
- package/dist/handlers/api-utils.d.ts +20 -0
- package/dist/handlers/api-utils.d.ts.map +1 -1
- package/dist/handlers/help.d.ts +20 -0
- package/dist/handlers/help.d.ts.map +1 -1
- package/dist/handlers/index.d.ts.map +1 -1
- package/dist/handlers/run.d.ts +24 -0
- package/dist/handlers/run.d.ts.map +1 -0
- package/dist/handlers/search-docs.d.ts +22 -0
- package/dist/handlers/search-docs.d.ts.map +1 -0
- package/dist/{handlers-BE96O-uy.js → handlers-BEeOjytC.js} +974 -10
- package/dist/{handlers-BE96O-uy.js.map → handlers-BEeOjytC.js.map} +1 -1
- package/dist/handlers.js +1 -1
- package/dist/{http-BJd4MLh0.js → http-BXP2cZn1.js} +4 -4
- package/dist/{http-BJd4MLh0.js.map → http-BXP2cZn1.js.map} +1 -1
- package/dist/http.js +1 -1
- package/dist/index.js +2 -2
- package/dist/run/bridge.d.ts +53 -0
- package/dist/run/bridge.d.ts.map +1 -0
- package/dist/run/docs.d.ts +23 -0
- package/dist/run/docs.d.ts.map +1 -0
- package/dist/run/engine.d.ts +60 -0
- package/dist/run/engine.d.ts.map +1 -0
- package/dist/run/limits.d.ts +33 -0
- package/dist/run/limits.d.ts.map +1 -0
- package/dist/run/prelude.d.ts +27 -0
- package/dist/run/prelude.d.ts.map +1 -0
- package/dist/run/render.d.ts +30 -0
- package/dist/run/render.d.ts.map +1 -0
- package/dist/run/strip.d.ts +20 -0
- package/dist/run/strip.d.ts.map +1 -0
- package/dist/schema.d.ts +13 -2
- package/dist/schema.d.ts.map +1 -1
- package/dist/server.js +2 -2
- package/dist/{stdio-BnfO285Q.js → stdio-pJj1QGos.js} +2 -2
- package/dist/{stdio-BnfO285Q.js.map → stdio-pJj1QGos.js.map} +1 -1
- package/dist/stdio.js +1 -1
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +93 -4
- package/dist/tools.js.map +1 -1
- package/dist/{version-Bza5GmW5.js → version-CQgSvXUX.js} +3 -3
- package/dist/{version-Bza5GmW5.js.map → version-CQgSvXUX.js.map} +1 -1
- package/package.json +5 -3
- package/skills/SKILL.md +71 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api-read.d.ts","sourceRoot":"","sources":["../../src/handlers/api-read.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"api-read.d.ts","sourceRoot":"","sources":["../../src/handlers/api-read.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAe7D,MAAM,WAAW,WAAW;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACjC,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,wBAAsB,aAAa,CAAC,IAAI,EAAE,WAAW,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,UAAU,CAAC,CAyC/F"}
|
|
@@ -23,5 +23,25 @@ export declare function validatePagination(args: {
|
|
|
23
23
|
}): void;
|
|
24
24
|
export declare function validateFilterSpec(filter: Record<string, unknown> | undefined, methodSpec: ApiMethodSpec): void;
|
|
25
25
|
export declare function validateSort(sort: string[] | undefined, methodSpec: ApiMethodSpec): void;
|
|
26
|
+
/** Number of documented endpoints in the catalog. */
|
|
27
|
+
export declare function apiEndpointCount(): number;
|
|
28
|
+
/** A single endpoint-catalog search match. */
|
|
29
|
+
export interface EndpointSearchMatch {
|
|
30
|
+
path: string;
|
|
31
|
+
methods: string[];
|
|
32
|
+
summary?: string;
|
|
33
|
+
}
|
|
34
|
+
export interface EndpointSearchResult {
|
|
35
|
+
query: string;
|
|
36
|
+
total: number;
|
|
37
|
+
matches: EndpointSearchMatch[];
|
|
38
|
+
truncated?: boolean;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Keyword-search the documented endpoint catalog, returning matching paths
|
|
42
|
+
* (not their full specs) so an agent can drill in with `api_read describe`.
|
|
43
|
+
* Pure — reused by `api_read` search and the global `search_docs` tool.
|
|
44
|
+
*/
|
|
45
|
+
export declare function searchApiEndpoints(query: string, limit?: number): EndpointSearchResult;
|
|
26
46
|
export declare function describeApiEndpoint(path: string): Record<string, unknown>;
|
|
27
47
|
//# sourceMappingURL=api-utils.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api-utils.d.ts","sourceRoot":"","sources":["../../src/handlers/api-utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAKhF,eAAO,MAAM,YAAY,MAAM,CAAC;AAChC,eAAO,MAAM,iBAAiB,KAAK,CAAC;AACpC,eAAO,MAAM,aAAa,KAAK,CAAC;AAEhC,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,eAAe,CAAC;IACtB,UAAU,EAAE,aAAa,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;CACxB;AAMD,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAerD;AAED,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,MAAM,EACZ,MAAM,EA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W,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,oBAAoB;IACnC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,mBAAmB,EAAE,CAAC;IAC/B,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAcD;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,oBAAoB,CAsBlF;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAmCzE"}
|
package/dist/handlers/help.d.ts
CHANGED
|
@@ -6,6 +6,26 @@ import type { ToolResult } from './types.js';
|
|
|
6
6
|
* Handle help action - returns documentation for a specific resource
|
|
7
7
|
*/
|
|
8
8
|
export declare function handleHelp(resource: string): ToolResult;
|
|
9
|
+
/** A single cross-resource help-search match. */
|
|
10
|
+
export interface HelpSearchMatch {
|
|
11
|
+
resource: string;
|
|
12
|
+
description: string;
|
|
13
|
+
/** Which parts of the resource's help matched the query. */
|
|
14
|
+
matched_in: string[];
|
|
15
|
+
}
|
|
16
|
+
/** All resource names that have help documentation. */
|
|
17
|
+
export declare function helpResourceNames(): string[];
|
|
18
|
+
/**
|
|
19
|
+
* Search help across all resources, returning a compact ranked list of matching
|
|
20
|
+
* resources (not their full docs). Pure — reused by both the `action=help`
|
|
21
|
+
* query path and the global `search_docs` tool.
|
|
22
|
+
*/
|
|
23
|
+
export declare function searchResourceHelp(query: string): HelpSearchMatch[];
|
|
24
|
+
/**
|
|
25
|
+
* `action=help` query path: cross-resource help search as a tool result, so an
|
|
26
|
+
* agent can drill into a specific resource with action="help".
|
|
27
|
+
*/
|
|
28
|
+
export declare function handleHelpSearch(query: string): ToolResult;
|
|
9
29
|
/**
|
|
10
30
|
* Get help for all resources (overview)
|
|
11
31
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"help.d.ts","sourceRoot":"","sources":["../../src/handlers/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAq/B7C;;GAEG;AACH,wBAAgB,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,UAAU,CAevD;AAED;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,UAAU,CAY/C"}
|
|
1
|
+
{"version":3,"file":"help.d.ts","sourceRoot":"","sources":["../../src/handlers/help.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAq/B7C;;GAEG;AACH,wBAAgB,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,UAAU,CAevD;AAED,iDAAiD;AACjD,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,4DAA4D;IAC5D,UAAU,EAAE,MAAM,EAAE,CAAC;CACtB;AA2BD,uDAAuD;AACvD,wBAAgB,iBAAiB,IAAI,MAAM,EAAE,CAE5C;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,eAAe,EAAE,CAcnE;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,GAAG,UAAU,CAiB1D;AAED;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,UAAU,CAY/C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/handlers/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAKH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAExD,OAAO,KAAK,EAAkB,UAAU,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/handlers/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAKH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAExD,OAAO,KAAK,EAAkB,UAAU,EAAE,MAAM,YAAY,CAAC;AA0C7D,YAAY,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AA8I7C;;GAEG;AACH,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,WAAW,EAAE,qBAAqB,GACjC,OAAO,CAAC,UAAU,CAAC,CAuMrB"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Handler for the `run_script` tool.
|
|
3
|
+
*
|
|
4
|
+
* Executes an agent-authored JavaScript/TypeScript script inside a QuickJS
|
|
5
|
+
* sandbox. The script reaches Productive only through the host bridge, which
|
|
6
|
+
* re-enters `executeToolWithCredentials` — so it inherits credential scoping,
|
|
7
|
+
* rate limiting, and validation, and has no other capabilities.
|
|
8
|
+
*
|
|
9
|
+
* Disabled by default; enable with `PRODUCTIVE_MCP_ENABLE_RUN=true`.
|
|
10
|
+
*/
|
|
11
|
+
import type { ProductiveCredentials } from '../auth.js';
|
|
12
|
+
import type { ToolExecutor } from '../run/bridge.js';
|
|
13
|
+
import type { ToolResult } from './types.js';
|
|
14
|
+
export interface RunScriptArgs {
|
|
15
|
+
code?: unknown;
|
|
16
|
+
args?: unknown;
|
|
17
|
+
flags?: unknown;
|
|
18
|
+
dry_run?: unknown;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Execute the `run_script` tool.
|
|
22
|
+
*/
|
|
23
|
+
export declare function handleRunScript(rawArgs: RunScriptArgs, credentials: ProductiveCredentials, exec: ToolExecutor, env?: NodeJS.ProcessEnv): Promise<ToolResult>;
|
|
24
|
+
//# sourceMappingURL=run.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../src/handlers/run.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,KAAK,EAAiB,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACpE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAU7C,MAAM,WAAW,aAAa;IAC5B,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAgBD;;GAEG;AACH,wBAAsB,eAAe,CACnC,OAAO,EAAE,aAAa,EACtB,WAAW,EAAE,qBAAqB,EAClC,IAAI,EAAE,YAAY,EAClB,GAAG,GAAE,MAAM,CAAC,UAAwB,GACnC,OAAO,CAAC,UAAU,CAAC,CAsErB"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Global documentation discovery (`search_docs` tool).
|
|
3
|
+
*
|
|
4
|
+
* One front door for "where do I even look?". It reuses the per-domain search
|
|
5
|
+
* engines so nothing drifts:
|
|
6
|
+
* - resource help → searchResourceHelp (drill in with productive action=help)
|
|
7
|
+
* - raw API endpoints → searchApiEndpoints (drill in with api_read describe)
|
|
8
|
+
* - run_script API → findDocSections (this tool IS the drill-in: it owns
|
|
9
|
+
* the scripting docs and returns their full bodies)
|
|
10
|
+
*
|
|
11
|
+
* With no query it returns a compact table of contents across those domains;
|
|
12
|
+
* with a query it returns ranked cross-domain matches. For resources and
|
|
13
|
+
* endpoints it points at the focused tool to drill in; for scripting (which has
|
|
14
|
+
* no other owning tool) it returns the matching section bodies directly.
|
|
15
|
+
*/
|
|
16
|
+
import type { ToolResult } from './types.js';
|
|
17
|
+
/**
|
|
18
|
+
* Handle the `search_docs` tool: a table of contents with no query, or ranked
|
|
19
|
+
* cross-domain matches with a query.
|
|
20
|
+
*/
|
|
21
|
+
export declare function handleSearchDocs(query?: string): ToolResult;
|
|
22
|
+
//# sourceMappingURL=search-docs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search-docs.d.ts","sourceRoot":"","sources":["../../src/handlers/search-docs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAqC7C;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,UAAU,CAoC3D"}
|