confluence-operations
Skill2 starsChanged 22 days agoMITView on GitHub
Upload a local markdown file to a Confluence page, or download a Confluence page to a local markdown file. Use when the user wants to publish/sync a markdown file to Confluence, or fetch an existing Confluence page for offline editing.
- Reads credentials
In this repository14 other files it gives its agents.
- AGENTS.mdAGENTS.md
- devto-articleSkill
- download-website-to-markdownSkill
- english-tech-blog-structureSkill
- linkedin-articleSkill
- llm-evaluationSkill
- md-deckSkill
- pdf-to-markdownSkill
- repo-security-auditSkill
- sales-agentSkill
- threat-model-attack-reviewSkill
- visual-colorSkill
- visual-diagramSkill
- zenn-articleSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 48
If --page-id is given, that page is updated directly — no title search is performed.
- Distinctive: line 50
If no matching page exists, a new page is created.
- Very specific: line 96
If the output path already exists, a numeric suffix is appended (e.g.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Prerequisites
Set the following environment variables in agent_skills/.env:
CONFLUENCE_BASE_URL=https://yourorg.atlassian.net
CONFLUENCE_EMAIL=you@example.com
CONFLUENCE_API_TOKEN=your_api_token # from id.atlassian.com/manage-profile/security/api-tokens
CONFLUENCE_SPACE_KEY=MYSPACEUpload — scripts/upload.ts
Upload a local markdown file to Confluence as a page (create or update).
Usage
cd agent_skills
npx tsx confluence-operations/scripts/upload.ts <markdown-file> [options]Arguments
| Argument | Required | Description |
markdown-file | Yes | Path to the local .md file to upload |
--title "Title" | No | Page title. Defaults to the first H1 heading in the file, or the filename if no H1 exists. |
--parent-id 12345 | No | Confluence page ID to nest the new page under |
--page-id 99999 | No | Update a specific existing page by ID (bypasses title search; also allows renaming the title) |
Behavior
- The first
#heading in the markdown file is extracted as the page title and stripped from the body (Confluence displays the title separately). - A Table of Contents macro is automatically prepended to the page body.
- If
--page-idis given, that page is updated directly — no title search is performed. - Otherwise, if a page with the same title already exists in the space, it is updated (new version).
- If no matching page exists, a new page is created.
- Markdown is converted to HTML (Confluence storage format) before upload.
Examples
# Create or update a page (title taken from first H1)
npx tsx confluence-operations/scripts/upload.ts reports/gpa-framework-guide-ja.md
# Nest under a parent page
npx tsx confluence-operations/scripts/upload.ts reports/overview-ja.md --parent-id 4890951685
# Update a specific page by ID (safe rename: avoids duplicate page on title change)
npx tsx confluence-operations/scripts/upload.ts reports/overview-ja.md --page-id 5940019259
# Override the title
npx tsx confluence-operations/scripts/upload.ts notes.md --title "Agent Eval Notes" --parent-id 98765Download — scripts/download.ts
Download a Confluence page and save it as a local markdown file.
Usage
cd agent_skills
npx tsx confluence-operations/scripts/download.ts <page-id> [output]Arguments
| Argument | Required | Description |
page-id | Yes | Confluence page ID (numeric, visible in the page URL) |
output | No | Output .md path or directory. Derived from the page title if omitted. |
Behavior
- Fetches the page body in Confluence storage format (HTML) via the REST API.
- Converts HTML to Markdown using Turndown (headings, tables, lists, code blocks preserved).
- Confluence macros (TOC, panels, etc.) are stripped.
- Prepends YAML front matter with
source,page_id, andfetchedfields. - The page title is added as the first
# H1heading in the file. - If the output path already exists, a numeric suffix is appended (e.g.
page-2.md).
Examples
# Derive filename from page title → saves to: my-page-title.md
npx tsx confluence-operations/scripts/download.ts 5940019259
# Save to a specific path
npx tsx confluence-operations/scripts/download.ts 5940019259 outputs/snowflake/my-page.md
# Save into a directory (filename derived from page title)
npx tsx confluence-operations/scripts/download.ts 5940019259 outputs/snowflake/Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

