New:Microsoft Teams Notifications Are Now Available in Socket.Learn more →
Get Started

@contextdb/cloud

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@contextdb/cloud

TypeScript SDK for persistent, action-aware memory in AI voice, support, and workflow agents

Source
npmnpm
Version
0.1.0-alpha.6
Version published
Weekly downloads
10
-50%
Maintainers
1
Weekly downloads
 
Created
Source

ContextDB Cloud TypeScript SDK for AI agent memory

Give Node.js voice, support, and workflow agents persistent memory through the hosted ContextDB data plane.

npm install @contextdb/cloud
import { CloudClient } from "@contextdb/cloud";

const db = new CloudClient({
  baseUrl: "https://api.contextdb.ai",
  apiKey: process.env.CONTEXTDB_API_KEY!,
});

const saved = await db.remember(
  "caller-1",
  "Thursday works",
  { source: "user_stated" },
);

Project API keys are server credentials. Do not expose them to browser code. The package is marked server-only and throws if constructed in a browser runtime. Use it from Node.js servers, API routes, workers, or server actions.

Use cases

  • Remember caller preferences across Retell, LiveKit, Pipecat, or custom voice agent sessions.
  • Ground support responses in previous conversations.
  • Require an act/ask/abstain decision before consequential tools run.
  • Pass consistency tokens when a follow-up recall must observe a recent write.
  • Report execution receipts for an auditable memory-to-action timeline.

Asynchronous Formation

const submitted = await db.submitFormationJob(
  "caller-1",
  [{ speaker: "user", content: "I prefer Saturday mornings." }],
  {
    mode: "propose",
    idempotencyKey: "call-456-formation-v1",
  },
);

const job = await db.getFormationJob(submitted.job_id);

Jobs accept structured text turns and return closed, inspectable statuses. Formation remains Hosted Alpha with no audio or cancellation contract.

TypeScript starter kits

  • Vercel AI SDK
  • PyAI Omni voice agents

Both starters install this package from npm and compile against their current framework dependencies in CI.

Is this package production-ready?

The package is alpha. It contains no ContextDB Cloud server implementation. No public availability SLA is claimed.

Keywords

ai-agents

FAQs

Package last updated on 21 Aug 2026

Related posts