@pragmatic-growth/memory-mcp 2.2.0 → 2.4.0
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/.npmrc.backup +2 -0
- package/README.md +7 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.js +12 -6
- package/package.json +2 -2
- package/src/index.ts +12 -6
package/.npmrc.backup
ADDED
package/README.md
CHANGED
|
@@ -191,7 +191,13 @@ For full mode to work:
|
|
|
191
191
|
|
|
192
192
|
## Changelog
|
|
193
193
|
|
|
194
|
-
### v2.
|
|
194
|
+
### v2.4.0 (Latest)
|
|
195
|
+
- Changed default server URL to custom domain: `https://memory.pragmaticgrowth.com/api/mcp`
|
|
196
|
+
- Simplified authentication to API key only (removed OAuth infrastructure)
|
|
197
|
+
- Updated dependencies to latest versions
|
|
198
|
+
- Improved error messages and documentation
|
|
199
|
+
|
|
200
|
+
### v2.3.0
|
|
195
201
|
- Added unified `get_content` and `list_content` tools (replacing `get_article`/`list_articles`)
|
|
196
202
|
- Added Knowledge Graph tools: `find_related`, `get_entities`, `search_entities`, `get_knowledge_graph`
|
|
197
203
|
- Added Episodic Memory tools: `start_conversation`, `add_message`, `get_conversation`, `list_conversations`, `get_session_context`
|
package/dist/index.d.ts
CHANGED
|
@@ -11,8 +11,12 @@
|
|
|
11
11
|
* npx @pragmatic-growth/memory-mcp --edit # Alias for --full
|
|
12
12
|
*
|
|
13
13
|
* Environment variables:
|
|
14
|
-
* MCP_API_KEY - API key for authentication (required)
|
|
14
|
+
* MCP_API_KEY - Clerk API key for authentication (required)
|
|
15
15
|
* MCP_SERVER_URL - Server URL (default: https://pg-memory-production.up.railway.app/api/mcp)
|
|
16
16
|
* MCP_MODE - Mode: 'readonly' (default) or 'full' for edit capabilities
|
|
17
|
+
*
|
|
18
|
+
* Authentication:
|
|
19
|
+
* Uses Clerk API key authentication via X-API-Key header.
|
|
20
|
+
* Get your API key from the Clerk Dashboard or the app's API Docs page.
|
|
17
21
|
*/
|
|
18
22
|
export {};
|
package/dist/index.js
CHANGED
|
@@ -11,9 +11,13 @@
|
|
|
11
11
|
* npx @pragmatic-growth/memory-mcp --edit # Alias for --full
|
|
12
12
|
*
|
|
13
13
|
* Environment variables:
|
|
14
|
-
* MCP_API_KEY - API key for authentication (required)
|
|
14
|
+
* MCP_API_KEY - Clerk API key for authentication (required)
|
|
15
15
|
* MCP_SERVER_URL - Server URL (default: https://pg-memory-production.up.railway.app/api/mcp)
|
|
16
16
|
* MCP_MODE - Mode: 'readonly' (default) or 'full' for edit capabilities
|
|
17
|
+
*
|
|
18
|
+
* Authentication:
|
|
19
|
+
* Uses Clerk API key authentication via X-API-Key header.
|
|
20
|
+
* Get your API key from the Clerk Dashboard or the app's API Docs page.
|
|
17
21
|
*/
|
|
18
22
|
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
19
23
|
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
|
|
@@ -24,22 +28,24 @@ const hasFullFlag = args.includes('--full') || args.includes('--edit');
|
|
|
24
28
|
const envMode = process.env.MCP_MODE?.toLowerCase();
|
|
25
29
|
const isFullMode = hasFullFlag || envMode === 'full' || envMode === 'edit';
|
|
26
30
|
// Configuration
|
|
27
|
-
const SERVER_URL = process.env.MCP_SERVER_URL || 'https://
|
|
31
|
+
const SERVER_URL = process.env.MCP_SERVER_URL || 'https://memory.pragmaticgrowth.com/api/mcp';
|
|
28
32
|
const API_KEY = process.env.MCP_API_KEY;
|
|
29
33
|
if (!API_KEY) {
|
|
30
34
|
console.error('Error: MCP_API_KEY environment variable is required');
|
|
31
|
-
console.error('
|
|
35
|
+
console.error('Get your Clerk API key from the Clerk Dashboard or app API Docs page');
|
|
36
|
+
console.error('Set it in your MCP client configuration under "env"');
|
|
32
37
|
process.exit(1);
|
|
33
38
|
}
|
|
34
39
|
// HTTP session management
|
|
35
40
|
let sessionId = null;
|
|
36
41
|
/**
|
|
37
42
|
* Make an HTTP request to the remote MCP server.
|
|
43
|
+
* Uses X-API-Key header for Clerk API key authentication.
|
|
38
44
|
*/
|
|
39
45
|
async function callRemoteServer(method, params) {
|
|
40
46
|
const headers = {
|
|
41
47
|
'Content-Type': 'application/json',
|
|
42
|
-
'
|
|
48
|
+
'X-API-Key': API_KEY, // Safe: already validated above
|
|
43
49
|
};
|
|
44
50
|
if (sessionId) {
|
|
45
51
|
headers['Mcp-Session-Id'] = sessionId;
|
|
@@ -75,7 +81,7 @@ async function initializeRemoteSession() {
|
|
|
75
81
|
capabilities: {},
|
|
76
82
|
clientInfo: {
|
|
77
83
|
name: 'pg-memory-stdio',
|
|
78
|
-
version: '2.
|
|
84
|
+
version: '2.4.0',
|
|
79
85
|
},
|
|
80
86
|
});
|
|
81
87
|
}
|
|
@@ -95,7 +101,7 @@ async function main() {
|
|
|
95
101
|
// Create local MCP server
|
|
96
102
|
const server = new McpServer({
|
|
97
103
|
name: 'pg-memory',
|
|
98
|
-
version: '2.
|
|
104
|
+
version: '2.4.0',
|
|
99
105
|
description: `PG-Memory knowledge base (${modeLabel} mode)`,
|
|
100
106
|
});
|
|
101
107
|
// ============================================================
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pragmatic-growth/memory-mcp",
|
|
3
|
-
"version": "2.
|
|
4
|
-
"description": "Stdio proxy for PG-Memory - connects stdio-based MCP clients (
|
|
3
|
+
"version": "2.4.0",
|
|
4
|
+
"description": "Stdio proxy for PG-Memory - connects stdio-based MCP clients (Claude Desktop, Raycast) to your PG-Memory HTTP server using Clerk API key authentication. Supports both read-only and full edit modes.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"bin": {
|
|
7
7
|
"memory-mcp": "./dist/index.js"
|
package/src/index.ts
CHANGED
|
@@ -11,9 +11,13 @@
|
|
|
11
11
|
* npx @pragmatic-growth/memory-mcp --edit # Alias for --full
|
|
12
12
|
*
|
|
13
13
|
* Environment variables:
|
|
14
|
-
* MCP_API_KEY - API key for authentication (required)
|
|
14
|
+
* MCP_API_KEY - Clerk API key for authentication (required)
|
|
15
15
|
* MCP_SERVER_URL - Server URL (default: https://pg-memory-production.up.railway.app/api/mcp)
|
|
16
16
|
* MCP_MODE - Mode: 'readonly' (default) or 'full' for edit capabilities
|
|
17
|
+
*
|
|
18
|
+
* Authentication:
|
|
19
|
+
* Uses Clerk API key authentication via X-API-Key header.
|
|
20
|
+
* Get your API key from the Clerk Dashboard or the app's API Docs page.
|
|
17
21
|
*/
|
|
18
22
|
|
|
19
23
|
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
@@ -27,12 +31,13 @@ const envMode = process.env.MCP_MODE?.toLowerCase();
|
|
|
27
31
|
const isFullMode = hasFullFlag || envMode === 'full' || envMode === 'edit';
|
|
28
32
|
|
|
29
33
|
// Configuration
|
|
30
|
-
const SERVER_URL = process.env.MCP_SERVER_URL || 'https://
|
|
34
|
+
const SERVER_URL = process.env.MCP_SERVER_URL || 'https://memory.pragmaticgrowth.com/api/mcp';
|
|
31
35
|
const API_KEY = process.env.MCP_API_KEY;
|
|
32
36
|
|
|
33
37
|
if (!API_KEY) {
|
|
34
38
|
console.error('Error: MCP_API_KEY environment variable is required');
|
|
35
|
-
console.error('
|
|
39
|
+
console.error('Get your Clerk API key from the Clerk Dashboard or app API Docs page');
|
|
40
|
+
console.error('Set it in your MCP client configuration under "env"');
|
|
36
41
|
process.exit(1);
|
|
37
42
|
}
|
|
38
43
|
|
|
@@ -49,11 +54,12 @@ interface JsonRpcResponse {
|
|
|
49
54
|
|
|
50
55
|
/**
|
|
51
56
|
* Make an HTTP request to the remote MCP server.
|
|
57
|
+
* Uses X-API-Key header for Clerk API key authentication.
|
|
52
58
|
*/
|
|
53
59
|
async function callRemoteServer(method: string, params?: Record<string, unknown>): Promise<unknown> {
|
|
54
60
|
const headers: Record<string, string> = {
|
|
55
61
|
'Content-Type': 'application/json',
|
|
56
|
-
'
|
|
62
|
+
'X-API-Key': API_KEY!, // Safe: already validated above
|
|
57
63
|
};
|
|
58
64
|
|
|
59
65
|
if (sessionId) {
|
|
@@ -97,7 +103,7 @@ async function initializeRemoteSession(): Promise<void> {
|
|
|
97
103
|
capabilities: {},
|
|
98
104
|
clientInfo: {
|
|
99
105
|
name: 'pg-memory-stdio',
|
|
100
|
-
version: '2.
|
|
106
|
+
version: '2.4.0',
|
|
101
107
|
},
|
|
102
108
|
});
|
|
103
109
|
}
|
|
@@ -119,7 +125,7 @@ async function main(): Promise<void> {
|
|
|
119
125
|
// Create local MCP server
|
|
120
126
|
const server = new McpServer({
|
|
121
127
|
name: 'pg-memory',
|
|
122
|
-
version: '2.
|
|
128
|
+
version: '2.4.0',
|
|
123
129
|
description: `PG-Memory knowledge base (${modeLabel} mode)`,
|
|
124
130
|
});
|
|
125
131
|
|