@goodtiming/baton-sdk 0.6.7 → 0.6.8

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 CHANGED
@@ -171,7 +171,7 @@ Each affected event says so, in its own field (`result_capture: "off"`), rather
171
171
 
172
172
  **What is still captured, and it is deliberate:** the tool name, the duration, and whether the call failed — so failure detection, pairing and timing all keep working. The message of an error your handler **throws** is withheld too: thrown messages often echo the data a call was handling.
173
173
 
174
- **What it does not withhold:** the message of a failed resource or prompt request. `resource_list_error`, `resource_read_error`, `prompt_list_error` and `prompt_get_error` keep it under `"off"`, so `withBaton` and `createBaton` print a warning saying so when you set the mode (see [Resources and prompts](#resources-and-prompts)).
174
+ **What it does not withhold:** the message of a failed tool list, resource or prompt request. `tool_list_error`, `resource_list_error`, `resource_read_error`, `prompt_list_error` and `prompt_get_error` keep it under `"off"`, so `withBaton` and `createBaton` print a warning saying so when you set the mode (see [Tool listings](#tool-listings) and [Resources and prompts](#resources-and-prompts)).
175
175
 
176
176
  **What it costs you:** anything that needs to read a response body. A call that returns `200` with a useless body can no longer be detected, and those calls sit outside the denominator of body-level analysis rather than counting as passes or failures.
177
177
 
@@ -248,6 +248,10 @@ that response held and how long it took. No tool name, description or schema
248
248
  is on these events. They carry the principal your `resolvePrincipal` hook
249
249
  returns ([Who is calling](#who-is-calling)).
250
250
 
251
+ A failed listing's `tool_list_error` carries the message that was thrown, and
252
+ `resultCaptureMode: "off"` does not withhold it. That message can be your own
253
+ text, from a `tools/list` handler you set on the server.
254
+
251
255
  ## Turning capture off entirely
252
256
 
253
257
  Not the same thing as **Not capturing responses at all**: that one keeps the signal and drops the response bodies, this one emits nothing at all. It also belongs to a different person — `resultCaptureMode` is set by whoever WRAPS the server, in code; this is set by whoever RUNS it, in the environment.
package/dist/index.cjs CHANGED
@@ -103,7 +103,7 @@ __export(index_exports, {
103
103
  module.exports = __toCommonJS(index_exports);
104
104
 
105
105
  // src/version.ts
106
- var SDK_VERSION = "ts-0.6.7";
106
+ var SDK_VERSION = "ts-0.6.8";
107
107
 
108
108
  // src/events.ts
109
109
  var import_zod = require("zod");
@@ -3956,7 +3956,7 @@ function warnAboutSettings(config) {
3956
3956
  }
3957
3957
  if (config.resultCaptureMode === WITHHELD) {
3958
3958
  warn(
3959
- 'baton: resultCaptureMode "off" does not withhold the message of a failed resource or prompt request. resource_list_error, resource_read_error, prompt_list_error and prompt_get_error carry that message, which can quote what your handler fetched. Throw a message that names the resource or prompt, not its contents.'
3959
+ 'baton: resultCaptureMode "off" does not withhold the message of a failed tool list, resource or prompt request. tool_list_error, resource_list_error, resource_read_error, prompt_list_error and prompt_get_error carry that message, which can include text your handler or middleware threw. Throw a message that does not quote what your code fetched.'
3960
3960
  );
3961
3961
  }
3962
3962
  }