@mcp-use/client 2.4.5-canary.0 → 2.4.5-canary.1
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/auth/session-store.d.ts.map +1 -1
- package/dist/index-browser.js +6 -2
- package/dist/index-browser.js.map +1 -1
- package/dist/index.js +6 -2
- package/dist/index.js.map +1 -1
- package/dist/react/index.js +9 -2
- package/dist/react/index.js.map +1 -1
- package/dist/react/token-expiry.d.ts +3 -1
- package/dist/react/token-expiry.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1659,7 +1659,7 @@ init_connector_telemetry();
|
|
|
1659
1659
|
init_logging();
|
|
1660
1660
|
|
|
1661
1661
|
// src/utils/version.ts
|
|
1662
|
-
var VERSION = "2.4.5-canary.
|
|
1662
|
+
var VERSION = "2.4.5-canary.1";
|
|
1663
1663
|
function getPackageVersion() {
|
|
1664
1664
|
return VERSION;
|
|
1665
1665
|
}
|
|
@@ -2438,7 +2438,11 @@ var OAuthSessionStore = class _OAuthSessionStore {
|
|
|
2438
2438
|
return (await this.readCredential("tokens", ctx))?.value;
|
|
2439
2439
|
}
|
|
2440
2440
|
async saveTokens(tokens, ctx) {
|
|
2441
|
-
const
|
|
2441
|
+
const stored = typeof tokens.expires_in === "number" ? {
|
|
2442
|
+
...tokens,
|
|
2443
|
+
mcp_use_expires_at: Date.now() + tokens.expires_in * 1e3
|
|
2444
|
+
} : tokens;
|
|
2445
|
+
const serialized = JSON.stringify(stored);
|
|
2442
2446
|
await this.store.set(this.credentialKey("tokens", ctx), serialized);
|
|
2443
2447
|
if (ctx) await this.store.set(this.credentialKey("tokens"), serialized);
|
|
2444
2448
|
await this.store.remove(this.getKey("code_verifier"));
|