@ai-sdk/mcp 1.0.7 → 1.0.9

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/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @ai-sdk/mcp
2
2
 
3
+ ## 1.0.9
4
+
5
+ ### Patch Changes
6
+
7
+ - ec84ffd: fix(mcp): lenient JSON-RPC parsing for http transport
8
+
9
+ ## 1.0.8
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies [46f46e4]
14
+ - @ai-sdk/provider-utils@4.0.7
15
+
3
16
  ## 1.0.7
4
17
 
5
18
  ### Patch Changes
package/dist/index.js CHANGED
@@ -1371,6 +1371,10 @@ var HttpMCPTransport = class {
1371
1371
  (_c = this.onerror) == null ? void 0 : _c.call(this, error2);
1372
1372
  throw error2;
1373
1373
  }
1374
+ const isNotification = !("id" in message);
1375
+ if (isNotification) {
1376
+ return;
1377
+ }
1374
1378
  const contentType = response.headers.get("content-type") || "";
1375
1379
  if (contentType.includes("application/json")) {
1376
1380
  const data = await response.json();