Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

how can i get last 5hr data

Megha Jb
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 21, 2020

Hi,

 

I am new to this. My script is as shown below. please help me to get last 5Hrs updated ticket details

from jira import JIRA
jira = JIRA('https://jira.spring.io')
block_size = 1000
block_num = 0
allissues = []
while True:
start_idx = block_num*block_size
issues = jira.search_issues('project=XD', start_idx, block_size)
if len(issues) == 0:
# Retrieve issues until there are no more to come
break
block_num += 1
for issue in issues:
#log.info('%s: %s' % (issue.key, issue.fields.summary))

1 answer

0 votes
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 21, 2020

You should use a REST call that is a search for issues, including a call for "and updated > -5h"

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events