cloud-sync

cloud-sync is a skill for Claude Code, Codex from thedotmack/claude-mem. It costs 64 tokens per session (1,214 once invoked), scanned A, original, Apache-2.0.

A guide for checking or configuring claude-mem cloud sync through cmem.ai Pro. Cloud sync backs up or synchronizes the local memory database using the service's SyncHub connection.

In plain words
What is it for?
Use it to check sync status, connection reachability, pending operations, recent sync time, and errors. It can also write the connection values issued by cmem.ai into the local settings file.
Why use it?
It helps verify whether the worker can reach the sync service and whether memory operations are waiting to be uploaded. It also keeps the sync token private and preserves unrelated settings.

Skill for Claude CodeCodex

Part of the claude-mem plugin — 16 skills, 1 MCP server shipped together

About the project

Claude-Mem, now presented as Grok Mem, records an agent's work, compresses it with AI, and brings relevant notes into later sessions so the agent can remember decisions and next steps. It is intended for persistent context across agent conversations and supports multiple coding-agent environments. The catalogue add-ons provide the workflows and integrations used to operate this memory system.

thedotmack/claude-mem · 93,095 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/thedotmack/claude-mem/cloud-sync
Any agent
npx skills add thedotmack/claude-mem --skill cloud-sync
Clone the repo
git clone --depth 1 https://github.com/thedotmack/claude-mem

Made for: Claude Code, Codex.

Or install claude-mem, the plugin that ships this one along with the rest of its 16 skills, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cloud-sync

README.md
[![agentmods](https://agentmods.dev/badge/skills/thedotmack/claude-mem/cloud-sync.svg)](https://agentmods.dev/skills/thedotmack/claude-mem/cloud-sync)
Your own site
<a href="https://agentmods.dev/skills/thedotmack/claude-mem/cloud-sync"><img src="https://agentmods.dev/badge/skills/thedotmack/claude-mem/cloud-sync.svg" alt="Measured on agentmods" height="20"></a>
Per session 64 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,214 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00064 $0.01214
Opus 5 $0.00032 $0.00607
Sonnet 5 $0.00013 $0.00243
Haiku 4.5 $0.00006 $0.00121

Measured 5d ago against content hash 671a0723613c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cloud-sync scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s "http://127.0.0.1:${PORT}/api/sync/status"
plugin/skills/cloud-sync/SKILL.md · 108 lines

How it starts

The opening of the file, as written. The whole thing — 108 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Cloud Sync (cmem.ai Pro)

The installed worker syncs through SyncHub. There is one client, one durable operation log, and no separate sync daemon. This skill checks status or writes the three connection values issued by cmem.ai → Connect.

Security rule: never print the sync token, put it in argv, or log it. Confirm only its length. Preserve every unrelated setting and keep ~/.claude-mem/settings.json mode 0600.

1. Check status

Resolve the worker port and query the always-registered status route:

PORT="${CLAUDE_MEM_WORKER_PORT:-$(node -e "const fs=require('fs'),p=require('path'),os=require('os');const uid=(typeof process.getuid==='function'?process.getuid():77);const fallback=String(37700+(uid%100));try{const s=JSON.parse(fs.readFileSync(p.join(os.homedir(),'.claude-mem','settings.json'),'utf-8'));process.stdout.write(String(s.CLAUDE_MEM_WORKER_PORT||fallback));}catch{process.stdout.write(fallback);}" 2>/dev/null)}"
curl -s "http://127.0.0.1:${PORT}/api/sync/status"
  • configured: true and hub.reachable: true → the worker completed an authenticated GET /v1/sync/status against SyncHub. Report deviceId, pending counts, lastFlushAt, lastError, and the Hub head/checkpoint; stop unless the user asked to replace the connection.
  • configured: true and hub.reachable: false → report hub.error and say the SyncHub connection is not verified. A zero pending count or lastError: null is not success because an empty queue performs no push.
  • configured: false → continue.
  • Connection refused, 404, or 503 immediately after restart → retry every three seconds for about 30 seconds before diagnosing the worker.

2. Obtain the connection

Ask for all three values shown by cmem.ai → Connect:

  1. sync token;
  2. user id;
  3. SyncHub URL.

The Hub URL must be an absolute https:// URL. Do not substitute the cmem.ai application API URL; the installed client talks only to SyncHub.

3. Write installed-client settings

Read the full file on GitHub · 108 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 108 lines · 64 tokens per session scan A 671a0723613c

Subscribe to this mod's changes

cloud-sync is a skill published in the GitHub repository thedotmack/claude-mem (93,095 stars, last pushed yesterday), licensed Apache-2.0. It adds 64 tokens to every session and 1,214 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.