You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| `cloud` | `https://sophia-api.restheart.com/mcp/cloud/` | RESTHeart Cloud managed service docs
35
35
|===
36
36
37
-
These are fully functional Sophia deployments managed by SoftInstigate. You can use them directly in your AI client or as a reference when setting up your own instance via link:/docs/cloud[RESTHeart Cloud].
37
+
These are fully functional Sophia deployments managed by SoftInstigate. You can use them directly in your AI client.
38
38
39
-
To connect immediately with Claude Desktop, open *Settings → Connectors → Add custom connector* and paste the URL. Or add this to `claude_desktop_config.json`:
39
+
To connect immediately with Claude Desktop, open *Settings → Connectors → Add custom connector* and paste the URL.
Private knowledge bases require an API token. Issue one from the admin panel (see link:/docs/cloud/sophia/administrator-guide#_api_token_management[API Token Management]). The admin panel generates ready-to-paste MCP configuration snippets for each token.
The token can be passed as an `Authorization: Bearer <token>` header or, for clients that do not support custom headers, as a `?token=<jwt>` query parameter:
Open *Settings → Connectors → Add custom connector* and paste the URL.
66
48
67
-
Clients that connect directly over HTTP (Claude Desktop, Cursor) use the context URL with an optional `Authorization` header.
49
+
=== Clients with native Streamable HTTP support
68
50
69
-
*Claude Desktop* — the easiest way is via the UI: open *Settings → Connectors → Add custom connector* and paste the context URL. For private contexts, Claude Desktop will prompt for OAuth client credentials, which Sophia supports natively.
70
-
71
-
To configure via `claude_desktop_config.json` (`~/Library/Application Support/Claude/` on macOS, `%APPDATA%\Claude\` on Windows):
51
+
Add this to the MCP settings:
72
52
73
53
[source,json]
74
54
----
75
55
{
76
-
"mcpServers": {
77
-
"sophia": {
78
-
"type": "sse",
79
-
"url": "https://<your-sophia>/mcp/<context>/",
80
-
"headers": {
81
-
"Authorization": "Bearer <your-token>"
82
-
}
83
-
}
56
+
"sophia": {
57
+
"type": "http",
58
+
"url": "https://<your-sophia>/mcp/<context>/"
84
59
}
85
60
}
86
61
----
87
62
88
-
Restart Claude Desktop after editing the file.
63
+
=== Clients that support stdio only
64
+
65
+
Some clients (Claude Code, VS Code, Zed) spawn MCP servers as local processes and communicate over stdio. Use link:https://www.npmjs.com/package/mcp-remote[`mcp-remote`] as a bridge. It requires link:https://nodejs.org[Node.js >= 18] and is downloaded automatically by `npx` on first run.
Private contexts require authentication. Sophia supports two approaches.
82
+
83
+
=== Via OAuth (recommended for interactive clients)
84
+
85
+
Claude Desktop supports OAuth natively. Other clients work in similar way.
106
86
107
-
Some clients (Claude Code, Zed, VS Code) spawn MCP servers as local processes and communicate over stdio. Use link:https://www.npmjs.com/package/mcp-remote[`mcp-remote`] as a bridge — it connects to the HTTP endpoint and exposes it as a stdio process. It requires link:https://nodejs.org[Node.js >= 18] and is downloaded automatically by `npx` on first run.
87
+
Open *Settings → Connectors → Add custom connector*, paste the context URL, and set `OAuth Client ID` to `claude_desktop` in the advanced settings. Sophia login page will open in the browser to complete the flow.
108
88
109
-
For authenticated access with stdio clients, pass the token via the `?token=` query parameter since stdio bridges typically do not support injecting headers.
89
+
=== Via API token
110
90
111
-
*Claude Code* — add to `.mcp.json` in your project root or to the global MCP config:
91
+
Issue a token from the admin panel (see link:/docs/cloud/sophia/administrator-guide#_api_token_management[API Token Management]). Pass it as an `Authorization: Bearer` header or, for clients that do not support custom headers, as a `?token=<jwt>` query parameter.
@@ -149,22 +133,3 @@ For authenticated access with stdio clients, pass the token via the `?token=` qu
149
133
| `sophia_render_prompt` | Builds a fully interpolated system prompt with RAG context injected, ready to send to any LLM as a `system` + `user` message pair.
150
134
| `sophia_api` | Returns the complete Sophia REST API reference. Requires authentication — reserved for service administrators.
151
135
|===
152
-
153
-
== Recommended Tool-Chaining Workflow
154
-
155
-
To maximise the context available to an AI agent:
156
-
157
-
. *`sophia_search`* — find relevant chunks; note the `Source:` filename and `Path:` directory in each result.
158
-
. *`sophia_get_file`* — retrieve the full file from `Source:` (not just the matched chunk).
159
-
. *`sophia_list_files`* with `path=<Path:>` — discover all related files in the same directory.
160
-
. *`sophia_get_file`* — retrieve any relevant sibling files.
161
-
162
-
To explore the knowledge base structure before searching:
163
-
164
-
[source]
165
-
----
166
-
sophia_list_paths → top-level directories
167
-
sophia_list_paths(path=X) → subdirectories under X
0 commit comments