Index of every page on this site: llms.txt
All skills
mystenlabs avatar

/walrus-memory

@4d8aa0b
Run it yourself

Walrus Memory (MemWal) — persistent, portable, encrypted memory for AI agents. Use when the user needs to give an AI agent persistent memory across sessions and apps, integrate the @mysten-incubation/memwal TypeScript SDK or Python memwal SDK, set up the Walrus Memory MCP server for Cursor/Claude/Codex, configure remember/recall/analyze/restore operations, manage memory spaces and namespaces, set up delegate keys and accounts, self-host the relayer, or use withMemWal AI middleware (Vercel AI SDK, LangChain, OpenAI SDK). Also use when the user asks about MemWal, Walrus Memory, agent memory, memory spaces, or the memwal-mcp package.

Use this Skill: https://skilld.dev/gh/mystenlabs/walrus-skills/walrus-memory

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

mcp.md

≈1.1k tokens on demand. Your agent reads this file only when SKILL.md points to it.

MCP Server Reference

Source: https://docs.wal.app/walrus-memory/mcp

The Walrus Memory MCP server gives MCP-aware AI clients (Cursor, Claude Desktop, Claude Code, Codex, Antigravity) access to persistent agent memory through eight built-in tools. No custom SDK code needed.

Quick start

1. Login (one-time, from a real terminal)

npx -y @mysten-incubation/memwal-mcp login --prod

Opens a browser to memory.walrus.xyz/connect/mcp. Approve with your Sui wallet. Credentials are saved to ~/.memwal/credentials.json.

For staging/testnet: --staging. For local dev: --local.

2. Add to your MCP client

Cursor (~/.cursor/mcp.json):

{
  "mcpServers": {
    "memwal": {
      "command": "npx",
      "args": ["-y", "@mysten-incubation/memwal-mcp"]
    }
  }
}

Claude Desktop (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "memwal": {
      "command": "npx",
      "args": ["-y", "@mysten-incubation/memwal-mcp"]
    }
  }
}

Claude Code:

claude mcp add --scope user memwal -- npx -y @mysten-incubation/memwal-mcp

Codex (~/.codex/config.toml):

[mcp_servers.memwal]
command = "npx"
args = ["-y", "@mysten-incubation/memwal-mcp"]

3. Restart the client

MCP servers load at startup. Fully quit and reopen (Cmd+Q on macOS). First launch fetches the package (5-10 second delay).

Eight MCP tools

Tool Description
memwal_remember Store a memory (text, optional namespace)
memwal_remember_bulk Store multiple memories in a single call
memwal_recall Search memories by natural language query
memwal_analyze Extract facts from text and store each separately
memwal_restore Rebuild vector index from Walrus for a namespace
memwal_health Check server and relayer connectivity status
memwal_login Open browser login flow (local-only tool)
memwal_logout Delete local credentials (local-only tool)

Auth-required mode

If credentials are missing on startup, the MCP server does not crash. It starts in auth-required mode with only memwal_login available. Ask the agent to run memwal_login, approve in the browser, then retry. This avoids the old UX of "failed to start server" errors.

Default namespace

Pin a default namespace in your client config to avoid passing it on every call:

{
  "mcpServers": {
    "memwal": {
      "command": "npx",
      "args": ["-y", "@mysten-incubation/memwal-mcp", "--namespace", "work"]
    }
  }
}

Or via environment variable:

{
  "mcpServers": {
    "memwal": {
      "command": "npx",
      "args": ["-y", "@mysten-incubation/memwal-mcp"],
      "env": { "MEMWAL_NAMESPACE": "work" }
    }
  }
}

Precedence: per-call namespace > flag/env default > relayer default ("default").

Switching environments

npx -y @mysten-incubation/memwal-mcp --logout
npx -y @mysten-incubation/memwal-mcp login --staging

The client config does not change. The package reads the environment from ~/.memwal/credentials.json.

Flag Relayer Dashboard
--prod https://relayer.memory.walrus.xyz https://memory.walrus.xyz
--staging https://relayer-staging.memory.walrus.xyz https://staging.memory.walrus.xyz
--local http://127.0.0.1:8000 http://localhost:5173

Streamable HTTP (remote MCP)

If your MCP client supports remote servers with custom headers, connect directly to the relayer:

  • URL: https://relayer.memory.walrus.xyz/api/mcp
  • Header: Authorization: Bearer <delegatePrivateKey>
  • Header: x-memwal-account-id: <accountId>

Values come from ~/.memwal/credentials.json after login.

Signing out

npx -y @mysten-incubation/memwal-mcp --logout

Deletes local credentials. The onchain delegate key is NOT revoked. Visit memory.walrus.xyz to remove it from your account.

Troubleshooting

  • No Walrus Memory tools visible: MCP host did not load the package. Check config file path, restart fully, confirm Node 20+.
  • Only memwal_login visible: Credentials are missing. Run the login command or ask the agent to call memwal_login.
  • Login command exits silently: Run in a real terminal with TTY. Non-interactive shells cannot open the browser.
  • 5-10 second delay on first use: Normal. npx fetches the package on first run.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts1mo3 checks · Risk SAFE
  • Gen Agent Trust Hub1mo

    This skill provides instructions and references for integrating Walrus Memory, a decentralized and encrypted storage solution for AI agent persistence. It includes setup guides for TypeScript and Python SDKs, as well as a Model Context Protocol (MCP) server. The main security consideration is the inherent attack surface for indirect prompt injection common to agent memory systems.

  • Socket1mo

    No alerts

  • Snyk1mo

    Risk: LOW · No issues

Signed by skilld at 4d8aa0b. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Steadyupdated 4 months ago

README badge

README badge for mystenlabs/walrus-skills/walrus-memory