Skip to content

Persistent Context Across Sessions for Every Agent – Captures everything your agent does during sessions, compresses it with AI, and injects relevant context back into future sessions. Works with Claude Code, OpenClaw, Codex, Gemini, Hermes, Copilot, OpenCode + More

791 B
Raw Blame
/**
 * The plans whose account has a Cloud Sync connection of its own, defined once
 * for `claude-mem sync setup` and for the worker route that imports a
 * workspace's prompts. This module has no imports, so both take it without
 * loading the other.
 *
 * A TeamBrain seat is one of them: cmem.ai tells a seat its access covers sync,
 * and the installer and `teambrain join` already write a seat's connection.
 * `none` is not: it has no sync access to import into.
 */
export const SYNC_SETUP_PLANS: readonly string[] = ['cloud_sync', 'pro', 'trial', 'teambrain_seat'];

/** Whether an account on `plan` may connect a workspace and import its prompts. */
export function planAllowsSyncSetup(plan: string | undefined): boolean {
  return SYNC_SETUP_PLANS.includes(plan?.trim() ?? '');
}