Integrations

Overview

Connecting Spectron to your stack – SDKs, MCP server, REST API, and framework integrations.

Spectron integrates with agents through HTTP, MCP, OpenAPI-backed SDKs, and harness adapters that batch conversation turns into /facts/batch, using the same provenance and trust model as the server.

The REST surface is described by an OpenAPI specification. Official Python and TypeScript clients are generated from that spec so request and response types stay aligned with the server — you do not need to hand-maintain DTOs when Spectron adds fields or enums.

Native MCP at /mcp on the api port — same API-KEY as REST. Prefer this when the client already speaks MCP (Claude Desktop, Cursor, Windsurf, VS Code, Claude Code).

spectron mcp

MCP server install

Generated client plus ergonomic façade:

pip install surrealdb-spectron

Python SDK guide

npm install @surrealdb/spectron

JavaScript SDK guide

Direct HTTP from any language. End-user routes: /api/v1/{context_id}/.... Management: /api/v1/contexts/....

REST integration guide · Full reference

Thin packages that mirror agent runtime traffic into POST /api/v1/{ctx}/facts/batch without changing your prompts:

PlatformPackage
LangChain (Python)spectron-langchain
OpenAI Agents (Python)spectron-openai
Vercel AI SDK (TS)@surrealdb/spectron-vercel-ai
n8nn8n-nodes-spectron
Claude Codenpx install-spectron-hook

LangChain · Vercel AI SDK

  • Semantic Kernel and CrewAI adapters — no packages in the repo; pages are placeholders.

  • Kotlin / Swift SDKs — cut from plan-5; Python and TypeScript only.

  • Embedded in-process library — use REST or SDK against a deployed instance (Embedded quickstart).

Was this page helpful?