一键导入
hq-cowork-sync
Run bidirectional HQ Sync from Cowork.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Run bidirectional HQ Sync from Cowork.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Deploy or share generated HQ artifacts through hq-deploy.
Mark a company as HQ Pro cloud-backed and sync its team setup.
Send HQ Sync direct messages, prompts, details, or scheduled notes to teammates.
Run a full bidirectional sync for cloud-backed HQ companies.
Scaffold a new HQ company AND optionally take it all the way to operational — business-discovery interview, seeded knowledge/workers/skills/projects, brand design packs (generated from website/PDF/Drive and bound to deploys via policy), connected integrations, org groups + ACL rules, teammate invites, and optional cloud agents.
Resolve HQ Sync conflicts by choosing local, cloud, or discard.
| name | hq-cowork-sync |
| description | Run bidirectional HQ Sync from Cowork. |
| allowed-tools | mcp__hq__hq_sync, mcp__hq__hq_whoami |
Runs the same sync engine the HQ Desktop App uses, but from inside a sandboxed Claude Code plugin host (Cowork, in particular). Walks every cloud-backed company in your local HQ, syncs in both directions against the vault, and writes conflict mirror files when divergence is detected.
Args: $ARGUMENTS — optional flags. Accepted shapes (parse free-text):
--company <slug> → scope to one company--personal → sync only the caller's personal vault--on-conflict overwrite|keep|abort → conflict strategy (default keep)--message "<msg>" → optional journal message attached to push legWithout args, syncs every membership + personal vault with --on-conflict keep.
/hq-sync~/.hq/cognito-tokens.json and hq isn't on PATH inside it, so the regular
/hq-sync skill (which spawns npx ... hq-sync-runner) cannot run.In a regular Claude Code session running on the host directly, prefer the
unprefixed /hq-sync skill — same engine, fewer hops.
Before the first sync of a session, call mcp__hq__hq_whoami. If it returns
your identity + session expiry, the host MCP is live and authenticated. If
it errors with "not signed in" or "tokens expired", tell the user to run
hq login on the host machine (the sandboxed agent cannot do this itself
— hq login opens a browser on the host).
Parse $ARGUMENTS into the hq_sync tool's input schema:
| Arg pattern | Tool input |
|---|---|
--company <slug> | { "company": "<slug>" } |
--personal | { "personal": true } |
| (neither) | {} — server defaults to --all |
--on-conflict <strategy> | { "onConflict": "<strategy>" } |
--message "<msg>" | { "message": "<msg>" } |
Call mcp__hq__hq_sync with the assembled input. Sync output can be chunky
(per-company push + pull legs) — surface a terse summary, not the full log,
unless the user asked for verbose detail.
Quiet by default. Surface:
<hqRoot>/.hq-conflicts/index.json
if any — the user can run /resolve-conflicts next)If conflicts were written, mention /resolve-conflicts as the next step.
The unprefixed /hq-sync skill resolves HQ root via four config tiers and
then execs the cloud-runner binary directly with the host's Cognito
session. None of that works from Cowork's sandbox, where ~/.hq is not
mounted and the host's Node binary isn't reachable. The
hq-pack-cowork MCP server fixes that by running on the host (with full
auth + binaries) and exposing hq_sync as a tool call the sandboxed agent
can make. This skill is the thin in-session adapter for that tool.