Jira Weekly Summary

 import logging
import requests
from datetime import datetime, timedelta
import json
from pprint import pprint

logger = logging.getLogger(__name__)
logging.basicConfig(level=logging.WARNING)


def format_ticket(ticket):
    formatted_ticket = {
        "Ticket ID": ticket['id'],
        "Key": ticket['key'],
        "Summary": ticket['fields']['summary'],
        "Status": ticket['fields']['status']['name'],
        "Type": ticket['fields']['issuetype']['name'],
        "Priority": ticket['fields']['priority']['name'],
        "Assignee": ticket['fields']['assignee']['displayName'] if ticket['fields']['assignee'] else "Unassigned",
        "Updated": ticket['fields']['updated'],
        "Project": ticket['fields']['project']['name'],
    }
    return formatted_ticket

About this template

This app provides a weekly summary of completed Jira tasks. It requests the user's Jira domain, email, and API token, and uses the Jira API to download closed tickets from the past week. The query filters for tickets with the status 'Done' and last updated between the start and end of the current week.

Introduction to the Jira Weekly Summary Template

Welcome to the step-by-step guide on how to use the Jira Weekly Summary template. This template is designed to help you generate a report of all completed Jira tasks within the past week. It will request your Jira domain, email, and API token to access the Jira API and retrieve a list of closed tickets with the status 'Done' that were updated between the start and end of the current week. To get started, simply click "Start with this Template" on the Lazy platform.

External Integrations

Before you can use this template, you need to ensure that you have the following:

  • A Jira account with access to the projects you wish to report on.
  • An API token from Jira which will be used for authentication. You can generate an API token by following the instructions provided in the Atlassian documentation.

Once you have these details, you will be ready to proceed with using the template.

Using the Test Button and Providing User Input

After clicking "Start with this Template," you will use the Test button to begin the deployment of the app. The Lazy CLI will launch, and you will be prompted to enter the required user input:

  • Your Jira domain (e.g., "yourcompany" if your Jira instance is "yourcompany.atlassian.net").
  • Your email associated with your Jira account.
  • Your Jira API token.

Once you have provided this information, the template will interact with the Jira API to fetch the closed tickets and display them in a formatted manner.

Sample Request and Response

While the template itself does not directly expose an API endpoint, it does make requests to the Jira API. Here is an example of what the request and response might look like:

Sample Request:

This is handled internally by the template, but it essentially performs a GET request to the Jira API with a JQL query to fetch closed tickets.

Sample Response:

The response will be a JSON object containing the details of the closed tickets, which the template will then format and print out. Here's an example of what a single ticket might look like in the output:

{
    "Ticket ID": "10001",
    "Key": "PROJ-1",
    "Summary": "Fix login bug",
    "Status": "Done",
    "Type": "Bug",
    "Priority": "High",
    "Assignee": "Jane Doe",
    "Updated": "2023-03-01T12:00:00.000+0000",
    "Project": "Project Name"
}

Remember, you do not need to manually make these requests or handle the responses; the template will do this for you once you provide the necessary Jira credentials.

Conclusion

By following these steps, you will be able to use the Jira Weekly Summary template to generate a report of completed tasks in your Jira projects. This tool is designed to simplify your workflow and provide you with valuable insights into your team's progress over the week. If you encounter any issues or have further questions, please reach out for support through the Lazy platform.

Category
Technology
Last published
July 26, 2024

More templates like this

SecureUserAuthenticator

Develop a secure User Authentication system for users to register, log in, and manage their profiles, laying the foundation for user-specific data management and permissions in the CMS.

Laravel
Python
Flask
Javascript

Simple Multiplayer Telegram game

This app is a simple frontend for a game where users can upvote and downvote the most popular word in their country, learn about the flags of other countries, and view what other people voted for on a leaderboard.

Telegram
Python
Javascript

MP3ify: Youtube to MP3 Converter

A web application that allows users to download YouTube videos from URLs and provides the option to convert them to MP3 format.

Python
Flask
Home
/
Jira Weekly Summary