Confluence Integration
Codity integrates with Confluence through linked-page retrieval and, where configured, MCP (Model Context Protocol) to pull relevant documentation into the context of pull request reviews. Codity searches your Confluence space to find requirement pages relevant to the PR and uses that content to provide more accurate, requirement-aware review feedback.
Prerequisites
- A Confluence Cloud or self-hosted Confluence instance
- An Atlassian API token with read access to the relevant Confluence spaces
- Access to the relevant pages and any MCP service required by your deployment
Setup
Step 1: Create a Confluence API Token
- Go to https://id.atlassian.com/manage-profile/security/api-tokens
- Click Create API token
- Enter a label such as
Codity Integration - Copy the token immediately: it will not be shown again
Step 2: Configure Confluence in Codity Dashboard
- Open Settings → Integrations in the Codity dashboard
- Choose Confluence
- Enter the following:
- Confluence URL: Your Confluence base URL (e.g.,
https://yourcompany.atlassian.net) - Email: The Atlassian account email associated with the API token
- API Token: The token created in Step 1
- MCP Server URL: The URL of your Confluence MCP server (e.g.,
https://mcp.example.com)
- Confluence URL: Your Confluence base URL (e.g.,
- Click Test Connection to verify the credentials
- Click Save Settings
How It Works
- For linked-page retrieval, Codity reads accessible Confluence page links from review context. When MCP is configured, it can connect to that server and retrieve its tools.
- An orchestration agent is given the PR title and description
- The agent calls MCP tools (such as
confluence_searchandconfluence_read) to find relevant documentation - The agent runs up to 3 rounds of tool calls to retrieve sufficient context
- The retrieved content is formatted and included in the review prompt
The agent extracts requirements verbatim from Confluence pages. The output format is:
CONFLUENCE REQUIREMENTS:
- <exact requirement from page>
- <exact requirement from page>
...
SOURCE: <page title>
URL: <page URL>
Token Storage and Security
- Confluence API tokens are encrypted using Fernet symmetric encryption before being stored in the database
- Tokens are never returned in plain text via the API
- All communication with Confluence uses HTTPS
- Connection tests authenticate using Basic Auth (
email:tokenbase64-encoded)
Next Steps
- Set up Jira integration to link tickets to PRs: JIRA Integration
- Configure review behavior: Auto-Review Configuration

