Publishes a Markdown file to a Confluence page, uploads referenced images, and converts Mermaid blocks to images.
- .NET SDK
- Mermaid CLI (
mmdc) available on PATH, or pass--mermaid-cliwith its full path
Create a credentials.json file:
{
"baseUrl": "https://your-domain.atlassian.net/wiki",
"username": "your-email@example.com",
"apiToken": "your-api-token"
}Use --save-credentials to write credentials from the command line to the file.
dotnet run --project ConfluencePublisher -- \
--markdown docs/example.md \
--space SPACEKEY \
--title "Page Title" \
--parent-id 123456 \
--credentials-file credentials.jsonOptional arguments:
--page-iduse a specific page ID--base-urloverride Confluence base URL--usernameoverride username--api-tokenoverride API token--log-filewrite logs to a specific path--mermaid-clipath tommdc--save-credentialssave current credentials to the file