mirror of
https://github.com/supermemoryai/supermemory.git
synced 2026-08-28 05:25:33 +00:00
## Summary - Replace percard Docs links with hover only info buttons and card click info modals - Add doc backed use cases inside setupstyle info modals, with Docs access and the same card action in the footer - Track all info modal close behavior through one analytics event with a close reason - Keep Active/Connected status in the card footer, align the info icon to the card action margin, and fix the Settings modal Integrations linkout <h3>Normal no hovering</h3> <img width="1029" height="529" alt="Screenshot 2026-06-09 at 1 21 38 PM" src="https://github.com/user-attachments/assets/ea817984-34a2-437e-9590-addea0f8d4a1" /> <h3>On hovering</h3> <img width="466" height="340" alt="Screenshot 2026-06-09 at 1 21 23 PM" src="https://github.com/user-attachments/assets/765c6132-9f91-4a9a-8141-6d61e24b688e" /> <img width="846" height="549" alt="Screenshot 2026-06-09 at 1 34 43 PM" src="https://github.com/user-attachments/assets/aaa10604-98e0-4139-b32f-b19e230210a2" /> <h3>Info modal</h3> <img width="1303" height="788" alt="Screenshot 2026-06-09 at 1 22 29 PM" src="https://github.com/user-attachments/assets/18b6228f-3a3b-481b-8459-392a39eccb1a" /> <img width="724" height="415" alt="Screenshot 2026-06-09 at 1 22 46 PM" src="https://github.com/user-attachments/assets/5e25e68b-53a9-4fa1-a5cf-1980ede7661a" />
159 lines
4.7 KiB
TypeScript
159 lines
4.7 KiB
TypeScript
export interface InstallStep {
|
|
title: string
|
|
description?: string
|
|
code?: string
|
|
copyLabel?: string
|
|
optional?: boolean
|
|
/** Blur the code block until hovered/focused (e.g. it contains the key). */
|
|
secret?: boolean
|
|
}
|
|
|
|
export interface PluginInfo {
|
|
id: string
|
|
name: string
|
|
tagline: string
|
|
icon: string
|
|
docsUrl?: string
|
|
githubUrl?: string
|
|
usesOAuth?: boolean
|
|
/** Steps shown after a key is minted. The literal `sm_...` is replaced
|
|
* with the freshly generated key when rendered. */
|
|
installSteps?: InstallStep[]
|
|
}
|
|
|
|
/** Match `FREE_TIER_PLUGIN_IDS` in mono `packages/lib/plugins.ts`. */
|
|
export const FREE_TIER_PLUGIN_IDS = ["hermes", "codex"]
|
|
|
|
export function isFreeTierPlugin(pluginId: string): boolean {
|
|
return FREE_TIER_PLUGIN_IDS.includes(pluginId)
|
|
}
|
|
|
|
export const PLUGIN_CATALOG: Record<string, PluginInfo> = {
|
|
claude_code: {
|
|
id: "claude_code",
|
|
name: "Claude Code",
|
|
tagline: "Remembers your conventions, decisions, and project context",
|
|
icon: "/images/plugins/claude-code.svg",
|
|
docsUrl: "https://supermemory.ai/docs/integrations/claude-code",
|
|
installSteps: [
|
|
{
|
|
title: "Save your API key",
|
|
description:
|
|
"Add this to your shell profile so Claude Code can authenticate. This key is shown only once — save it now.",
|
|
code: 'export SUPERMEMORY_CC_API_KEY="sm_..."',
|
|
copyLabel: "API key",
|
|
secret: true,
|
|
},
|
|
{
|
|
title: "Install the plugin",
|
|
description: "Run these commands inside a Claude Code session:",
|
|
code: "/plugin marketplace add supermemoryai/claude-supermemory\n/plugin install claude-supermemory",
|
|
},
|
|
],
|
|
},
|
|
codex: {
|
|
id: "codex",
|
|
name: "Codex",
|
|
tagline: "Persistent memory for the Codex CLI — free on every plan",
|
|
icon: "/images/plugins/codex.png",
|
|
docsUrl: "https://supermemory.ai/docs/integrations/codex",
|
|
githubUrl: "https://github.com/supermemoryai/codex-supermemory",
|
|
installSteps: [
|
|
{
|
|
title: "Save your API key",
|
|
description:
|
|
"Add this to your shell profile. This key is shown only once — save it now.",
|
|
code: 'export SUPERMEMORY_CODEX_API_KEY="sm_..."',
|
|
copyLabel: "API key",
|
|
secret: true,
|
|
},
|
|
{
|
|
title: "Install the hooks",
|
|
description: "Run this to wire Supermemory into Codex CLI:",
|
|
code: "npx codex-supermemory@latest install",
|
|
},
|
|
],
|
|
},
|
|
opencode: {
|
|
id: "opencode",
|
|
name: "OpenCode",
|
|
tagline: "Long-term memory for your OpenCode sessions",
|
|
icon: "/images/plugins/opencode.svg",
|
|
docsUrl: "https://supermemory.ai/docs/integrations/opencode",
|
|
githubUrl: "https://github.com/supermemoryai/opencode-supermemory",
|
|
usesOAuth: true,
|
|
installSteps: [
|
|
{
|
|
title: "Install the plugin",
|
|
description: "Use --no-tui for non-interactive environments.",
|
|
code: "bunx opencode-supermemory@latest install",
|
|
},
|
|
{
|
|
title: "Authenticate OpenCode",
|
|
description:
|
|
"Run the browser auth flow from the machine where OpenCode runs:",
|
|
code: "bunx opencode-supermemory@latest login",
|
|
},
|
|
{
|
|
title: "Verify your config",
|
|
description:
|
|
"Ensure ~/.config/opencode/opencode.jsonc includes the plugin:",
|
|
code: '{\n "plugin": ["opencode-supermemory"]\n}',
|
|
optional: true,
|
|
},
|
|
],
|
|
},
|
|
openclaw: {
|
|
id: "openclaw",
|
|
name: "OpenClaw",
|
|
tagline: "Cross-platform memory across Telegram, Discord, Slack",
|
|
icon: "/images/plugins/openclaw.svg",
|
|
docsUrl: "https://supermemory.ai/docs/integrations/openclaw",
|
|
installSteps: [
|
|
{
|
|
title: "Install the plugin",
|
|
description: "Run this in your OpenClaw project:",
|
|
code: "openclaw plugins install @supermemory/openclaw-supermemory",
|
|
},
|
|
{
|
|
title: "Configure Supermemory",
|
|
description:
|
|
"Run the setup command and paste your API key when prompted:",
|
|
code: "openclaw supermemory setup",
|
|
},
|
|
],
|
|
},
|
|
hermes: {
|
|
id: "hermes",
|
|
name: "Hermes",
|
|
tagline: "Persistent memory for the Hermes agent — free on every plan",
|
|
icon: "/images/plugins/hermes.svg",
|
|
docsUrl: "https://supermemory.ai/docs/integrations/hermes",
|
|
installSteps: [
|
|
{
|
|
title: "Run Hermes memory setup",
|
|
description:
|
|
"On the machine where Hermes is deployed, start the memory wizard, choose Supermemory as the provider, and paste your API key when prompted:",
|
|
code: "hermes memory setup",
|
|
},
|
|
],
|
|
},
|
|
}
|
|
|
|
const SPACE_TO_CATALOG_ID: Record<string, string> = {
|
|
"claude-code": "claude_code",
|
|
codex: "codex",
|
|
opencode: "opencode",
|
|
openclaw: "openclaw",
|
|
hermes: "hermes",
|
|
}
|
|
|
|
export function spacePluginIdToCatalogId(spacePluginId: string): string | null {
|
|
return SPACE_TO_CATALOG_ID[spacePluginId] ?? null
|
|
}
|
|
|
|
/** Normalize plugin client ids from API keys, metadata, and space ids. */
|
|
export function normalizePluginClientId(client: string): string {
|
|
const trimmed = client.trim().toLowerCase()
|
|
return spacePluginIdToCatalogId(trimmed) ?? trimmed.replace(/-/g, "_")
|
|
}
|