/install confluence-cli
confcli
CLI for Confluence Cloud.
Installation
Check if confcli is installed:
command -v confcli
If not installed, install via:
curl -fsSL https://raw.githubusercontent.com/hochej/confcli/main/install.sh | sh
To install a specific version or to a custom directory:
curl -fsSL https://raw.githubusercontent.com/hochej/confcli/main/install.sh | VERSION=0.2.3 sh
curl -fsSL https://raw.githubusercontent.com/hochej/confcli/main/install.sh | INSTALL_DIR=~/.bin sh
Authentication
Check auth status first:
confcli auth status
If not authenticated, ask the user to configure authentication. They can either:
- Run
confcli auth logininteractively in their own terminal, or - Set environment variables before starting the session:
CONFLUENCE_DOMAIN— e.g.yourcompany.atlassian.netCONFLUENCE_EMAILCONFLUENCE_TOKEN(orCONFLUENCE_API_TOKEN)
API tokens are generated at https://id.atlassian.com/manage-profile/security/api-tokens
Never ask the user to paste a token into the conversation. Tokens must be set via environment variables or
confcli auth login.
Page References
Pages can be referenced by:
- ID:
12345 - URL:
https://company.atlassian.net/wiki/spaces/MFS/pages/12345/Title - Space:Title:
MFS:Overview
Important
Write operations (create, update, delete, purge, edit, label add/remove, attachment upload/delete, comment add/delete, copy-tree) require explicit user intent. Never perform these based on assumptions.
Use --dry-run to preview destructive operations without executing them.
Common Commands
# Spaces
confcli space list
confcli space get MFS
confcli space pages MFS --tree
confcli space create --key PROJ --name "Project" -o json --compact-json
confcli space delete MFS --yes
# Pages
confcli page list --space MFS --title "Overview"
confcli page get MFS:Overview # metadata (table)
confcli page get MFS:Overview --show-body # include body in table output
confcli page get MFS:Overview -o json # full JSON
confcli page body MFS:Overview # markdown content
confcli page body MFS:Overview --format storage
confcli page children MFS:Overview
confcli page children MFS:Overview --recursive
confcli page history MFS:Overview
confcli page open MFS:Overview # open in browser
confcli page edit MFS:Overview # edit in $EDITOR
# Search
confcli search "query"
confcli search "type=page AND title ~ Template"
confcli search "confluence" --space MFS
# Write
confcli page create --space MFS --title "Title" --body "\x3Cp>content\x3C/p>"
confcli page update MFS:Overview --body-file content.html
confcli page delete 12345
# Attachments
confcli attachment list MFS:Overview
confcli attachment upload MFS:Overview ./file.png ./other.pdf
confcli attachment download att12345 --dest file.png
# Labels
confcli label add MFS:Overview tag1 tag2 tag3
confcli label remove MFS:Overview tag1 tag2
confcli label pages "tag"
# Comments
confcli comment list MFS:Overview
confcli comment add MFS:Overview --body "LGTM"
confcli comment delete 123456
# Export
confcli export MFS:Overview --dest ./exports --format md
# Copy Tree
confcli copy-tree MFS:Overview MFS:TargetParent
Output Formats
Use -o flag: json, table, md
confcli space list -o json
confcli page get MFS:Overview -o json
Pagination
Add --all to fetch all results, -n to set limit:
confcli space list --all
confcli search "query" --all -n 100
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install confluence-cli - 安装完成后,直接呼叫该 Skill 的名称或使用
/confluence-cli触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
Confluence CLI (confcli) 是什么?
Interact with Confluence Cloud from the command line. Use when reading, creating, updating, or searching Confluence pages, managing attachments, labels, comments, or exporting content. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 1021 次。
如何安装 Confluence CLI (confcli)?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install confluence-cli」即可一键安装,无需额外配置。
Confluence CLI (confcli) 是免费的吗?
是的,Confluence CLI (confcli) 完全免费(开源免费),可自由下载、安装和使用。
Confluence CLI (confcli) 支持哪些平台?
Confluence CLI (confcli) 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Confluence CLI (confcli)?
由 hochej(@hochej)开发并维护,当前版本 v0.2.5。