vault-cortex 0.2.2 → 0.2.4

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/messages.js CHANGED
@@ -22,8 +22,11 @@ export const buildLocalConnectMessage = (params) => {
22
22
  const startLine = started
23
23
  ? "The server is running."
24
24
  : startServerLine(targetDir);
25
+ // When the token was written, put it alone on its own line so selecting
26
+ // that line copies just the token — no "Auth token: " prefix to trim and
27
+ // no chance of grabbing the surrounding label.
25
28
  const tokenLine = tokenWritten
26
- ? `Auth token: ${token}`
29
+ ? `Auth token:\n ${token}`
27
30
  : `Auth token: use the existing MCP_AUTH_TOKEN in ${targetDir}/.env`;
28
31
  // Flush-left on purpose: template literals keep leading whitespace, so
29
32
  // indenting these lines would indent the rendered output.
@@ -33,19 +36,30 @@ Connect your MCP client:
33
36
  URL: http://localhost:${port}/mcp
34
37
  ${tokenLine}
35
38
 
36
- OAuth clients (Claude Desktop, Claude Code, most MCP clients):
37
- 1. Add the URL above as a remote MCP server, leaving Client
38
- ID/Secret empty ("remote" = HTTP — the server still runs on
39
- your machine)
39
+ Claude Code:
40
+ 1. claude mcp add --transport http vault-cortex http://localhost:${port}/mcp
40
41
  2. Approve the browser consent page with the token above
41
- 3. Done the client holds auto-refreshing access tokens; the
42
+ 3. Done. The client holds auto-refreshing access tokens; the
42
43
  token never sits in client config
43
44
 
45
+ Claude Desktop only accepts https URLs in its connector dialog, so
46
+ register the server in claude_desktop_config.json via the mcp-remote
47
+ bridge instead:
48
+ "vault-cortex": {
49
+ "command": "npx",
50
+ "args": ["-y", "mcp-remote", "http://localhost:${port}/mcp",
51
+ "--header", "Authorization: Bearer <token above>"]
52
+ }
53
+
54
+ Other OAuth clients (Cursor, most MCP clients) add the URL above as a
55
+ remote MCP server, leaving Client ID/Secret empty ("remote" = HTTP —
56
+ the server still runs on your machine), then approve the consent page.
57
+
44
58
  Clients without OAuth, scripts, and curl send the token directly:
45
59
  curl -H "Authorization: Bearer <token>" http://localhost:${port}/mcp
46
60
 
47
- Note: claude.ai (web) cannot reach localhost — use Claude Desktop or
48
- Claude Code for a local server.
61
+ Note: claude.ai (web) cannot reach localhost — use Claude Code for local
62
+ access, or Claude Desktop with the mcp-remote bridge.
49
63
 
50
64
  Smoke test:
51
65
  curl http://localhost:${port}/healthz
@@ -71,6 +85,14 @@ export const buildRemoteConnectMessage = (params) => {
71
85
  const approveLine = tokenWritten
72
86
  ? `approve with your MCP_AUTH_TOKEN:\n ${token}`
73
87
  : `approve with the existing MCP_AUTH_TOKEN in ${targetDir}/.env`;
88
+ const httpUrlWarning = publicUrl.startsWith("https://")
89
+ ? ""
90
+ : `
91
+
92
+ Note: claude.ai and Claude Desktop only accept https URLs — set up
93
+ HTTPS when you're ready for those clients (see the HTTPS section in
94
+ the remote guide). Claude Code works with http:
95
+ claude mcp add --transport http vault-cortex ${publicUrl}/mcp`;
74
96
  // Flush-left on purpose: template literals keep leading whitespace, so
75
97
  // indenting these lines would indent the rendered output.
76
98
  const connectMessage = `${startLine}
@@ -80,7 +102,7 @@ Connect your MCP client:
80
102
 
81
103
  OAuth clients (Claude Desktop, Claude Code, claude.ai): add a remote MCP
82
104
  server with that URL and leave Client ID/Secret empty — a consent page
83
- opens; ${approveLine}
105
+ opens; ${approveLine}${httpUrlWarning}
84
106
 
85
107
  Optional settings (timezone, memory folder, port, logging, sync
86
108
  behavior) are commented out in ${targetDir}/.env — uncomment, set a
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vault-cortex",
3
- "version": "0.2.2",
3
+ "version": "0.2.4",
4
4
  "description": "Set up a Vault Cortex MCP server for your Obsidian vault in one command: npx vault-cortex init",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -6,6 +6,8 @@
6
6
  # 1. cp .env.example .env (then fill in MCP_AUTH_TOKEN and VAULT_PATH)
7
7
  # 2. docker compose up
8
8
  # 3. Connect your MCP client to http://localhost:8000/mcp
9
+ # (Claude Desktop's connector dialog requires https — register a
10
+ # localhost server via the mcp-remote bridge; see the local README)
9
11
  #
10
12
  # Full docs: https://github.com/aliasunder/vault-cortex
11
13