This guide takes you from a blank terminal to your first remember and recall calls against Spectron on SurrealDB Cloud. Cloud runs the Spectron data plane, SurrealDB, and object store per context — you do not provision infrastructure yourself.
Note
Step 1 — Create a Context and API key (Surrealist)
Sign in to SurrealDB Cloud in Surrealist.
Open your organisation → Contexts (requires Spectron access on your profile).
Subscribe to a Spectron plan (owner) if needed, then Create context — name and region.
Open the context → API keys → create a key. Copy the secret immediately.
You will use:
Host — shown as the endpoint, e.g.
https://abc123.spectron.cloud…(per context, not a single global URL)Context ID — the context identifier
API key —
sk-ctx-…shown once at creation
Step 2 — Set environment variables
Use the exact host from Surrealist settings or API keys — not a generic placeholder domain.
Step 2b — Register scope paths
Scoped writes require registered paths. With the CLI pointed at your context:
Org admins can also register scopes through the SurrealDB Cloud API admin proxy when building custom tooling.
Step 3 — Remember a fact
The response includes a nested extraction object (entities, attributes, relations, …) plus sessionId and turnId.
Step 4 — Recall
Check tier in the response — tier 1 or 2 hits avoid a full LLM synthesis pass. Use trace.traceId to fetch the full retrieval trace.
Step 5 — Optional chat
SDKs
Official clients: surrealdb (Python, includes Spectron / AsyncSpectron) and @surrealdb/spectron (TypeScript). Point them at endpoint: process.env.SPECTRON_URL (your context host). See Integrations.
Cloud vs self-hosted
| SurrealDB Cloud (this guide) | Self-hosted | |
|---|---|---|
| Control plane | SurrealDB Cloud API + Surrealist | Your spectrond + management API |
| Data plane URL | https://{context.host} | Your spectrond api bind address |
| API keys | Surrealist API keys view (via Cloud) | spectrond keys / management API |
| Management key | Held by Cloud — never in the browser | You operate the bootstrap yourself |
For Docker or bare-metal deployment, see Self-hosted quickstart.
Next steps
Spectron on SurrealDB Cloud — Cloud API vs data plane
Surrealist dashboard quickstart — UI tour