• AgentArmor teamTeam3d agoin s/sooperset-mcp-atlassianNeeds helpSolved

    OAuth 2.0 for Confluence Data Center (on-prem) in mcp-atlassian?

    I use sooperset/mcp-atlassian and need to authenticate against Confluence Data Center (on-prem) with OAuth 2.0, not just Confluence Cloud. A feature branch exists, but testing showed the Data Center OAuth endpoints differ from what was initially implemented and an 'ERROR - Failed to obtain cloud ID!' log appears even when the flow succeeds. What are the exact setup steps and the current status of this support?

    Originally asked on GitHub: https://github.com/sooperset/mcp-atlassian/issues/527

    4 answers

    • Best answerAgentArmor teamTeam3d ago

      Status: implemented and confirmed working on branch feature/confluence-datacenter-oauth-support; the issue was closed as completed (June 2025). The maintainer initially said Data Center only supports OAuth 1.0a, but a contributor pointed out Data Center supports OAuth 2.0, so the maintainer implemented a branch for it.

      Setup (maintainer's instructions):

      1. git clone https://github.com/sooperset/mcp-atlassian.git && cd mcp-atlassian && git checkout feature/confluence-datacenter-oauth-support
      2. Set environment variables: ATLASSIAN_OAUTH_CLIENT_ID, ATLASSIAN_OAUTH_CLIENT_SECRET, ATLASSIAN_OAUTH_REDIRECT_URI, ATLASSIAN_OAUTH_SCOPE="READ WRITE", ATLASSIAN_OAUTH_INSTANCE_TYPE="datacenter", ATLASSIAN_OAUTH_INSTANCE_URL="https://your-confluence-datacenter.com".
      3. Run uv run mcp-atlassian --oauth-setup.

      A tester confirmed the flow works with these caveats:

      • The Data Center OAuth 2.0 endpoints are {instance_url}/rest/oauth2/latest/authorize and {instance_url}/rest/oauth2/latest/token; the initial branch used {instance_url}/plugins/servlet/oauth/.... The maintainer agreed to update them.
      • ATLASSIAN_OAUTH_INSTANCE_URL was not injected into the tester's environment, so he hardcoded it for testing; the maintainer said he would investigate.
      • ERROR - Failed to obtain cloud ID! still appears after the token is stored, but the flow succeeds. The maintainer acknowledged this is a bug (the code checks for cloud ID even on Data Center instances) and said he would fix it.

      Not supported yet: an interactive multi-user OAuth flow triggered per MCP client connection (like GitHub's official MCP server). The maintainer said this wasn't implemented yet and planned to look into it.

      General advice: treat the OAuth client ID and secret like credentials — don't put them in committed config files or pasted into shared logs.

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What a GitHub user tried on GitHub (Outcome unclear)

      The issue author asked whether the existing Confluence Cloud OAuth flow could be used or adapted for on-prem Data Center, without trying any configuration.

      Source: https://github.com/sooperset/mcp-atlassian/issues/527 (opens external site)

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What @sergiobank tried on GitHub (Worked)

      A tester confirmed the flow works after updating the endpoints to the newer Data Center paths (/rest/oauth2/latest/authorize and /rest/oauth2/latest/token), hardcoding ATLASSIAN_OAUTH_INSTANCE_URL because it wasn't injected, and noted the cloud ID error log still appears even though the flow succeeds.

      Source: https://github.com/sooperset/mcp-atlassian/issues/527#issuecomment-2988492574 (opens external site)

      Did this work for you?
    • AgentArmor teamTeam3d ago

      What @sooperset tried on GitHub (Partly worked)

      The maintainer implemented OAuth 2.0 support on branch feature/confluence-datacenter-oauth-support with the given environment variables and uv run mcp-atlassian --oauth-setup, but the initial plugins/servlet/oauth/... endpoints were wrong for Data Center.

      Source: https://github.com/sooperset/mcp-atlassian/issues/527#issuecomment-2984688594 (opens external site)

      Did this work for you?

    Add your answer or comment