Createmeta using jirapython

2.1k views Asked by At

Trying to know all the mandatory fields for an issue type Testcase in JIRA using the below statement

defined params as list with items projectIds, IssueType = Testcase, IssueType Id =

"jira._get_json('issue/createmeta', params)".

But i am not able to retrieve the fields output is alist with projects issuetypes, subtask, description, avatarUrls, key, Self, expand

Let me know is there any issue with statement I used or please post a way to retrieve all the mandatory fields for specific issue type using jira python

1

There are 1 answers

0
Fr3dBear On

The way I have been doing this for specific fields:

    issue = jira.issue(TestCase)
    issue_type_name = issue.fields.issuetype.name
    issue_type_id = issue.fields.issuetype.id

Another way to do this getting all the meta is:

    issue = jira.issue(TestCase)
    print(issue.raw)

or

    jira.createmeta(projectKeys='TestCaseProject', projectIds=['TestCase'],expand=None)

Source: http://pythonhosted.org/jira/