caplets 0.12.7 → 0.14.0

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.
Files changed (3) hide show
  1. package/README.md +37 -3
  2. package/dist/index.js +19594 -13827
  3. package/package.json +8 -6
package/README.md CHANGED
@@ -68,6 +68,18 @@ Connect Caplets to any MCP client:
68
68
  Ask your agent to use Caplets. It will see a compact capability list first, then inspect
69
69
  only the backend it needs.
70
70
 
71
+ You can also invoke configured Caplets directly from the CLI for agent-friendly scripts and smoke tests:
72
+
73
+ ```sh
74
+ caplets get-caplet context7
75
+ caplets list-tools context7
76
+ caplets get-tool context7.resolve-library-id
77
+ caplets call-tool context7.resolve-library-id --args '{"libraryName":"react"}'
78
+ caplets call-tool context7.resolve-library-id --args '{"libraryName":"react"}' --field result.id --format json
79
+ ```
80
+
81
+ Direct CLI operation commands print Markdown summaries by default. Add `--format plain` for plain text or `--format json` for machine-readable JSON (`md` is accepted as an alias for `markdown`). If a downstream tool returns `isError: true`, Caplets still exits with status code 1.
82
+
71
83
  ## Agent Plugins
72
84
 
73
85
  Use Caplets as a normal MCP server everywhere, or install a native agent integration when
@@ -610,7 +622,10 @@ shell snippets.
610
622
  "description": "Fetch status for one service.",
611
623
  "inputSchema": {
612
624
  "type": "object",
613
- "properties": { "service": { "type": "string" }, "verbose": { "type": "boolean" } },
625
+ "properties": {
626
+ "service": { "type": "string" },
627
+ "verbose": { "type": "boolean" }
628
+ },
614
629
  "required": ["service"]
615
630
  },
616
631
  "query": { "verbose": "$input.verbose" }
@@ -693,7 +708,7 @@ an existing destination file.
693
708
 
694
709
  Use `capletSets` to expose another Caplets collection as nested Caplets. Each child Caplet appears
695
710
  as one downstream tool and supports the full Caplets operation set: `get_caplet`, `check_backend`,
696
- `check_mcp_server`, `list_tools`, `search_tools`, `get_tool`, and `call_tool`.
711
+ `list_tools`, `search_tools`, `get_tool`, and `call_tool`.
697
712
 
698
713
  ```json
699
714
  {
@@ -891,7 +906,6 @@ Available operations:
891
906
 
892
907
  - `get_caplet`: return the configured capability card without starting the downstream server.
893
908
  - `check_backend`: verify the selected backend, whether MCP, OpenAPI, GraphQL, HTTP, CLI, or nested Caplets.
894
- - `check_mcp_server`: start or connect to an MCP server and verify its tool list.
895
909
  - `list_tools`: return compact downstream tool metadata.
896
910
  - `search_tools`: search downstream tool names and descriptions within this Caplet.
897
911
  - `get_tool`: return full metadata for one exact downstream tool.
@@ -900,6 +914,26 @@ Available operations:
900
914
  Requests are strict: operation-specific extra fields are rejected, and `call_tool` requires
901
915
  `arguments` to be a JSON object.
902
916
 
917
+ Discovery operations (`get_caplet`, `check_backend`, `list_tools`, `search_tools`, and
918
+ `get_tool`) return wrapper-generated results whose `structuredContent.caplets` field
919
+ identifies the Caplet with `id`, plus backend, operation, status, and elapsed time when
920
+ available. Discovery result objects and compact tool entries also use `id` for the
921
+ configured Caplet identity. Compact `list_tools` and `search_tools` entries may include
922
+ input/output schema hashes; treat those
923
+ hashes as reuse hints for a schema you have already inspected, not as a replacement for
924
+ `get_tool` when arguments, output, or semantics are unclear.
925
+
926
+ Direct `call_tool` preserves the downstream tool result shape instead of wrapping it in
927
+ `structuredContent.result`. When the result can carry MCP metadata, Caplets adds
928
+ `_meta.caplets` with the same call context and status. It may also include artifact metadata
929
+ for paths mentioned by downstream content, such as screenshots, snapshots, logs, downloads,
930
+ or other saved files. Artifact `displayPath` values are either absolute local paths or
931
+ relative to the downstream MCP server process, not necessarily relative to the current
932
+ project or Caplets process.
933
+
934
+ For first use, the explicit progressive-discovery path is still safest: choose a Caplet,
935
+ `search_tools` or `list_tools`, inspect uncertain tools with `get_tool`, then `call_tool`.
936
+
903
937
  ## Development
904
938
 
905
939
  ```sh