How to check if a list of issues is editable via REST API?

You can use the Jira expressions REST API to query for issue data based on a JQL query – it has a page size of 1000, so the number of requests would be reduced tenfold.

Here is an example request:

  "expression": "issues.map(i => { issueId: i.id, statusId: i.status.id, projectId: i.project.id })",
  "context": {
    "issues": {
      "jql": {
        "query": "order by id",
        "startAt": 0
      }
    }
  }
}

The response will be something like:

{
  "value": [
    {
      "issueId": 10027,
      "statusId": 10005,
      "projectId": 10006
    },
    {
      "issueId": 10028,
      "statusId": 10005,
      "projectId": 10006
    },
    ...
  ],
    "issues": {
      "jql": {
        "startAt": 0,
        "maxResults": 1000,
        "count": 1000,
        "totalCount": 4500
      }
    }
  }
}

Other than that, it’s a bit surprising that checking the issue edit permission for a particular issue doesn’t take the workflow into account. You might want to raise this is a bug in the ACJIRA project.

1 Like