Get list of closed issues using JQL

Hello
i’m trying to get list of completed issues using :
/rest/api/3/search?jql=resolved is not EMPTY AND sprint={sprintId}

but i got some issues with the resolution field (won’t fix) or (won’t done) … it depends on wish instance i use
i’m wondring is there a solution to get issues not including the resolution field (won’t fix) or (won’t done) i mean only completed issues what ever is my instance
i hope that my question is clear

Cheers

@hamzabouallegue,

For Jira Cloud, I would recommend statusCategory = Done as the more precise way to express “closed issues”.

@ibuchanan
Thank you for responce
statusCategory = Done is not a good solution for me cause i have some issues that are really done but their statusCategory = in progress
that’s why i tried with resolved is not EMPTY
Any help please

@hamzabouallegue,

If not statusCategory = Done, then I don’t know what “really done” means to you.

If you have some workflows where statusCategory = Done doesn’t mean done, then those workflows will confuse Jira reporting and other features as well because that is what Jira expects internally as the “definition of done”. I don’t think you’ll get a different answer out of other Atlassians but maybe there are experienced app developers who have learned some better answer?