modality-ai 0.5.1 → 0.5.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/dist/index.js +34491 -34772
- package/dist/types/index.d.ts +1 -1
- package/dist/types/mcp-oauth-provider.d.ts +4 -9
- package/package.json +3 -3
package/dist/types/index.d.ts
CHANGED
|
@@ -3,4 +3,4 @@ export { ModalityClient } from "./ModalityClient";
|
|
|
3
3
|
export { setupStdioToHttpTools, createStdioClient, } from "./setupStdioToHttpTools";
|
|
4
4
|
export type { ModalityClientInstance } from "./ModalityClient";
|
|
5
5
|
export type { StdioClientOptions } from "./setupStdioToHttpTools";
|
|
6
|
-
export { CLIBrowserOAuthProvider
|
|
6
|
+
export { CLIBrowserOAuthProvider } from "./mcp-oauth-provider";
|
|
@@ -22,14 +22,11 @@ interface CLIBrowserOAuthProviderOptions {
|
|
|
22
22
|
*/
|
|
23
23
|
noOpen?: boolean;
|
|
24
24
|
/**
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
* own cache entry and re-runs skip dynamic registration entirely.
|
|
28
|
-
*
|
|
29
|
-
* Pass an explicit string (e.g. "figma") for a human-readable cache name.
|
|
25
|
+
* MCP server URL used to derive a unique cache key via urlStorageKey().
|
|
26
|
+
* Each server gets its own cache entry so re-runs skip dynamic registration.
|
|
30
27
|
* Pass null to disable persistence entirely.
|
|
31
28
|
*/
|
|
32
|
-
|
|
29
|
+
serverUrl?: string | null;
|
|
33
30
|
}
|
|
34
31
|
/**
|
|
35
32
|
* OAuthClientProvider for CLI tools.
|
|
@@ -42,7 +39,7 @@ interface CLIBrowserOAuthProviderOptions {
|
|
|
42
39
|
* and the browser prompt (until the token expires).
|
|
43
40
|
*
|
|
44
41
|
* Usage:
|
|
45
|
-
* const provider = new CLIBrowserOAuthProvider({ clientName: "my-cli",
|
|
42
|
+
* const provider = new CLIBrowserOAuthProvider({ clientName: "my-cli", serverUrl: "https://mcp.figma.com/mcp" });
|
|
46
43
|
* const transport = new StreamableHTTPClientTransport(url, { authProvider: provider });
|
|
47
44
|
* const client = new Client(...);
|
|
48
45
|
*
|
|
@@ -97,6 +94,4 @@ export declare class CLIBrowserOAuthProvider implements OAuthClientProvider {
|
|
|
97
94
|
private _persistCache;
|
|
98
95
|
private _handleCallback;
|
|
99
96
|
}
|
|
100
|
-
/** Short stable hash of a string — used to derive a cache file name from a URL. */
|
|
101
|
-
export declare function urlStorageKey(url: string): string;
|
|
102
97
|
export {};
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.5.
|
|
2
|
+
"version": "0.5.3",
|
|
3
3
|
"name": "modality-ai",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
18
|
"@ai-sdk/google": "^3.0.53",
|
|
19
|
-
"ai": "^6.0.
|
|
19
|
+
"ai": "^6.0.141",
|
|
20
20
|
"ollama-ai-provider": "^1.2.0"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"scripts": {
|
|
36
36
|
"build:clean": "find ./dist -name '*.*' | xargs rm -rf",
|
|
37
37
|
"build:types": "bun tsc -p ./",
|
|
38
|
-
"build:src": "bun build src/index.ts --outdir dist --external @modelcontextprotocol/sdk",
|
|
38
|
+
"build:src": "bun build src/index.ts --outdir dist --target node --external @modelcontextprotocol/sdk",
|
|
39
39
|
"build": "bun run build:clean && bun run build:types && bun run build:src",
|
|
40
40
|
"dev": "bunx concurrently 'bun --watch tsc -p ./' 'bun build:src -- --watch --sourcemap=inline'",
|
|
41
41
|
"test": "npm run build && bun test",
|