# Confluence To Markdown

Internal fetcher module for Confluence pages.

- Repository: https://github.com/ccplugins/awesome-claude-code-plugins (991 stars)
- Category: AI and agents
- License: Apache-2.0
- Last updated: 2026-08-12
- Runs scripts: yes, review before use

## Install

Claude Code: `npx skills add ccplugins/awesome-claude-code-plugins --skill confluence-to-markdown -g -a claude-code -y`
Codex: `npx skills add ccplugins/awesome-claude-code-plugins --skill confluence-to-markdown -g -a codex -y`
Cursor: `npx skills add ccplugins/awesome-claude-code-plugins --skill confluence-to-markdown -g -a cursor -y`
Gemini CLI: `npx skills add ccplugins/awesome-claude-code-plugins --skill confluence-to-markdown -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add ccplugins/awesome-claude-code-plugins`

## Description

Internal fetcher module for Confluence pages. Fetches content via Atlassian MCP (preferred), REST API with Basic Auth (fallback), or browser DOM extraction via Claude in Chrome (last resort) and returns Markdown. Used by /bedrock:teach and /bedrock:sync, not intended for direct user invocation.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Confluence Fetcher

Internal module, invoked by `/bedrock:teach` Phase 1 and `/bedrock:sync` Phase 2, not user-invocable.

Fetches a Confluence page and returns its content as Markdown. Three layers in fallback order:
**MCP (preferred) → REST API → Browser DOM extraction.**

**Dependency:** Browser fallback (Layer 3) requires `scripts/extract.js` (relative to this skill directory).

---

## Step 1, Parse URL

Parse the Confluence URL. Accept these formats:
- `https://<domain>.atlassian.net/wiki/spaces/<spaceKey>/pages/<pageId>/<title>`
- `https://<domain>.atlassian.net/wiki/spaces/<spaceKey>/pages/<pageId>`
- `https://<domain>.atlassian.net/wiki/x/<shortlink>`
- `https://<domain>.atlassian.net/wiki/pages/viewpage.action?pageId=<pageId>`

Extract:
- **Base URL**: `https://<domain>.atlassian.net` (everything before `/wiki/...`)
- **Page ID**: the numeric ID from the URL path (segment after `/pages/`) or `pageId` query parameter
- **Full URL**: the original URL as provided (needed for browser fallback)

---

## Step 2, Layer 1: MCP (Atlassian)

The preferred layer. Uses the `plugin:atlassian:atlassian` MCP server if installed and authenticated.

### 2.1 Check MCP availability

Use ToolSearch to check if Atlassian MCP tools are available:

```
ToolSearch(query: "atlassian confluence page", max_results: 5)
```

Evaluate the result:

- **MCP tools found and functional** (tools other than `authenticate` and `complete_authentication` are available) → proceed to **2.2 Fetch via MCP**
- **Only `authenticate` / `complete_authentication` tools found** (MCP installed but not authenticated) → proceed to **2.3 Guide authentication**
- **No Atlassian MCP tools found** → log and fall through:

> **MCP not available:** No Atlassian MCP server installed.
> Install the Atlassian MCP plugin for Claude Code to enable direct Confluence access.
> Falling back to API (Layer 2).

### 2.2 Fetch via MCP

The rest: https://github.com/ccplugins/awesome-claude-code-plugins/blob/HEAD/plugins/bedrock/skills/confluence-to-markdown/SKILL.md
