@tmcp/transport-http 0.8.1 → 0.8.3
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/package.json +6 -6
- package/src/index.js +5 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tmcp/transport-http",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.3",
|
|
4
4
|
"description": "Transport for TMCP using HTTP",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.js",
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"src/**/*"
|
|
17
17
|
],
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"tmcp": "^1.
|
|
20
|
-
"@tmcp/auth": "^0.3.3"
|
|
19
|
+
"tmcp": "^1.18.0",
|
|
20
|
+
"@tmcp/auth": "^0.3.3 || ^0.4.0"
|
|
21
21
|
},
|
|
22
22
|
"peerDependenciesMeta": {
|
|
23
23
|
"@tmcp/auth": {
|
|
@@ -46,9 +46,9 @@
|
|
|
46
46
|
"publint": "^0.3.12",
|
|
47
47
|
"valibot": "^1.1.0",
|
|
48
48
|
"vitest": "^4.0.0",
|
|
49
|
-
"@tmcp/adapter-valibot": "^0.1.
|
|
50
|
-
"@tmcp/auth": "^0.
|
|
51
|
-
"tmcp": "^1.
|
|
49
|
+
"@tmcp/adapter-valibot": "^0.1.5",
|
|
50
|
+
"@tmcp/auth": "^0.4.0",
|
|
51
|
+
"tmcp": "^1.18.1"
|
|
52
52
|
},
|
|
53
53
|
"publishConfig": {
|
|
54
54
|
"access": "public"
|
package/src/index.js
CHANGED
|
@@ -161,7 +161,7 @@ export class HttpTransport {
|
|
|
161
161
|
}
|
|
162
162
|
await this.#options.sessionManager.streams.send(
|
|
163
163
|
sessions,
|
|
164
|
-
'
|
|
164
|
+
'event: message\ndata: ' + JSON.stringify(request) + '\n\n',
|
|
165
165
|
);
|
|
166
166
|
});
|
|
167
167
|
|
|
@@ -172,7 +172,7 @@ export class HttpTransport {
|
|
|
172
172
|
|
|
173
173
|
controller.enqueue(
|
|
174
174
|
this.#text_encoder.encode(
|
|
175
|
-
'
|
|
175
|
+
'event: message\ndata: ' + JSON.stringify(request) + '\n\n',
|
|
176
176
|
),
|
|
177
177
|
);
|
|
178
178
|
});
|
|
@@ -407,7 +407,9 @@ export class HttpTransport {
|
|
|
407
407
|
|
|
408
408
|
controller?.enqueue(
|
|
409
409
|
this.#text_encoder.encode(
|
|
410
|
-
'
|
|
410
|
+
'event: message\ndata: ' +
|
|
411
|
+
JSON.stringify(response) +
|
|
412
|
+
'\n\n',
|
|
411
413
|
),
|
|
412
414
|
);
|
|
413
415
|
controller?.close();
|