Apps documentation
Requirements and Test Management for Jira
Cloud Server/Data Center
Requirements and Test Management for Jira

Cloud

Server/Data Center

Documentation
FAQ
Release notes
Articles & Videos
Last updated Mar 5, 2021

Example of use

How to create a new Test Case via API v1

{
  "projectKey": "TEMP",
  "summary": "Create TC Edit with ID",
  "description": "desc",
  "preconditions": "pre1",
  "labels": [
    "Frontend",
    "Backend"
  ],
  "assigneeId": "{{assigneeId}}",
  "components": [
    {
      "id": "10000"
    }
  ],
  "versions": [
    {
      "id": "10000"
    }
  ],
  "environment": "dhdh",
  "priority": {
    "id": 1
  },
  "coveredRequirements": [
    "{{ReqTestKey}}"
  ],
  "timeEstimate": 3,
  "testKey": "newtestkeyd",
  "steps": [
    [
      {
        "value": "step1"
      },
      {
        "value": "step2"
      },
      {
        "value": "step3"
      }
    ],
    [
      {
        "groupName": "stepgroup"
      }
    ]
  ],
  "links": [
    {
      "testKey": "newtestkeyd"
    }
  ]
}

How to create a new Test Case via API v2

{
  "projectKey": "TEMP",
  "summary": "Create TC" ,
  "description": "content of description",
  "preconditions": "pre1",
  "labels": ["Frontend", "Backend"],

  "components": [
    {"name": "ComponentName"}
  ],
  "versions": [
    {"name": "VersionName"}
  ],
  "environment": "rtm1",
  "priority": {
    "name": "Lowest"
  },
  "coveredRequirements": [
    {
      "testKey": "{{ReqTestKey}}"
    }
  ],
  "parentTestKey": "{{TestCasesParentFolder}}",

  "stepGroups": [
    {
      "name": "name of group",
      "steps": [
        {
          "stepColumns": [
            {
              "ordinal": "1",
              "value": "content of column 1"
            },
            {
              "ordinal": "2",
              "value": "content of column 2"
            },
            {
              "ordinal": "3",
              "value": "content of column 3"
            }
          ],
          "stepAttachments": [
            {
              "attachmentId": idAttachment
            }
          ]
        }
      ]
    }
  ]
}
Tip

The ordinal's value determines the step’s order. You can decide how to organize Test steps by setting up own values. It’s also possible to add an attachment to the Test Case step. Simply enter an attachment’s ID in stepAttachments.

Operation SET - generates an exact set of links indicated in the payload

{
  "coveredRequirements": {
    "set": [
      {
        "testKey": "{{ReqTestKey2}}"
      }
    ]
  }
}

Operation ADD - adds links indicated in the payload

{
  "coveredRequirements": {
    "add": [
      {
        "testKey": "{{ReqTestKey2}}"
      }
    ]
  }
}

Operation REMOVE - deletes links indicated in the payload

{
  "coveredRequirements": {
    "remove": [
      {
        "testKey": "{{ReqTestKey2}}"
      }
    ]
  }
}
Note

In case of leaving the SET/ADD/REMOVE playload empty, the set operation will be applied. It means that:

  • links which are not defined in the new playload will be removed
  • existing links will stay the same
  • new links will be added.

How to set up a Components field

It’s possible to set up the Components using their id as well as name:

 "components": [
{"name": "{{ComponentName}}"}
],
 "components": [
{"id": "{{ComponentId}}"}
],

How to set up a Priority field

It’s possible to set up the Priority using their id as well as name:


"priority": [
{"name": "{{PriorityName}}"}
],
 "priority": [
{"id": "{{PriorityId}}"}
],

How to set up Test Steps via API v1

Rows are defined as a list of the objects: {'value':'cellValue'}.

Groups are defined as objects with the attribute “groupName”: {'groupName':'cellValue'}.

"steps": [
[{"value": "row1_cell_1"}, {"value": "row1_cell_2"}, {"value": "row1_cell_3"}],
[{"groupName": "updatestepgroup"}],
[{"value": "row1_cell_1"}, {"value": "row1_cell_2"}, {"value": "row1_cell_3"}],
]

How to set up Test Steps via API v2


"stepGroups": [
{
"name": "name of group",
"steps": [
{
"stepColumns": [
{
"ordinal": "1",
"value": "content of column 1"
}, {
"ordinal": "2",
"value": "content of column 2"
}, {
"ordinal": "3",
"value": "content of column 3"
}
]
}
]
}
]
Tip
The ordinal's value determines the step’s order. You can decide how to organize Test steps by setting up own values.