better-confluence-mcp 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. better_confluence_mcp-0.1.0/.devcontainer/Dockerfile +3 -0
  2. better_confluence_mcp-0.1.0/.devcontainer/devcontainer.json +35 -0
  3. better_confluence_mcp-0.1.0/.devcontainer/post-create.sh +5 -0
  4. better_confluence_mcp-0.1.0/.devcontainer/post-start.sh +8 -0
  5. better_confluence_mcp-0.1.0/.dockerignore +53 -0
  6. better_confluence_mcp-0.1.0/.github/ISSUE_TEMPLATE/bug_report.yml +119 -0
  7. better_confluence_mcp-0.1.0/.github/ISSUE_TEMPLATE/config.yml +8 -0
  8. better_confluence_mcp-0.1.0/.github/ISSUE_TEMPLATE/feature_request.yml +42 -0
  9. better_confluence_mcp-0.1.0/.github/pull_request_template.md +31 -0
  10. better_confluence_mcp-0.1.0/.github/workflows/docker-publish.yml +77 -0
  11. better_confluence_mcp-0.1.0/.github/workflows/lint.yml +27 -0
  12. better_confluence_mcp-0.1.0/.github/workflows/publish.yml +41 -0
  13. better_confluence_mcp-0.1.0/.github/workflows/stale.yml +53 -0
  14. better_confluence_mcp-0.1.0/.github/workflows/tests.yml +42 -0
  15. better_confluence_mcp-0.1.0/.gitignore +80 -0
  16. better_confluence_mcp-0.1.0/.pre-commit-config.yaml +60 -0
  17. better_confluence_mcp-0.1.0/AGENTS.md +162 -0
  18. better_confluence_mcp-0.1.0/CLAUDE.md +150 -0
  19. better_confluence_mcp-0.1.0/CONTRIBUTING.md +141 -0
  20. better_confluence_mcp-0.1.0/Dockerfile +49 -0
  21. better_confluence_mcp-0.1.0/LICENSE +21 -0
  22. better_confluence_mcp-0.1.0/PKG-INFO +306 -0
  23. better_confluence_mcp-0.1.0/README.md +264 -0
  24. better_confluence_mcp-0.1.0/SECURITY.md +20 -0
  25. better_confluence_mcp-0.1.0/pyproject.toml +166 -0
  26. better_confluence_mcp-0.1.0/scripts/test_with_real_data.sh +154 -0
  27. better_confluence_mcp-0.1.0/smithery.yaml +79 -0
  28. better_confluence_mcp-0.1.0/src/mcp_atlassian/__init__.py +176 -0
  29. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/__init__.py +28 -0
  30. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/client.py +164 -0
  31. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/comments.py +149 -0
  32. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/config.py +138 -0
  33. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/constants.py +50 -0
  34. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/labels.py +79 -0
  35. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/pages.py +517 -0
  36. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/search.py +125 -0
  37. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/spaces.py +100 -0
  38. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/users.py +100 -0
  39. better_confluence_mcp-0.1.0/src/mcp_atlassian/confluence/utils.py +66 -0
  40. better_confluence_mcp-0.1.0/src/mcp_atlassian/exceptions.py +4 -0
  41. better_confluence_mcp-0.1.0/src/mcp_atlassian/local_storage.py +673 -0
  42. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/__init__.py +58 -0
  43. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/base.py +126 -0
  44. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/__init__.py +34 -0
  45. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/comment.py +89 -0
  46. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/common.py +128 -0
  47. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/label.py +62 -0
  48. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/page.py +272 -0
  49. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/search.py +74 -0
  50. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/space.py +57 -0
  51. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/confluence/user_search.py +145 -0
  52. better_confluence_mcp-0.1.0/src/mcp_atlassian/models/constants.py +36 -0
  53. better_confluence_mcp-0.1.0/src/mcp_atlassian/preprocessing/__init__.py +13 -0
  54. better_confluence_mcp-0.1.0/src/mcp_atlassian/preprocessing/base.py +223 -0
  55. better_confluence_mcp-0.1.0/src/mcp_atlassian/preprocessing/confluence.py +96 -0
  56. better_confluence_mcp-0.1.0/src/mcp_atlassian/servers/__init__.py +5 -0
  57. better_confluence_mcp-0.1.0/src/mcp_atlassian/servers/confluence.py +1500 -0
  58. better_confluence_mcp-0.1.0/src/mcp_atlassian/servers/context.py +20 -0
  59. better_confluence_mcp-0.1.0/src/mcp_atlassian/servers/dependencies.py +49 -0
  60. better_confluence_mcp-0.1.0/src/mcp_atlassian/servers/main.py +299 -0
  61. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/__init__.py +28 -0
  62. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/date.py +31 -0
  63. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/decorators.py +101 -0
  64. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/env.py +93 -0
  65. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/environment.py +41 -0
  66. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/io.py +17 -0
  67. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/lifecycle.py +74 -0
  68. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/logging.py +118 -0
  69. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/ssl.py +98 -0
  70. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/tools.py +63 -0
  71. better_confluence_mcp-0.1.0/src/mcp_atlassian/utils/urls.py +39 -0
  72. better_confluence_mcp-0.1.0/tests/README.md +273 -0
  73. better_confluence_mcp-0.1.0/tests/__init__.py +0 -0
  74. better_confluence_mcp-0.1.0/tests/conftest.py +277 -0
  75. better_confluence_mcp-0.1.0/tests/fixtures/__init__.py +0 -0
  76. better_confluence_mcp-0.1.0/tests/fixtures/confluence_mocks.py +470 -0
  77. better_confluence_mcp-0.1.0/tests/integration/README.md +135 -0
  78. better_confluence_mcp-0.1.0/tests/integration/conftest.py +30 -0
  79. better_confluence_mcp-0.1.0/tests/integration/test_authentication.py +163 -0
  80. better_confluence_mcp-0.1.0/tests/integration/test_content_processing.py +482 -0
  81. better_confluence_mcp-0.1.0/tests/integration/test_stdin_monitoring_fix.py +158 -0
  82. better_confluence_mcp-0.1.0/tests/integration/test_transport_lifecycle.py +270 -0
  83. better_confluence_mcp-0.1.0/tests/test_real_api_validation.py +384 -0
  84. better_confluence_mcp-0.1.0/tests/unit/confluence/__init__.py +1 -0
  85. better_confluence_mcp-0.1.0/tests/unit/confluence/conftest.py +637 -0
  86. better_confluence_mcp-0.1.0/tests/unit/confluence/test_client.py +262 -0
  87. better_confluence_mcp-0.1.0/tests/unit/confluence/test_comments.py +267 -0
  88. better_confluence_mcp-0.1.0/tests/unit/confluence/test_config.py +163 -0
  89. better_confluence_mcp-0.1.0/tests/unit/confluence/test_constants.py +96 -0
  90. better_confluence_mcp-0.1.0/tests/unit/confluence/test_custom_headers.py +154 -0
  91. better_confluence_mcp-0.1.0/tests/unit/confluence/test_labels.py +129 -0
  92. better_confluence_mcp-0.1.0/tests/unit/confluence/test_pages.py +900 -0
  93. better_confluence_mcp-0.1.0/tests/unit/confluence/test_search.py +566 -0
  94. better_confluence_mcp-0.1.0/tests/unit/confluence/test_spaces.py +167 -0
  95. better_confluence_mcp-0.1.0/tests/unit/confluence/test_users.py +568 -0
  96. better_confluence_mcp-0.1.0/tests/unit/confluence/test_utils.py +57 -0
  97. better_confluence_mcp-0.1.0/tests/unit/models/__init__.py +0 -0
  98. better_confluence_mcp-0.1.0/tests/unit/models/conftest.py +329 -0
  99. better_confluence_mcp-0.1.0/tests/unit/models/test_base_models.py +108 -0
  100. better_confluence_mcp-0.1.0/tests/unit/models/test_confluence_models.py +662 -0
  101. better_confluence_mcp-0.1.0/tests/unit/models/test_constants.py +89 -0
  102. better_confluence_mcp-0.1.0/tests/unit/servers/__init__.py +0 -0
  103. better_confluence_mcp-0.1.0/tests/unit/servers/test_confluence_server.py +308 -0
  104. better_confluence_mcp-0.1.0/tests/unit/servers/test_context.py +261 -0
  105. better_confluence_mcp-0.1.0/tests/unit/servers/test_dependencies.py +159 -0
  106. better_confluence_mcp-0.1.0/tests/unit/servers/test_main_server.py +16 -0
  107. better_confluence_mcp-0.1.0/tests/unit/test_exceptions.py +201 -0
  108. better_confluence_mcp-0.1.0/tests/unit/test_main_transport_selection.py +119 -0
  109. better_confluence_mcp-0.1.0/tests/unit/utils/__init__.py +1 -0
  110. better_confluence_mcp-0.1.0/tests/unit/utils/test_custom_headers.py +175 -0
  111. better_confluence_mcp-0.1.0/tests/unit/utils/test_date.py +39 -0
  112. better_confluence_mcp-0.1.0/tests/unit/utils/test_decorators.py +36 -0
  113. better_confluence_mcp-0.1.0/tests/unit/utils/test_env.py +217 -0
  114. better_confluence_mcp-0.1.0/tests/unit/utils/test_environment.py +160 -0
  115. better_confluence_mcp-0.1.0/tests/unit/utils/test_io.py +83 -0
  116. better_confluence_mcp-0.1.0/tests/unit/utils/test_lifecycle.py +170 -0
  117. better_confluence_mcp-0.1.0/tests/unit/utils/test_logging.py +64 -0
  118. better_confluence_mcp-0.1.0/tests/unit/utils/test_masking.py +67 -0
  119. better_confluence_mcp-0.1.0/tests/unit/utils/test_ssl.py +165 -0
  120. better_confluence_mcp-0.1.0/tests/unit/utils/test_tools.py +73 -0
  121. better_confluence_mcp-0.1.0/tests/unit/utils/test_urls.py +74 -0
  122. better_confluence_mcp-0.1.0/tests/utils/__init__.py +1 -0
  123. better_confluence_mcp-0.1.0/tests/utils/assertions.py +88 -0
  124. better_confluence_mcp-0.1.0/tests/utils/base.py +54 -0
  125. better_confluence_mcp-0.1.0/tests/utils/factories.py +68 -0
  126. better_confluence_mcp-0.1.0/tests/utils/mocks.py +114 -0
  127. better_confluence_mcp-0.1.0/uv.lock +1889 -0
@@ -0,0 +1,3 @@
1
+ FROM "mcr.microsoft.com/devcontainers/python:3.10"
2
+ RUN curl -LsSf https://astral.sh/uv/install.sh | env UV_INSTALL_DIR="/usr/local/bin" sh
3
+ ENV UV_LINK_MODE=copy
@@ -0,0 +1,35 @@
1
+ // For format details, see https://aka.ms/devcontainer.json. For config options, see the
2
+ // README at: https://github.com/devcontainers/templates/tree/main/src/python
3
+ {
4
+ "name": "Python 3 Project",
5
+ // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6
+ //"image": "mcr.microsoft.com/devcontainers/python:3",
7
+ "build": {
8
+ "dockerfile": "Dockerfile"
9
+ },
10
+ "containerEnv": {
11
+ "PYTHONPATH": "./src"
12
+ },
13
+ // Features to add to the dev container. More info: https://containers.dev/features.
14
+ "features": {
15
+ "ghcr.io/devcontainers/features/node:1": {}
16
+ },
17
+ // Use 'forwardPorts' to make a list of ports inside the container available locally.
18
+ "forwardPorts": [
19
+ 3000
20
+ ],
21
+ // Use 'postCreateCommand' to run commands after the container is created.
22
+ "postCreateCommand": ".devcontainer/post-create.sh",
23
+ "postStartCommand": ".devcontainer/post-start.sh",
24
+ // Configure tool-specific properties.
25
+ "customizations": {
26
+ "vscode": {
27
+ "extensions": [
28
+ "ms-python.mypy-type-checker",
29
+ "charliermarsh.ruff"
30
+ ]
31
+ }
32
+ }
33
+ // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
34
+ // "remoteUser": "root"
35
+ }
@@ -0,0 +1,5 @@
1
+ #! /bin/bash
2
+ set -xe
3
+
4
+ uv venv
5
+ source .venv/bin/activate
@@ -0,0 +1,8 @@
1
+ #! /bin/bash
2
+
3
+ set -xe
4
+
5
+ source .venv/bin/activate
6
+
7
+ uv sync --frozen --all-extras --dev
8
+ pre-commit install
@@ -0,0 +1,53 @@
1
+ # Version control
2
+ .git
3
+ .gitignore
4
+ .github
5
+
6
+ # Virtual environments
7
+ .venv*
8
+ venv*
9
+ env*
10
+
11
+ # Python bytecode/cache
12
+ __pycache__/
13
+ *.py[cod]
14
+ *$py.class
15
+ .pytest_cache
16
+ .coverage
17
+ .mypy_cache
18
+ .ruff_cache
19
+
20
+ # Build artifacts
21
+ dist/
22
+ build/
23
+ *.egg-info/
24
+
25
+ # IDE and editor files
26
+ .vscode/
27
+ .idea/
28
+ *.swp
29
+ *.swo
30
+ .DS_Store
31
+
32
+ # Environment variables and secrets
33
+ .env*
34
+ *.env
35
+ *.key
36
+
37
+ # Logs
38
+ *.log
39
+
40
+ # Docker related
41
+ Dockerfile*
42
+ docker-compose*
43
+ .dockerignore
44
+
45
+ # Documentation
46
+ docs/
47
+ *.md
48
+ !README.md
49
+
50
+ # Temporal and backup files
51
+ *.tmp
52
+ *.bak
53
+ *.backup
@@ -0,0 +1,119 @@
1
+ name: "\U0001F41B Bug Report"
2
+ description: Create a report to help us improve better-confluence-mcp
3
+ title: "[Bug]: "
4
+ labels: ["bug"]
5
+ body:
6
+ - type: markdown
7
+ attributes:
8
+ value: |
9
+ Thanks for taking the time to fill out this bug report! Please provide as much detail as possible.
10
+ - type: checkboxes
11
+ id: prerequisites
12
+ attributes:
13
+ label: Prerequisites
14
+ description: Please confirm the following before submitting the issue.
15
+ options:
16
+ - label: I have searched the [existing issues](https://github.com/twinity1/better-confluence-mcp/issues) to make sure this bug has not already been reported.
17
+ required: true
18
+ - label: I have checked the [README](https://github.com/twinity1/better-confluence-mcp/blob/main/README.md) for relevant information.
19
+ required: true
20
+ - type: textarea
21
+ id: description
22
+ attributes:
23
+ label: Bug Description
24
+ description: A clear and concise description of what the bug is.
25
+ placeholder: "When I call the `sync_space` tool with..., it fails with..."
26
+ validations:
27
+ required: true
28
+ - type: textarea
29
+ id: steps-to-reproduce
30
+ attributes:
31
+ label: Steps to Reproduce
32
+ description: Provide detailed steps to reproduce the behavior.
33
+ placeholder: |
34
+ 1. Start the server with command `...`
35
+ 2. Send a `list_tools` request using `...`
36
+ 3. Call the tool `xyz` with arguments `...`
37
+ 4. See error `...`
38
+ validations:
39
+ required: true
40
+ - type: textarea
41
+ id: expected-behavior
42
+ attributes:
43
+ label: Expected Behavior
44
+ description: A clear and concise description of what you expected to happen.
45
+ placeholder: "I expected the Confluence space to be synced successfully."
46
+ validations:
47
+ required: true
48
+ - type: textarea
49
+ id: actual-behavior
50
+ attributes:
51
+ label: Actual Behavior
52
+ description: What actually happened? Include full error messages, logs (from the server and the client if possible), or screenshots.
53
+ placeholder: "The server returned an error message: '...' / The tool call returned an empty list."
54
+ render: shell
55
+ validations:
56
+ required: true
57
+ - type: input
58
+ id: version
59
+ attributes:
60
+ label: better-confluence-mcp Version
61
+ description: Which version of `better-confluence-mcp` are you using?
62
+ placeholder: "e.g., 0.6.5"
63
+ validations:
64
+ required: true
65
+ - type: dropdown
66
+ id: installation
67
+ attributes:
68
+ label: Installation Method
69
+ description: How did you install `better-confluence-mcp`?
70
+ options:
71
+ - From PyPI (pip install better-confluence-mcp / uvx better-confluence-mcp)
72
+ - From source (git clone)
73
+ - Docker
74
+ - Other
75
+ validations:
76
+ required: true
77
+ - type: dropdown
78
+ id: os
79
+ attributes:
80
+ label: Operating System
81
+ description: What operating system are you using?
82
+ options:
83
+ - Windows
84
+ - macOS
85
+ - Linux (Specify distribution below if relevant)
86
+ - Other
87
+ validations:
88
+ required: true
89
+ - type: input
90
+ id: python-version
91
+ attributes:
92
+ label: Python Version
93
+ description: What version of Python are you using? (`python --version`)
94
+ placeholder: "e.g., 3.11.4"
95
+ validations:
96
+ required: true
97
+ - type: dropdown
98
+ id: atlassian-instance
99
+ attributes:
100
+ label: Confluence Instance Type
101
+ description: Are you connecting to Confluence Cloud or Server/Data Center?
102
+ options:
103
+ - Confluence Cloud
104
+ - Confluence Server / Data Center
105
+ validations:
106
+ required: true
107
+ - type: input
108
+ id: client-app
109
+ attributes:
110
+ label: Client Application
111
+ description: What application/library are you using to interact with the MCP server? (This is important!)
112
+ placeholder: "e.g., Claude Code, Cursor, Windsurf, custom script"
113
+ validations:
114
+ required: true
115
+ - type: textarea
116
+ id: additional-context
117
+ attributes:
118
+ label: Additional Context
119
+ description: Add any other context about the problem here (e.g., environment variables, network configuration like proxies, specific Confluence setup).
@@ -0,0 +1,8 @@
1
+ blank_issues_enabled: false
2
+ contact_links:
3
+ - name: "\U0001F4AC Ask a Question or Discuss"
4
+ url: https://github.com/sooperset/mcp-atlassian/discussions # GitHub Discussions 링크 (활성화되어 있다면)
5
+ about: Please ask and answer questions here, or start a general discussion.
6
+ - name: "\U0001F4DA Read the Documentation"
7
+ url: https://github.com/sooperset/mcp-atlassian/blob/main/README.md
8
+ about: Check the README for setup and usage instructions.
@@ -0,0 +1,42 @@
1
+ name: "\U0001F680 Feature Request"
2
+ description: Suggest an idea or enhancement for mcp-atlassian
3
+ title: "[Feature]: "
4
+ labels: ["enhancement"]
5
+ body:
6
+ - type: markdown
7
+ attributes:
8
+ value: |
9
+ Thanks for suggesting an idea! Please describe your proposal clearly.
10
+ - type: textarea
11
+ id: problem
12
+ attributes:
13
+ label: Is your feature request related to a problem? Please describe.
14
+ description: A clear and concise description of what the problem is.
15
+ placeholder: "e.g., I'm always frustrated when [...] because [...]"
16
+ validations:
17
+ required: true
18
+ - type: textarea
19
+ id: solution
20
+ attributes:
21
+ label: Describe the solution you'd like
22
+ description: A clear and concise description of what you want to happen. How should the feature work?
23
+ placeholder: "Add a new tool `confluence_move_page` that takes `page_id` and `target_parent_id` arguments..."
24
+ validations:
25
+ required: true
26
+ - type: textarea
27
+ id: alternatives
28
+ attributes:
29
+ label: Describe alternatives you've considered
30
+ description: A clear and concise description of any alternative solutions or features you've considered.
31
+ placeholder: "I considered modifying the `confluence_update_page` tool, but..."
32
+ - type: textarea
33
+ id: use-case
34
+ attributes:
35
+ label: Use Case
36
+ description: How would this feature benefit users? Who is the target audience?
37
+ placeholder: "This would allow AI agents to automatically organize documentation..."
38
+ - type: textarea
39
+ id: additional-context
40
+ attributes:
41
+ label: Additional Context
42
+ description: Add any other context, mockups, or links about the feature request here.
@@ -0,0 +1,31 @@
1
+ <!-- Thank you for your contribution! Please provide a brief summary. -->
2
+
3
+ ## Description
4
+
5
+ <!-- What does this PR do? Why is it needed? -->
6
+ <!-- Link related issues: Fixes #<issue_number> -->
7
+
8
+ Fixes: #
9
+
10
+ ## Changes
11
+
12
+ <!-- Briefly list the key changes made. -->
13
+
14
+ -
15
+ -
16
+ -
17
+
18
+ ## Testing
19
+
20
+ <!-- How did you test these changes? (e.g., unit tests, integration tests, manual checks) -->
21
+
22
+ - [ ] Unit tests added/updated
23
+ - [ ] Integration tests passed
24
+ - [ ] Manual checks performed: `[briefly describe]`
25
+
26
+ ## Checklist
27
+
28
+ - [ ] Code follows project style guidelines (linting passes).
29
+ - [ ] Tests added/updated for changes.
30
+ - [ ] All tests pass locally.
31
+ - [ ] Documentation updated (if needed).
@@ -0,0 +1,77 @@
1
+ name: Docker Publish
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - 'v*.*.*' # Trigger on version tag pushes (e.g., v0.7.1)
7
+ pull_request:
8
+ branches:
9
+ - main # Trigger on PRs targeting main branch
10
+ workflow_dispatch: {} # Allow manual triggering from the Actions tab
11
+
12
+ env:
13
+ REGISTRY: ghcr.io
14
+ IMAGE_NAME: ${{ github.repository }}
15
+
16
+ jobs:
17
+ build-and-push:
18
+ runs-on: ubuntu-latest
19
+ permissions:
20
+ contents: read # Needed for checkout
21
+ packages: write # Needed to push packages to ghcr.io
22
+
23
+ steps:
24
+ - name: Checkout repository
25
+ uses: actions/checkout@v4
26
+
27
+ - name: Set up QEMU
28
+ uses: docker/setup-qemu-action@v3
29
+ with:
30
+ platforms: arm64,amd64
31
+
32
+ - name: Set up Docker Buildx
33
+ uses: docker/setup-buildx-action@v3
34
+
35
+ # Extract metadata (tags, labels) for Docker
36
+ - name: Extract Docker metadata
37
+ id: meta
38
+ uses: docker/metadata-action@v5
39
+ with:
40
+ images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
41
+ tags: |
42
+ # Create 'main' tag on push to main branch
43
+ type=ref,event=branch,branch=main
44
+ # Create 'X.Y.Z', 'X.Y', 'X' tags on tag push (e.g., v1.2.3 -> 1.2.3, 1.2, 1)
45
+ type=semver,pattern={{version}}
46
+ type=semver,pattern={{major}}.{{minor}}
47
+ type=semver,pattern={{major}}
48
+ # Only create 'latest' tag if it's a tag push AND it's a non-prerelease version tag (no '-')
49
+ type=raw,value=latest,enable=${{ github.ref_type == 'tag' && startsWith(github.ref, 'refs/tags/v') && !contains(github.ref, '-') }}
50
+ # Create a tag for PRs (e.g., pr-123) - useful for testing PR builds
51
+ type=ref,event=pr
52
+ # For manual workflow runs, use branch name with 'manual' suffix
53
+ type=raw,value={{branch}}-manual,enable=${{ github.event_name == 'workflow_dispatch' }}
54
+
55
+ - name: Log in to GitHub Container Registry
56
+ uses: docker/login-action@v3
57
+ # Only login for pushes and manual runs, not for PRs
58
+ if: github.event_name != 'pull_request'
59
+ with:
60
+ registry: ${{ env.REGISTRY }}
61
+ username: ${{ github.actor }}
62
+ password: ${{ secrets.GITHUB_TOKEN }}
63
+
64
+ - name: Build and push Docker image
65
+ id: docker_build
66
+ uses: docker/build-push-action@v5
67
+ with:
68
+ context: .
69
+ platforms: linux/amd64,linux/arm64
70
+ # Only push for non-PR events
71
+ push: ${{ github.event_name != 'pull_request' }}
72
+ # Use tags and labels from metadata action
73
+ tags: ${{ steps.meta.outputs.tags }}
74
+ labels: ${{ steps.meta.outputs.labels }}
75
+ # Enable Docker layer caching
76
+ cache-from: type=gha
77
+ cache-to: type=gha,mode=max
@@ -0,0 +1,27 @@
1
+ name: Lint
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [ main ]
6
+ push:
7
+ branches: [ main ]
8
+
9
+ jobs:
10
+ lint:
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - uses: actions/checkout@v4
14
+
15
+ - name: Set up Python
16
+ uses: actions/setup-python@v5
17
+ with:
18
+ python-version: '3.10'
19
+ cache: 'pip'
20
+
21
+ - name: Install dependencies
22
+ run: |
23
+ python -m pip install --upgrade pip
24
+ pip install .[dev]
25
+
26
+ - name: Run pre-commit
27
+ uses: pre-commit/action@v3.0.0
@@ -0,0 +1,41 @@
1
+ # .github/workflows/publish.yml
2
+ name: Publish MCP-Atlassian to PyPI
3
+
4
+ on:
5
+ release:
6
+ types: [published] # Triggers when a GitHub Release is published
7
+ workflow_dispatch: # Allows manual triggering
8
+
9
+ jobs:
10
+ pypi-publish:
11
+ name: Upload release to PyPI
12
+ runs-on: ubuntu-latest
13
+ environment:
14
+ name: pypi
15
+ url: https://pypi.org/p/mcp-atlassian # Link to your PyPI package
16
+ permissions:
17
+ id-token: write # Necessary for PyPI's trusted publishing
18
+
19
+ steps:
20
+ - name: Checkout repository
21
+ uses: actions/checkout@v4
22
+ with:
23
+ fetch-depth: 0 # Required for uv-dynamic-versioning to get tags
24
+
25
+ - name: Set up Python
26
+ uses: actions/setup-python@v5
27
+ with:
28
+ python-version: "3.10" # Or your minimum supported Python
29
+
30
+ - name: Install uv
31
+ uses: astral-sh/setup-uv@v3
32
+ with:
33
+ enable-cache: true
34
+
35
+ - name: Build package
36
+ run: uv build
37
+
38
+ - name: Publish package to PyPI
39
+ run: uv publish --token ${{ secrets.PYPI_API_TOKEN }} dist/*
40
+ # If using trusted publishing (recommended), remove --token and configure it in PyPI:
41
+ # run: uv publish dist/*
@@ -0,0 +1,53 @@
1
+ name: 'Manage Stale Issues and PRs'
2
+
3
+ on:
4
+ schedule:
5
+ # Runs daily at midnight UTC
6
+ - cron: '0 0 * * *'
7
+ workflow_dispatch:
8
+
9
+ permissions:
10
+ issues: write
11
+ pull-requests: write
12
+
13
+ jobs:
14
+ stale:
15
+ runs-on: ubuntu-latest
16
+ steps:
17
+ - uses: actions/stale@v9
18
+ with:
19
+ # === Core Timing Settings ===
20
+ days-before-stale: 14 # Start with 2 weeks
21
+ days-before-close: -1 # Disable automatic closing initially
22
+
23
+ # === Labels ===
24
+ stale-issue-label: 'stale'
25
+ stale-pr-label: 'stale'
26
+
27
+ # === Bot Messages ===
28
+ stale-issue-message: >
29
+ This issue has been automatically marked as stale because it has not had
30
+ recent activity for 14 days. It will be closed if no further activity occurs.
31
+ Please leave a comment or remove the 'stale' label if you believe this issue is still relevant.
32
+ Thank you for your contributions!
33
+ stale-pr-message: >
34
+ This pull request has been automatically marked as stale because it has not had
35
+ recent activity for 14 days. It will be closed if no further activity occurs.
36
+ Please leave a comment or remove the 'stale' label if you believe this PR is still relevant.
37
+ Thank you for your contributions!
38
+
39
+ # === Exemptions ===
40
+ exempt-issue-labels: 'pinned,security,good first issue,help wanted,bug,enhancement,feature request,documentation,awaiting-user-feedback,needs-investigation'
41
+ exempt-pr-labels: 'pinned,security,work-in-progress,awaiting-review,do-not-merge'
42
+ exempt-all-milestones: true
43
+ exempt-all-assignees: false # Consider if most issues should have assignees
44
+ exempt-draft-pr: true
45
+
46
+ # === Behavior Control ===
47
+ remove-stale-when-updated: true
48
+ operations-per-run: 30
49
+ debug-only: false
50
+ delete-branch: false
51
+
52
+ # --- Statistics ---
53
+ enable-statistics: true
@@ -0,0 +1,42 @@
1
+ # .github/workflows/tests.yml
2
+
3
+ name: Run Tests
4
+
5
+ on:
6
+ push:
7
+ branches: [ main ]
8
+ pull_request:
9
+ branches: [ main ]
10
+
11
+ jobs:
12
+ test:
13
+ name: Run pytest on Python ${{ matrix.python-version }}
14
+ runs-on: ubuntu-latest
15
+ strategy:
16
+ fail-fast: false
17
+ matrix:
18
+ python-version: ["3.10", "3.11", "3.12"]
19
+
20
+ steps:
21
+ - name: Checkout repository
22
+ uses: actions/checkout@v4
23
+
24
+ - name: Set up Python ${{ matrix.python-version }}
25
+ uses: actions/setup-python@v5
26
+ with:
27
+ python-version: ${{ matrix.python-version }}
28
+
29
+ - name: Install uv
30
+ uses: astral-sh/setup-uv@v5
31
+ with:
32
+ version: "0.6.10"
33
+ cache: true
34
+
35
+ - name: Install dependencies
36
+ run: uv sync --frozen --all-extras --dev
37
+
38
+ - name: Run tests with pytest
39
+ # Add -v for verbose output, helpful in CI
40
+ # Add basic coverage reporting to terminal logs
41
+ # Skip real API validation tests as they require credentials
42
+ run: uv run pytest -v -k "not test_real_api_validation" --cov=src/mcp_atlassian --cov-report=term-missing
@@ -0,0 +1,80 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[cod]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # Environments
30
+ .env
31
+ .env.*
32
+ .venv
33
+ env/
34
+ venv/
35
+ ENV/
36
+ env.bak/
37
+ venv.bak/
38
+
39
+ # uv/uvx specific
40
+ .uv/
41
+ .uvx/
42
+ .venv.uv/
43
+
44
+ # IDEs and editors
45
+ .idea/
46
+ .vscode/
47
+ *.swp
48
+ *.swo
49
+ *~
50
+
51
+ # OS specific
52
+ .DS_Store
53
+ Thumbs.db
54
+
55
+ # Debug and local development
56
+ debug/
57
+ local/
58
+
59
+ # Credentials
60
+ .pypirc
61
+
62
+ # Pytest
63
+ .pytest_cache/
64
+ .coverage/
65
+ .coverage
66
+
67
+ # Pre-commit
68
+ .pre-commit-config.yaml.cache
69
+
70
+ # debug
71
+ playground/
72
+
73
+ # cursor
74
+ .cursor*
75
+
76
+ # Claude
77
+ .claude/
78
+
79
+ # Local Confluence cache
80
+ .better-confluence-mcp/