Async Python client for Atlassian products
Project description
Atlassian Async Client
A modern, async Python client for Atlassian products (Jira and Confluence) with comprehensive API coverage, type safety, and Pydantic models.
✨ Features
- 🚀 Full Async Support: Built with
httpxfor modern async/await operations - 🔒 Type Safety: Complete type hints and mypy strict mode compliance
- 📦 Modern Packaging: Uses
pyproject.tomland modern Python packaging standards - 🏗️ Pydantic Models: Robust data validation and serialization
- 🔍 Comprehensive Coverage: Support for both Jira and Confluence APIs
- ☁️ Flexible Authentication: Supports both Cloud and Server/Data Center deployments
- 🔄 Content Processing: Built-in preprocessing for Jira and Confluence content
- 📝 Rich Text Support: Markdown to Confluence conversion utilities
🛠️ Installation
# Using pip
pip install atlassian-async-client
# Using uv (recommended)
uv pip install atlassian-async-client
For development:
uv pip install -e ".[dev]"
🚀 Quick Start
Basic Usage
import asyncio
from atlassian_client import AtlassianClient
async def main():
async with AtlassianClient(
base_url="https://your-domain.atlassian.net",
username="your-email@example.com",
api_token="your-api-token"
) as client:
# Your API calls here
pass
if __name__ == "__main__":
asyncio.run(main())
Environment Configuration
Set up your environment variables:
# For Cloud deployment
export JIRA_URL="https://your-domain.atlassian.net"
export JIRA_USERNAME="your-email@example.com"
export JIRA_API_TOKEN="your-api-token"
# For Server/Data Center
export JIRA_URL="https://jira.your-company.com"
export JIRA_PERSONAL_TOKEN="your-personal-access-token"
Similar configuration for Confluence:
export CONFLUENCE_URL="https://your-domain.atlassian.net"
export CONFLUENCE_USERNAME="your-email@example.com"
export CONFLUENCE_API_TOKEN="your-api-token"
📚 Documentation
Jira Client
from atlassian_client import JiraClient
from atlassian_client.models.jira import JiraIssue
async with JiraClient() as jira:
# Create issue
issue = await jira.create_issue(
project_key="PROJ",
summary="Test Issue",
description="Description"
)
Confluence Client
from atlassian_client import ConfluenceClient
from atlassian_client.models.confluence import ConfluencePage
async with ConfluenceClient() as confluence:
# Create page
page = await confluence.create_page(
space_key="SPACE",
title="Page Title",
body="Content"
)
🧪 Development
- Clone the repository:
git clone https://github.com/khanhct/atlassian-async-client.git
cd atlassian-async-client
- Create virtual environment and install dependencies:
uv venv
uv pip install -e ".[dev]"
- Run tests:
pytest
- Code quality:
# Format code
black .
isort .
# Type checking
mypy .
# Linting
ruff .
🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
📝 License
This project is licensed under the MIT License - see the LICENSE file for details.
🙏 Acknowledgments
- Built on top of the atlassian-python-api package
- Uses Pydantic for data validation
- Powered by httpx for async HTTP requests
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file atlassian_client-0.1.2.tar.gz.
File metadata
- Download URL: atlassian_client-0.1.2.tar.gz
- Upload date:
- Size: 167.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.6.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
36a155fe8662b3d32c56cf1d21b9c4e9187d9a137510024e3d21235ee73a9255
|
|
| MD5 |
5717fc59130cd625a86c539ac0de7740
|
|
| BLAKE2b-256 |
0b4784a7d9b29b7ebab2f71652ce7122c493b4fb62c92540a746ab0e42bcbd48
|
File details
Details for the file atlassian_client-0.1.2-py3-none-any.whl.
File metadata
- Download URL: atlassian_client-0.1.2-py3-none-any.whl
- Upload date:
- Size: 76.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.6.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d51f6e61c9d32be3a569092a0aba5eb8ce412f32e78e732c43bcfac7a73fabde
|
|
| MD5 |
7029ce01092bb0632baafdaff03dc721
|
|
| BLAKE2b-256 |
83ae842a253d35f7038c564d5766aeae7ece0da74cf3346ed4efae24bdd66052
|