Scrapes Jira tickets assigned to you and saves each ticket to a separate file (XML by default).
Also supports changing ticket status via the Jira transitions API.
- Create a Python virtual environment and install dependencies:
python3 -m venv .venv
source .venv/bin/activate
pip install playwright
playwright install chromium- Create a
.envfile with your Jira configuration:
JIRA_BASE_URL=https://jira.example.com
JIRA_BOARD_ID=12345 # Optional: Agile board ID for sprint operations- Create a
.jira_credentials.jsonfile with your credentials:
{"username": "your.email@example.com", "password": "your-password"}See all features and examples:
./scrape-jira.sh --help./scrape-jira.sh # Fetch 100 most recent tickets (XML)
./scrape-jira.sh -n 500 # Fetch up to 500 tickets
./scrape-jira.sh --format txt # Output as plain text instead of XML
./scrape-jira.sh --status "In Progress" # Fetch only in-progress tickets
./scrape-jira.sh --status "Open" # Fetch only open tickets
./scrape-jira.sh --active-sprint # Fetch tickets in active sprint
./scrape-jira.sh --active-sprint --status "Open" # Open tickets in active sprint
./scrape-jira.sh --login # Force new login (refresh session)./scrape-jira.sh --change-status TICKET-123 --to-status "In Progress"
./scrape-jira.sh -c TICKET-123 -t "Done"The script will:
- Fetch available transitions for the ticket
- Find the transition that leads to the target status
- Execute the transition
Note: Available transitions depend on the ticket's current status and your project's workflow.
OpenIn ProgressReady for ReviewIn ReviewDoneClosed
Note: Status values are case-sensitive and may vary by project.
Tickets are organized into folders by their Jira status:
output/
├── blocked/
├── code_review/
├── completed/
├── in_progress/
├── ready_for_testing/
└── testing/
Each ticket is saved as an .xml file (or .txt with --format txt).
| Option | Short | Description |
|---|---|---|
--format FORMAT |
-f |
Output format: xml (default) or txt |
--max-results N |
-n |
Maximum tickets to fetch (default: 100) |
--status STATUS |
-s |
Filter by ticket status |
--active-sprint |
Filter by active sprint | |
--output DIR |
-o |
Output directory |
--login |
-l |
Force new login |
--headed |
Show browser window (for SSO login) |
jira_scraper.py- Main Python scraper using Playwrightscrape-jira.sh- Shell wrapper script.env- Environment configuration (not tracked in git).jira_credentials.json- Your credentials (not tracked in git).jira_cookies.json- Saved session cookies (not tracked in git)output/- Ticket files (not tracked in git)
| Variable | Required | Description |
|---|---|---|
JIRA_BASE_URL |
Yes | Base URL of your Jira instance |
JIRA_BOARD_ID |
No | Agile board ID for sprint operations |