You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(core): address review on isSpecType/specTypeSchemas
- Explicit auth-schema allowlist (excludes SafeUrl/OptionalSafeUrl/IdJagTokenExchangeResponse helpers)
- Guard predicate types value as schema input (z.input), not output, since safeParse only proves input shape
- SchemaRecord typed as StandardSchemaV1<In, Out> so validate() output is the spec type
- JSDoc/migration examples await validate() (Result | Promise<Result>); drop stale setCustom* refs
const result =specTypeSchemas.CallToolResult['~standard'].validate(value);
464
+
const result =awaitspecTypeSchemas.CallToolResult['~standard'].validate(value);
465
465
```
466
466
467
-
`isSpecType` and `specTypeSchemas` are keyed by `SpecTypeName` — a literal union of every named type in the MCP spec — so you get autocomplete and a compile error on typos. `specTypeSchemas.X` is a `StandardSchemaV1<T>`, which composes with any Standard-Schema-aware library and is accepted
468
-
by `setCustomRequestHandler`/`sendCustomRequest`. The pre-existing `isCallToolResult(value)` guard still works.
467
+
`isSpecType` and `specTypeSchemas` are keyed by `SpecTypeName` — a literal union of every named type in the MCP spec — so you get autocomplete and a compile error on typos. `specTypeSchemas.X` is a `StandardSchemaV1<In, Out>`, which composes with any Standard-Schema-aware library. The pre-existing `isCallToolResult(value)` guard still works.
469
468
470
469
### Client list methods return empty results for missing capabilities
0 commit comments