mcp-use 1.11.0-canary.19 → 1.11.0-canary.20
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/dist/.tsbuildinfo +1 -1
- package/dist/{chunk-7KWUIU7I.js → chunk-5MXNFVMH.js} +2 -2
- package/dist/{chunk-5QAH2BZN.js → chunk-ENJHJKXG.js} +1 -1
- package/dist/{chunk-FKQI4DOX.js → chunk-IXGXOEPQ.js} +4 -4
- package/dist/{chunk-2CX2RMGM.js → chunk-J7NQQHWW.js} +18 -4
- package/dist/{chunk-XWY3UCBV.js → chunk-RSC4XIGS.js} +2 -2
- package/dist/{chunk-DDBBDHDD.js → chunk-SP22S3FF.js} +2 -2
- package/dist/{chunk-MIZSOV27.js → chunk-TA74PN4A.js} +1 -1
- package/dist/{chunk-X6LSPCRY.js → chunk-UVA62XMK.js} +1 -1
- package/dist/{chunk-ERDKUHUF.js → chunk-YCXBIMRG.js} +4 -4
- package/dist/index.cjs +18 -4
- package/dist/index.js +12 -12
- package/dist/src/agents/index.cjs +18 -4
- package/dist/src/agents/index.js +5 -5
- package/dist/src/browser.cjs +18 -4
- package/dist/src/browser.js +9 -9
- package/dist/src/client.cjs +18 -4
- package/dist/src/client.js +3 -3
- package/dist/src/react/index.cjs +18 -4
- package/dist/src/react/index.js +7 -7
- package/dist/src/server/index.cjs +18 -4
- package/dist/src/server/index.js +5 -5
- package/dist/src/telemetry/telemetry.d.ts.map +1 -1
- package/dist/src/version.d.ts +1 -1
- package/dist/{tool-execution-helpers-SAKOUQKI.js → tool-execution-helpers-QJTACMMN.js} +2 -2
- package/package.json +3 -3
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BaseMCPClient,
|
|
3
3
|
HttpConnector
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-ENJHJKXG.js";
|
|
5
5
|
import {
|
|
6
6
|
Tel,
|
|
7
7
|
getPackageVersion
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-J7NQQHWW.js";
|
|
9
9
|
import {
|
|
10
10
|
logger
|
|
11
11
|
} from "./chunk-FRUZDWXH.js";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BrowserMCPClient
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import {
|
|
5
|
-
Tel
|
|
6
|
-
} from "./chunk-2CX2RMGM.js";
|
|
3
|
+
} from "./chunk-5MXNFVMH.js";
|
|
7
4
|
import {
|
|
8
5
|
BrowserOAuthClientProvider,
|
|
9
6
|
sanitizeUrl
|
|
10
7
|
} from "./chunk-J75I2C26.js";
|
|
8
|
+
import {
|
|
9
|
+
Tel
|
|
10
|
+
} from "./chunk-J7NQQHWW.js";
|
|
11
11
|
import {
|
|
12
12
|
__name
|
|
13
13
|
} from "./chunk-3GQAWCBQ.js";
|
|
@@ -92,7 +92,7 @@ function generateUUID() {
|
|
|
92
92
|
__name(generateUUID, "generateUUID");
|
|
93
93
|
|
|
94
94
|
// src/version.ts
|
|
95
|
-
var VERSION = "1.11.0-canary.
|
|
95
|
+
var VERSION = "1.11.0-canary.20";
|
|
96
96
|
function getPackageVersion() {
|
|
97
97
|
return VERSION;
|
|
98
98
|
}
|
|
@@ -479,6 +479,20 @@ function extractModelInfo(llm) {
|
|
|
479
479
|
__name(extractModelInfo, "extractModelInfo");
|
|
480
480
|
|
|
481
481
|
// src/telemetry/telemetry.ts
|
|
482
|
+
function secureRandomString() {
|
|
483
|
+
if (typeof window !== "undefined" && window.crypto && typeof window.crypto.getRandomValues === "function") {
|
|
484
|
+
const array = new Uint8Array(8);
|
|
485
|
+
window.crypto.getRandomValues(array);
|
|
486
|
+
return Array.from(array, (v) => v.toString(16).padStart(2, "0")).join("");
|
|
487
|
+
}
|
|
488
|
+
try {
|
|
489
|
+
const crypto = __require("crypto");
|
|
490
|
+
return crypto.randomBytes(8).toString("hex");
|
|
491
|
+
} catch (e) {
|
|
492
|
+
return Math.random().toString(36).substring(2, 15);
|
|
493
|
+
}
|
|
494
|
+
}
|
|
495
|
+
__name(secureRandomString, "secureRandomString");
|
|
482
496
|
var USER_ID_STORAGE_KEY = "mcp_use_user_id";
|
|
483
497
|
function detectRuntimeEnvironment() {
|
|
484
498
|
try {
|
|
@@ -810,7 +824,7 @@ var Telemetry = class _Telemetry {
|
|
|
810
824
|
try {
|
|
811
825
|
return `session-${generateUUID()}`;
|
|
812
826
|
} catch (uuidError) {
|
|
813
|
-
return `session-${Date.now()}-${
|
|
827
|
+
return `session-${Date.now()}-${secureRandomString()}`;
|
|
814
828
|
}
|
|
815
829
|
}
|
|
816
830
|
}
|
|
@@ -824,7 +838,7 @@ var Telemetry = class _Telemetry {
|
|
|
824
838
|
try {
|
|
825
839
|
userId = generateUUID();
|
|
826
840
|
} catch (uuidError) {
|
|
827
|
-
userId = `${Date.now()}-${
|
|
841
|
+
userId = `${Date.now()}-${secureRandomString()}`;
|
|
828
842
|
}
|
|
829
843
|
localStorage.setItem(USER_ID_STORAGE_KEY, userId);
|
|
830
844
|
}
|
|
@@ -834,7 +848,7 @@ var Telemetry = class _Telemetry {
|
|
|
834
848
|
try {
|
|
835
849
|
sessionId = `session-${generateUUID()}`;
|
|
836
850
|
} catch (uuidError) {
|
|
837
|
-
sessionId = `session-${Date.now()}-${
|
|
851
|
+
sessionId = `session-${Date.now()}-${secureRandomString()}`;
|
|
838
852
|
}
|
|
839
853
|
return sessionId;
|
|
840
854
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
MCPClient
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-SP22S3FF.js";
|
|
4
4
|
import {
|
|
5
5
|
LangChainAdapter
|
|
6
6
|
} from "./chunk-MFSO5PUW.js";
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
Telemetry,
|
|
9
9
|
extractModelInfo,
|
|
10
10
|
getPackageVersion
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-J7NQQHWW.js";
|
|
12
12
|
import {
|
|
13
13
|
logger
|
|
14
14
|
} from "./chunk-FRUZDWXH.js";
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
ConnectionManager,
|
|
5
5
|
HttpConnector,
|
|
6
6
|
MCPSession
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-ENJHJKXG.js";
|
|
8
8
|
import {
|
|
9
9
|
Tel,
|
|
10
10
|
getPackageVersion
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-J7NQQHWW.js";
|
|
12
12
|
import {
|
|
13
13
|
logger
|
|
14
14
|
} from "./chunk-FRUZDWXH.js";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BrowserMCPClient
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-5MXNFVMH.js";
|
|
4
|
+
import {
|
|
5
|
+
Tel
|
|
6
|
+
} from "./chunk-J7NQQHWW.js";
|
|
4
7
|
import {
|
|
5
8
|
BrowserOAuthClientProvider,
|
|
6
9
|
sanitizeUrl
|
|
7
10
|
} from "./chunk-J75I2C26.js";
|
|
8
|
-
import {
|
|
9
|
-
Tel
|
|
10
|
-
} from "./chunk-2CX2RMGM.js";
|
|
11
11
|
import {
|
|
12
12
|
__name
|
|
13
13
|
} from "./chunk-3GQAWCBQ.js";
|
package/dist/index.cjs
CHANGED
|
@@ -2790,7 +2790,7 @@ __name(generateUUID, "generateUUID");
|
|
|
2790
2790
|
init_logging();
|
|
2791
2791
|
|
|
2792
2792
|
// src/version.ts
|
|
2793
|
-
var VERSION = "1.11.0-canary.
|
|
2793
|
+
var VERSION = "1.11.0-canary.20";
|
|
2794
2794
|
function getPackageVersion() {
|
|
2795
2795
|
return VERSION;
|
|
2796
2796
|
}
|
|
@@ -2829,6 +2829,20 @@ function extractModelInfo(llm) {
|
|
|
2829
2829
|
__name(extractModelInfo, "extractModelInfo");
|
|
2830
2830
|
|
|
2831
2831
|
// src/telemetry/telemetry.ts
|
|
2832
|
+
function secureRandomString() {
|
|
2833
|
+
if (typeof window !== "undefined" && window.crypto && typeof window.crypto.getRandomValues === "function") {
|
|
2834
|
+
const array = new Uint8Array(8);
|
|
2835
|
+
window.crypto.getRandomValues(array);
|
|
2836
|
+
return Array.from(array, (v) => v.toString(16).padStart(2, "0")).join("");
|
|
2837
|
+
}
|
|
2838
|
+
try {
|
|
2839
|
+
const crypto = require("crypto");
|
|
2840
|
+
return crypto.randomBytes(8).toString("hex");
|
|
2841
|
+
} catch (e) {
|
|
2842
|
+
return Math.random().toString(36).substring(2, 15);
|
|
2843
|
+
}
|
|
2844
|
+
}
|
|
2845
|
+
__name(secureRandomString, "secureRandomString");
|
|
2832
2846
|
var USER_ID_STORAGE_KEY = "mcp_use_user_id";
|
|
2833
2847
|
function detectRuntimeEnvironment() {
|
|
2834
2848
|
try {
|
|
@@ -3160,7 +3174,7 @@ var Telemetry = class _Telemetry {
|
|
|
3160
3174
|
try {
|
|
3161
3175
|
return `session-${generateUUID()}`;
|
|
3162
3176
|
} catch (uuidError) {
|
|
3163
|
-
return `session-${Date.now()}-${
|
|
3177
|
+
return `session-${Date.now()}-${secureRandomString()}`;
|
|
3164
3178
|
}
|
|
3165
3179
|
}
|
|
3166
3180
|
}
|
|
@@ -3174,7 +3188,7 @@ var Telemetry = class _Telemetry {
|
|
|
3174
3188
|
try {
|
|
3175
3189
|
userId = generateUUID();
|
|
3176
3190
|
} catch (uuidError) {
|
|
3177
|
-
userId = `${Date.now()}-${
|
|
3191
|
+
userId = `${Date.now()}-${secureRandomString()}`;
|
|
3178
3192
|
}
|
|
3179
3193
|
localStorage.setItem(USER_ID_STORAGE_KEY, userId);
|
|
3180
3194
|
}
|
|
@@ -3184,7 +3198,7 @@ var Telemetry = class _Telemetry {
|
|
|
3184
3198
|
try {
|
|
3185
3199
|
sessionId = `session-${generateUUID()}`;
|
|
3186
3200
|
} catch (uuidError) {
|
|
3187
|
-
sessionId = `session-${Date.now()}-${
|
|
3201
|
+
sessionId = `session-${Date.now()}-${secureRandomString()}`;
|
|
3188
3202
|
}
|
|
3189
3203
|
return sessionId;
|
|
3190
3204
|
}
|
package/dist/index.js
CHANGED
|
@@ -9,10 +9,9 @@ import {
|
|
|
9
9
|
streamEventsToAISDKWithTools
|
|
10
10
|
} from "./chunk-LGDFGYRL.js";
|
|
11
11
|
import "./chunk-GXNAXUDI.js";
|
|
12
|
-
import "./chunk-JQKKMUCT.js";
|
|
13
12
|
import {
|
|
14
13
|
PROMPTS
|
|
15
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-TA74PN4A.js";
|
|
16
15
|
import {
|
|
17
16
|
AcquireActiveMCPServerTool,
|
|
18
17
|
AddMCPServerFromConfigTool,
|
|
@@ -27,7 +26,7 @@ import {
|
|
|
27
26
|
getSupportedProviders,
|
|
28
27
|
isValidLLMString,
|
|
29
28
|
parseLLMString
|
|
30
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-RSC4XIGS.js";
|
|
31
30
|
import "./chunk-JRGQRPTN.js";
|
|
32
31
|
import {
|
|
33
32
|
BaseCodeExecutor,
|
|
@@ -37,10 +36,11 @@ import {
|
|
|
37
36
|
VMCodeExecutor,
|
|
38
37
|
isVMAvailable,
|
|
39
38
|
loadConfigFile
|
|
40
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-SP22S3FF.js";
|
|
41
40
|
import {
|
|
42
41
|
BaseAdapter
|
|
43
42
|
} from "./chunk-MFSO5PUW.js";
|
|
43
|
+
import "./chunk-JQKKMUCT.js";
|
|
44
44
|
import {
|
|
45
45
|
ErrorBoundary,
|
|
46
46
|
Image,
|
|
@@ -52,28 +52,28 @@ import {
|
|
|
52
52
|
useWidgetProps,
|
|
53
53
|
useWidgetState,
|
|
54
54
|
useWidgetTheme
|
|
55
|
-
} from "./chunk-
|
|
56
|
-
import "./chunk-
|
|
57
|
-
import {
|
|
58
|
-
BrowserOAuthClientProvider,
|
|
59
|
-
onMcpAuthorization
|
|
60
|
-
} from "./chunk-J75I2C26.js";
|
|
55
|
+
} from "./chunk-YCXBIMRG.js";
|
|
56
|
+
import "./chunk-5MXNFVMH.js";
|
|
61
57
|
import {
|
|
62
58
|
BaseConnector,
|
|
63
59
|
HttpConnector,
|
|
64
60
|
MCPSession
|
|
65
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-ENJHJKXG.js";
|
|
66
62
|
import {
|
|
67
63
|
Tel,
|
|
68
64
|
Telemetry,
|
|
69
65
|
VERSION,
|
|
70
66
|
getPackageVersion,
|
|
71
67
|
setTelemetrySource
|
|
72
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-J7NQQHWW.js";
|
|
73
69
|
import {
|
|
74
70
|
Logger,
|
|
75
71
|
logger
|
|
76
72
|
} from "./chunk-FRUZDWXH.js";
|
|
73
|
+
import {
|
|
74
|
+
BrowserOAuthClientProvider,
|
|
75
|
+
onMcpAuthorization
|
|
76
|
+
} from "./chunk-J75I2C26.js";
|
|
77
77
|
import {
|
|
78
78
|
__name
|
|
79
79
|
} from "./chunk-3GQAWCBQ.js";
|
|
@@ -1417,7 +1417,7 @@ __name(generateUUID, "generateUUID");
|
|
|
1417
1417
|
init_logging();
|
|
1418
1418
|
|
|
1419
1419
|
// src/version.ts
|
|
1420
|
-
var VERSION = "1.11.0-canary.
|
|
1420
|
+
var VERSION = "1.11.0-canary.20";
|
|
1421
1421
|
function getPackageVersion() {
|
|
1422
1422
|
return VERSION;
|
|
1423
1423
|
}
|
|
@@ -1456,6 +1456,20 @@ function extractModelInfo(llm) {
|
|
|
1456
1456
|
__name(extractModelInfo, "extractModelInfo");
|
|
1457
1457
|
|
|
1458
1458
|
// src/telemetry/telemetry.ts
|
|
1459
|
+
function secureRandomString() {
|
|
1460
|
+
if (typeof window !== "undefined" && window.crypto && typeof window.crypto.getRandomValues === "function") {
|
|
1461
|
+
const array = new Uint8Array(8);
|
|
1462
|
+
window.crypto.getRandomValues(array);
|
|
1463
|
+
return Array.from(array, (v) => v.toString(16).padStart(2, "0")).join("");
|
|
1464
|
+
}
|
|
1465
|
+
try {
|
|
1466
|
+
const crypto = require("crypto");
|
|
1467
|
+
return crypto.randomBytes(8).toString("hex");
|
|
1468
|
+
} catch (e) {
|
|
1469
|
+
return Math.random().toString(36).substring(2, 15);
|
|
1470
|
+
}
|
|
1471
|
+
}
|
|
1472
|
+
__name(secureRandomString, "secureRandomString");
|
|
1459
1473
|
var USER_ID_STORAGE_KEY = "mcp_use_user_id";
|
|
1460
1474
|
function detectRuntimeEnvironment() {
|
|
1461
1475
|
try {
|
|
@@ -1787,7 +1801,7 @@ var Telemetry = class _Telemetry {
|
|
|
1787
1801
|
try {
|
|
1788
1802
|
return `session-${generateUUID()}`;
|
|
1789
1803
|
} catch (uuidError) {
|
|
1790
|
-
return `session-${Date.now()}-${
|
|
1804
|
+
return `session-${Date.now()}-${secureRandomString()}`;
|
|
1791
1805
|
}
|
|
1792
1806
|
}
|
|
1793
1807
|
}
|
|
@@ -1801,7 +1815,7 @@ var Telemetry = class _Telemetry {
|
|
|
1801
1815
|
try {
|
|
1802
1816
|
userId = generateUUID();
|
|
1803
1817
|
} catch (uuidError) {
|
|
1804
|
-
userId = `${Date.now()}-${
|
|
1818
|
+
userId = `${Date.now()}-${secureRandomString()}`;
|
|
1805
1819
|
}
|
|
1806
1820
|
localStorage.setItem(USER_ID_STORAGE_KEY, userId);
|
|
1807
1821
|
}
|
|
@@ -1811,7 +1825,7 @@ var Telemetry = class _Telemetry {
|
|
|
1811
1825
|
try {
|
|
1812
1826
|
sessionId = `session-${generateUUID()}`;
|
|
1813
1827
|
} catch (uuidError) {
|
|
1814
|
-
sessionId = `session-${Date.now()}-${
|
|
1828
|
+
sessionId = `session-${Date.now()}-${secureRandomString()}`;
|
|
1815
1829
|
}
|
|
1816
1830
|
return sessionId;
|
|
1817
1831
|
}
|
package/dist/src/agents/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
BaseAgent,
|
|
3
3
|
PROMPTS
|
|
4
|
-
} from "../../chunk-
|
|
4
|
+
} from "../../chunk-TA74PN4A.js";
|
|
5
5
|
import {
|
|
6
6
|
MCPAgent,
|
|
7
7
|
RemoteAgent
|
|
8
|
-
} from "../../chunk-
|
|
8
|
+
} from "../../chunk-RSC4XIGS.js";
|
|
9
9
|
import "../../chunk-JRGQRPTN.js";
|
|
10
|
-
import "../../chunk-
|
|
10
|
+
import "../../chunk-SP22S3FF.js";
|
|
11
11
|
import "../../chunk-MFSO5PUW.js";
|
|
12
|
-
import "../../chunk-
|
|
13
|
-
import "../../chunk-
|
|
12
|
+
import "../../chunk-ENJHJKXG.js";
|
|
13
|
+
import "../../chunk-J7NQQHWW.js";
|
|
14
14
|
import "../../chunk-FRUZDWXH.js";
|
|
15
15
|
import "../../chunk-3GQAWCBQ.js";
|
|
16
16
|
export {
|
package/dist/src/browser.cjs
CHANGED
|
@@ -1651,7 +1651,7 @@ __name(generateUUID, "generateUUID");
|
|
|
1651
1651
|
init_logging();
|
|
1652
1652
|
|
|
1653
1653
|
// src/version.ts
|
|
1654
|
-
var VERSION = "1.11.0-canary.
|
|
1654
|
+
var VERSION = "1.11.0-canary.20";
|
|
1655
1655
|
function getPackageVersion() {
|
|
1656
1656
|
return VERSION;
|
|
1657
1657
|
}
|
|
@@ -1690,6 +1690,20 @@ function extractModelInfo(llm) {
|
|
|
1690
1690
|
__name(extractModelInfo, "extractModelInfo");
|
|
1691
1691
|
|
|
1692
1692
|
// src/telemetry/telemetry.ts
|
|
1693
|
+
function secureRandomString() {
|
|
1694
|
+
if (typeof window !== "undefined" && window.crypto && typeof window.crypto.getRandomValues === "function") {
|
|
1695
|
+
const array = new Uint8Array(8);
|
|
1696
|
+
window.crypto.getRandomValues(array);
|
|
1697
|
+
return Array.from(array, (v) => v.toString(16).padStart(2, "0")).join("");
|
|
1698
|
+
}
|
|
1699
|
+
try {
|
|
1700
|
+
const crypto = require("crypto");
|
|
1701
|
+
return crypto.randomBytes(8).toString("hex");
|
|
1702
|
+
} catch (e) {
|
|
1703
|
+
return Math.random().toString(36).substring(2, 15);
|
|
1704
|
+
}
|
|
1705
|
+
}
|
|
1706
|
+
__name(secureRandomString, "secureRandomString");
|
|
1693
1707
|
var USER_ID_STORAGE_KEY = "mcp_use_user_id";
|
|
1694
1708
|
function detectRuntimeEnvironment() {
|
|
1695
1709
|
try {
|
|
@@ -2021,7 +2035,7 @@ var Telemetry = class _Telemetry {
|
|
|
2021
2035
|
try {
|
|
2022
2036
|
return `session-${generateUUID()}`;
|
|
2023
2037
|
} catch (uuidError) {
|
|
2024
|
-
return `session-${Date.now()}-${
|
|
2038
|
+
return `session-${Date.now()}-${secureRandomString()}`;
|
|
2025
2039
|
}
|
|
2026
2040
|
}
|
|
2027
2041
|
}
|
|
@@ -2035,7 +2049,7 @@ var Telemetry = class _Telemetry {
|
|
|
2035
2049
|
try {
|
|
2036
2050
|
userId = generateUUID();
|
|
2037
2051
|
} catch (uuidError) {
|
|
2038
|
-
userId = `${Date.now()}-${
|
|
2052
|
+
userId = `${Date.now()}-${secureRandomString()}`;
|
|
2039
2053
|
}
|
|
2040
2054
|
localStorage.setItem(USER_ID_STORAGE_KEY, userId);
|
|
2041
2055
|
}
|
|
@@ -2045,7 +2059,7 @@ var Telemetry = class _Telemetry {
|
|
|
2045
2059
|
try {
|
|
2046
2060
|
sessionId = `session-${generateUUID()}`;
|
|
2047
2061
|
} catch (uuidError) {
|
|
2048
|
-
sessionId = `session-${Date.now()}-${
|
|
2062
|
+
sessionId = `session-${Date.now()}-${secureRandomString()}`;
|
|
2049
2063
|
}
|
|
2050
2064
|
return sessionId;
|
|
2051
2065
|
}
|
package/dist/src/browser.js
CHANGED
|
@@ -12,35 +12,35 @@ import {
|
|
|
12
12
|
getSupportedProviders,
|
|
13
13
|
isValidLLMString,
|
|
14
14
|
parseLLMString
|
|
15
|
-
} from "../chunk-
|
|
15
|
+
} from "../chunk-RSC4XIGS.js";
|
|
16
16
|
import "../chunk-JRGQRPTN.js";
|
|
17
|
-
import "../chunk-
|
|
17
|
+
import "../chunk-SP22S3FF.js";
|
|
18
18
|
import {
|
|
19
19
|
BaseAdapter
|
|
20
20
|
} from "../chunk-MFSO5PUW.js";
|
|
21
21
|
import {
|
|
22
22
|
BrowserMCPClient
|
|
23
|
-
} from "../chunk-
|
|
24
|
-
import {
|
|
25
|
-
BrowserOAuthClientProvider,
|
|
26
|
-
onMcpAuthorization
|
|
27
|
-
} from "../chunk-J75I2C26.js";
|
|
23
|
+
} from "../chunk-5MXNFVMH.js";
|
|
28
24
|
import {
|
|
29
25
|
BaseConnector,
|
|
30
26
|
HttpConnector,
|
|
31
27
|
MCPSession
|
|
32
|
-
} from "../chunk-
|
|
28
|
+
} from "../chunk-ENJHJKXG.js";
|
|
33
29
|
import {
|
|
34
30
|
Tel,
|
|
35
31
|
Telemetry,
|
|
36
32
|
VERSION,
|
|
37
33
|
getPackageVersion,
|
|
38
34
|
setTelemetrySource
|
|
39
|
-
} from "../chunk-
|
|
35
|
+
} from "../chunk-J7NQQHWW.js";
|
|
40
36
|
import {
|
|
41
37
|
Logger,
|
|
42
38
|
logger
|
|
43
39
|
} from "../chunk-FRUZDWXH.js";
|
|
40
|
+
import {
|
|
41
|
+
BrowserOAuthClientProvider,
|
|
42
|
+
onMcpAuthorization
|
|
43
|
+
} from "../chunk-J75I2C26.js";
|
|
44
44
|
import "../chunk-3GQAWCBQ.js";
|
|
45
45
|
export {
|
|
46
46
|
BaseAdapter,
|
package/dist/src/client.cjs
CHANGED
|
@@ -942,13 +942,27 @@ function generateUUID() {
|
|
|
942
942
|
__name(generateUUID, "generateUUID");
|
|
943
943
|
|
|
944
944
|
// src/version.ts
|
|
945
|
-
var VERSION = "1.11.0-canary.
|
|
945
|
+
var VERSION = "1.11.0-canary.20";
|
|
946
946
|
function getPackageVersion() {
|
|
947
947
|
return VERSION;
|
|
948
948
|
}
|
|
949
949
|
__name(getPackageVersion, "getPackageVersion");
|
|
950
950
|
|
|
951
951
|
// src/telemetry/telemetry.ts
|
|
952
|
+
function secureRandomString() {
|
|
953
|
+
if (typeof window !== "undefined" && window.crypto && typeof window.crypto.getRandomValues === "function") {
|
|
954
|
+
const array = new Uint8Array(8);
|
|
955
|
+
window.crypto.getRandomValues(array);
|
|
956
|
+
return Array.from(array, (v) => v.toString(16).padStart(2, "0")).join("");
|
|
957
|
+
}
|
|
958
|
+
try {
|
|
959
|
+
const crypto = require("crypto");
|
|
960
|
+
return crypto.randomBytes(8).toString("hex");
|
|
961
|
+
} catch (e) {
|
|
962
|
+
return Math.random().toString(36).substring(2, 15);
|
|
963
|
+
}
|
|
964
|
+
}
|
|
965
|
+
__name(secureRandomString, "secureRandomString");
|
|
952
966
|
var USER_ID_STORAGE_KEY = "mcp_use_user_id";
|
|
953
967
|
function detectRuntimeEnvironment() {
|
|
954
968
|
try {
|
|
@@ -1280,7 +1294,7 @@ var Telemetry = class _Telemetry {
|
|
|
1280
1294
|
try {
|
|
1281
1295
|
return `session-${generateUUID()}`;
|
|
1282
1296
|
} catch (uuidError) {
|
|
1283
|
-
return `session-${Date.now()}-${
|
|
1297
|
+
return `session-${Date.now()}-${secureRandomString()}`;
|
|
1284
1298
|
}
|
|
1285
1299
|
}
|
|
1286
1300
|
}
|
|
@@ -1294,7 +1308,7 @@ var Telemetry = class _Telemetry {
|
|
|
1294
1308
|
try {
|
|
1295
1309
|
userId = generateUUID();
|
|
1296
1310
|
} catch (uuidError) {
|
|
1297
|
-
userId = `${Date.now()}-${
|
|
1311
|
+
userId = `${Date.now()}-${secureRandomString()}`;
|
|
1298
1312
|
}
|
|
1299
1313
|
localStorage.setItem(USER_ID_STORAGE_KEY, userId);
|
|
1300
1314
|
}
|
|
@@ -1304,7 +1318,7 @@ var Telemetry = class _Telemetry {
|
|
|
1304
1318
|
try {
|
|
1305
1319
|
sessionId = `session-${generateUUID()}`;
|
|
1306
1320
|
} catch (uuidError) {
|
|
1307
|
-
sessionId = `session-${Date.now()}-${
|
|
1321
|
+
sessionId = `session-${Date.now()}-${secureRandomString()}`;
|
|
1308
1322
|
}
|
|
1309
1323
|
return sessionId;
|
|
1310
1324
|
}
|
package/dist/src/client.js
CHANGED
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
MCPClient,
|
|
5
5
|
VMCodeExecutor,
|
|
6
6
|
isVMAvailable
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-SP22S3FF.js";
|
|
8
8
|
import {
|
|
9
9
|
MCPSession
|
|
10
|
-
} from "../chunk-
|
|
11
|
-
import "../chunk-
|
|
10
|
+
} from "../chunk-ENJHJKXG.js";
|
|
11
|
+
import "../chunk-J7NQQHWW.js";
|
|
12
12
|
import "../chunk-FRUZDWXH.js";
|
|
13
13
|
import "../chunk-3GQAWCBQ.js";
|
|
14
14
|
export {
|
package/dist/src/react/index.cjs
CHANGED
|
@@ -918,13 +918,27 @@ function generateUUID() {
|
|
|
918
918
|
__name(generateUUID, "generateUUID");
|
|
919
919
|
|
|
920
920
|
// src/version.ts
|
|
921
|
-
var VERSION = "1.11.0-canary.
|
|
921
|
+
var VERSION = "1.11.0-canary.20";
|
|
922
922
|
function getPackageVersion() {
|
|
923
923
|
return VERSION;
|
|
924
924
|
}
|
|
925
925
|
__name(getPackageVersion, "getPackageVersion");
|
|
926
926
|
|
|
927
927
|
// src/telemetry/telemetry.ts
|
|
928
|
+
function secureRandomString() {
|
|
929
|
+
if (typeof window !== "undefined" && window.crypto && typeof window.crypto.getRandomValues === "function") {
|
|
930
|
+
const array = new Uint8Array(8);
|
|
931
|
+
window.crypto.getRandomValues(array);
|
|
932
|
+
return Array.from(array, (v) => v.toString(16).padStart(2, "0")).join("");
|
|
933
|
+
}
|
|
934
|
+
try {
|
|
935
|
+
const crypto = require("crypto");
|
|
936
|
+
return crypto.randomBytes(8).toString("hex");
|
|
937
|
+
} catch (e) {
|
|
938
|
+
return Math.random().toString(36).substring(2, 15);
|
|
939
|
+
}
|
|
940
|
+
}
|
|
941
|
+
__name(secureRandomString, "secureRandomString");
|
|
928
942
|
var USER_ID_STORAGE_KEY = "mcp_use_user_id";
|
|
929
943
|
function detectRuntimeEnvironment() {
|
|
930
944
|
try {
|
|
@@ -1256,7 +1270,7 @@ var Telemetry = class _Telemetry {
|
|
|
1256
1270
|
try {
|
|
1257
1271
|
return `session-${generateUUID()}`;
|
|
1258
1272
|
} catch (uuidError) {
|
|
1259
|
-
return `session-${Date.now()}-${
|
|
1273
|
+
return `session-${Date.now()}-${secureRandomString()}`;
|
|
1260
1274
|
}
|
|
1261
1275
|
}
|
|
1262
1276
|
}
|
|
@@ -1270,7 +1284,7 @@ var Telemetry = class _Telemetry {
|
|
|
1270
1284
|
try {
|
|
1271
1285
|
userId = generateUUID();
|
|
1272
1286
|
} catch (uuidError) {
|
|
1273
|
-
userId = `${Date.now()}-${
|
|
1287
|
+
userId = `${Date.now()}-${secureRandomString()}`;
|
|
1274
1288
|
}
|
|
1275
1289
|
localStorage.setItem(USER_ID_STORAGE_KEY, userId);
|
|
1276
1290
|
}
|
|
@@ -1280,7 +1294,7 @@ var Telemetry = class _Telemetry {
|
|
|
1280
1294
|
try {
|
|
1281
1295
|
sessionId = `session-${generateUUID()}`;
|
|
1282
1296
|
} catch (uuidError) {
|
|
1283
|
-
sessionId = `session-${Date.now()}-${
|
|
1297
|
+
sessionId = `session-${Date.now()}-${secureRandomString()}`;
|
|
1284
1298
|
}
|
|
1285
1299
|
return sessionId;
|
|
1286
1300
|
}
|
package/dist/src/react/index.js
CHANGED
|
@@ -9,18 +9,18 @@ import {
|
|
|
9
9
|
useWidgetProps,
|
|
10
10
|
useWidgetState,
|
|
11
11
|
useWidgetTheme
|
|
12
|
-
} from "../../chunk-
|
|
13
|
-
import "../../chunk-
|
|
14
|
-
import
|
|
15
|
-
onMcpAuthorization
|
|
16
|
-
} from "../../chunk-J75I2C26.js";
|
|
17
|
-
import "../../chunk-5QAH2BZN.js";
|
|
12
|
+
} from "../../chunk-YCXBIMRG.js";
|
|
13
|
+
import "../../chunk-5MXNFVMH.js";
|
|
14
|
+
import "../../chunk-ENJHJKXG.js";
|
|
18
15
|
import {
|
|
19
16
|
Tel,
|
|
20
17
|
Telemetry,
|
|
21
18
|
setTelemetrySource
|
|
22
|
-
} from "../../chunk-
|
|
19
|
+
} from "../../chunk-J7NQQHWW.js";
|
|
23
20
|
import "../../chunk-FRUZDWXH.js";
|
|
21
|
+
import {
|
|
22
|
+
onMcpAuthorization
|
|
23
|
+
} from "../../chunk-J75I2C26.js";
|
|
24
24
|
import "../../chunk-3GQAWCBQ.js";
|
|
25
25
|
export {
|
|
26
26
|
Tel as BrowserTelemetry,
|