twg-confluence

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

twg-confluence

twg-confluence

Use with root
twg
when Confluence is the primary source or mutation target. This skill owns content-type, hierarchy, format, and concurrency semantics; live help owns exact command grammar.
搭配根命令
twg
使用,当Confluence作为主要数据源或变更目标时启用。 本技能负责内容类型、层级结构、格式以及并发语义; 实时帮助模块负责具体命令语法。

CLI launcher fallback

CLI启动器回退方案

Run
twg <command>
. On shell
command not found
, use
$HOME/.local/bin/twg
(macOS/Linux) /
$env:LOCALAPPDATA\Programs\twg\bin\twg.exe
(PowerShell), then tell user to add that directory to PATH. Do not treat auth or command errors as PATH failures.
运行
twg <command>
。若shell提示
command not found
,请使用
$HOME/.local/bin/twg
(macOS/Linux系统)或
$env:LOCALAPPDATA\Programs\twg\bin\twg.exe
(PowerShell环境),随后告知用户需将该目录添加至PATH环境变量。请勿将认证错误或命令错误视为PATH配置问题。

Use When

使用场景

  • Use for Confluence-anchored content or space reads and mutations, including CQL, bodies, hierarchy, versions, permissions, and exports.
  • Do not load for a supporting Confluence link in a broader workflow.
  • 适用于以Confluence为核心的内容或空间的读取与变更操作,包括CQL查询、内容主体、层级结构、版本、权限及导出功能。
  • 若仅在更宽泛的工作流中涉及Confluence链接作为辅助内容,无需加载本技能。

First Route

优先路由

IntentRoute
Known content ID or URL
confluence content get
Exact Confluence filteringConfluence search with CQL
Date-filtered page/blogpost list
confluence search query --cql
with
lastmodified
;
content list
has no date filter
Fuzzy page/topic discoveryCross-product search, then native get
Create or update contentUnified
confluence content
surface
Space metadata/lifecycle
confluence space
Hierarchy
confluence tree
ExportWord returns a download directly; PDF requires export-status polling
Use
twg help describe "<exact path>"
before an unfamiliar or consequential mutation.
意图路由
已知内容ID或URL
confluence content get
精确Confluence筛选使用CQL进行Confluence搜索
按日期筛选页面/博客列表结合
lastmodified
参数使用
confluence search query --cql
content list
无日期筛选功能
模糊页面/主题发现跨产品搜索,再调用原生获取接口
创建或更新内容统一使用
confluence content
操作入口
空间元数据/生命周期管理
confluence space
层级结构管理
confluence tree
导出操作Word格式直接返回下载文件;PDF格式需轮询导出状态
在执行不熟悉或影响重大的变更操作前,请使用
twg help describe "<exact path>"
查看帮助。

Confluence Semantics

Confluence语义规范

  • Use the unified content surface for content operations advertised by live help; use
    confluence space
    for spaces and
    confluence tree
    for hierarchy.
  • Search snippets are discovery candidates. Read the selected content before summarizing or editing it.
  • Page titles are supplied separately from bodies. Do not repeat the title as the first body heading.
  • Remix create commands create an asset, not a page embed. For a visual on the page, continue with the HTML guide already loaded, update that page, and read it back; an asset ID or URL alone is not completion proof.
  • 对于实时帮助中提到的内容操作,使用统一内容操作入口;空间管理使用
    confluence space
    ,层级结构管理使用
    confluence tree
  • 搜索片段仅作为发现候选内容。在总结或编辑前,请先读取选中的内容。
  • 页面标题需与内容主体分开提供。请勿将标题重复作为内容主体的首个标题。
  • Remix创建命令用于创建资源,而非页面嵌入。若需在页面上展示可视化内容,请继续使用已加载的HTML指南,更新页面后再重新读取;仅提供资源ID或URL不代表操作完成。

Safe Authoring And Editing

安全创作与编辑规范

  • Treat user authorization and CLI confirmation as separate checks for archive, trash, and purge. The CLI requirement to pass
    --yes
    is an execution preflight, not evidence that the user authorized the mutation. Use
    --yes
    only after the user explicitly named the mutation and the exact target or a previously displayed bounded target set.
  • Explicit instructions such as "archive page XYZ" or "archive those 15 pages" after a concrete list authorize execution without another confirmation. Vague outcome language such as "clean up", "organize", "remove clutter", or "take care of" does not authorize archive, trash, or purge.
  • If the mutation or targets were inferred, read and resolve the proposed targets, present the exact action and bounded target list, and wait for the user to affirm that mutation. Do not generalize approval from a similar prior action.
    trash
    does not authorize an additional permanent purge.
  • Before authoring, read and apply the target space's instructions by key or ID; see
    references/spaces.md
    . Empty instructions mean use defaults.
  • Prefer
    live_doc
    for collaborative or co-authored internal content when the target supports it. Bare "page" or "doc" creation also defaults to live docs.
  • Use
    page
    for explicit classic/non-live intent, knowledge bases, customer help, established classic-page spaces, or page-only operations. Preserve an existing target's type; a classic parent or reference does not set a new child's type.
  • For non-trivial edits, read current content, save the body locally, edit the file, then update with the snapshot token.
  • Use the lossless HTML round trip when macros or exact storage representation matter.
  • Use
    --dry-run
    only for explicit preview or validation requests, or for unusually risky edits where direct execution was not requested.
  • Read back the content or space after mutation and report its URL.
  • 对于归档、删除(放入回收站)和彻底清除操作,需分别检查用户授权与CLI确认。CLI要求传递
    --yes
    参数是执行前的预检步骤,而非用户已授权变更的证明。仅当用户明确指定变更操作及精确目标,或目标为之前已展示的有限集合时,方可使用
    --yes
    参数。
  • 若用户给出明确指令,如“归档页面XYZ”或“归档这15个页面”(且已提供具体列表),可直接执行无需再次确认。模糊表述如“清理一下”“整理”“移除冗余内容”“处理一下”等,不代表授权进行归档、删除或彻底清除操作。
  • 若变更操作或目标是推断得出的,请读取并确认拟操作的目标,展示具体操作内容及有限目标列表,等待用户确认后方可执行。请勿将之前类似操作的批准视为本次操作的授权。例如,用户授权删除(放入回收站)并不代表授权额外的彻底清除操作。
  • 在创作前,请通过空间Key或ID读取并应用目标空间的规则;详见
    references/spaces.md
    。若规则为空,则使用默认设置。
  • 当目标支持时,对于协作或共同创作的内部内容,优先使用
    live_doc
    。仅指定“page”或“doc”创建时,默认使用实时文档(live docs)。
  • 若用户明确要求创建传统/非实时文档、知识库、客户帮助文档、已建立的传统页面空间,或仅支持页面的操作,请使用
    page
    。保留现有目标的类型;父级或参考内容为传统页面,不会决定新子内容的类型。
  • 对于非 trivial 的编辑操作,请先读取当前内容,将主体保存至本地,编辑文件后,使用快照令牌进行更新。
  • 当宏或精确存储格式很重要时,使用无损HTML往返转换。
  • 仅在用户明确要求预览或验证,或操作风险极高且未被直接要求执行时,使用
    --dry-run
    参数。
  • 变更操作完成后,请重新读取内容或空间,并向用户报告其URL。

Handoffs

交接规则

  • Load
    twg-context-discovery
    for related Jira work, projects, goals, or dependencies; load
    twg-responsibility-routing
    for people, ownership, authority, or escalation.
  • Load
    twg-status-rollups
    when pages contribute to a broader status report.
  • Load
    twg-operational-health
    for runbooks, incidents, PIRs, or reliability evidence.
  • 若涉及相关Jira工作、项目、目标或依赖项,请加载
    twg-context-discovery
    ;若涉及人员、所有权、权限或升级流程,请加载
    twg-responsibility-routing
  • 当页面需纳入更广泛的状态报告时,请加载
    twg-status-rollups
  • 若涉及运行手册、事件、事后分析(PIRs)或可靠性证据,请加载
    twg-operational-health

References

参考文档

  • references/content.md
    - content types, reads, writes, and exports
  • references/editing.md
    - concurrency-safe body editing
  • references/spaces.md
    - space lifecycle and hierarchy
  • references/querying.md
    - CQL and fuzzy discovery
  • references/body-formats.md
    - HTML, markdown, mentions, and special formats
  • references/content.md
    - 内容类型、读取、写入及导出操作说明
  • references/editing.md
    - 并发安全的内容主体编辑指南
  • references/spaces.md
    - 空间生命周期与层级结构管理
  • references/querying.md
    - CQL查询与模糊发现方法
  • references/body-formats.md
    - HTML、Markdown、提及及特殊格式说明