skills/surrealmcp/SKILL.md
SurrealMCP -- Model Context Protocol server for SurrealDB. Lets MCP-compatible LLM hosts (Claude Code/Desktop, Cursor, Codex, OpenCode, Amp, Continue, Windsurf) read and write a SurrealDB instance through a single config entry. Part of the surreal-skills collection.
npx skillsauth add 24601/surreal-skills surrealmcpInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
SurrealMCP exposes SurrealDB as a Model Context Protocol server so any MCP host can query, mutate, introspect, and live-subscribe over one declarative config entry instead of bespoke per-agent integration code.
# Install (Cargo)
cargo install surrealmcp
# Or via npm wrapper
npm install -g @surrealdb/surrealmcp
# Run as stdio server (the host launches this command)
surrealmcp \
--endpoint ws://localhost:8000/rpc \
--user $SURREAL_USER --pass $SURREAL_PASS \
--namespace test --database test
Claude Code (~/.claude/mcp.json), Cursor (.cursor/mcp.json), Codex
(~/.codex/mcp.json), OpenCode, Amp, Continue all share the same shape:
{
"mcpServers": {
"surrealdb": {
"command": "surrealmcp",
"args": [
"--endpoint", "ws://localhost:8000/rpc",
"--namespace", "test",
"--database", "test"
],
"env": {
"SURREAL_USER": "root",
"SURREAL_PASS": "root"
}
}
}
}
| Tool | Purpose |
|------|---------|
| query | Parameterized SurrealQL execution |
| select / create / update / merge / delete | Typed CRUD |
| relate | Graph edge creation |
| live / kill | LIVE SELECT subscriptions over MCP notifications |
| schema.introspect / schema.tables / schema.table | Schema introspection |
| info.db / info.ns | INFO statement wrappers |
| use / signin | Session-level namespace + auth changes |
Read-only tools are safe for autonomous loops. Mutating tools should be gated through the host's permission prompt against shared / production DBs.
DEFINE USER ... ON DATABASE), not root.--log-format json for structured stderr suitable for log shipping.surrealmcp ping is the canonical health check.testing
SurrealKit schema sync, rollout migrations, seeding, and declarative testing for SurrealDB apps. Part of the surreal-skills collection.
tools
SurrealDB Surrealism WASM extension development. Write Rust functions, compile to WASM, deploy as database modules. Part of the surreal-skills collection.
development
SurrealFS virtual filesystem for AI agents. Rust core + Python agent (Pydantic AI). Persistent file operations backed by SurrealDB. Part of the surreal-skills collection.
development
Data migration and synchronization to SurrealDB from MongoDB, PostgreSQL, MySQL, Neo4j, Kafka, and JSONL. Full and incremental CDC sync. Part of the surreal-skills collection.