How to get Inactive user AccountId via Rest API, we have a usecase wherein we check if Jira User exists else create Jira user and create JSM record using Jira User-Account Id.
You can search the user endpoint API and do filtering of users whose "active" key is false. However, a user being inactive doesn't mean they exist as part of your user list or user base (i.e. if you have Jira Software and Jira Service Management applications). They could have been deleted from your instance and are in a residual state. So depending on either way, when checking by creation, you can get the information you want if they are truly inactive status.
Fetching all users with active key "false" will give thousands of records, finding the exact record from those thousand records will not be a feasible option. Is there any endpoint API which gets Account Id of the employee via email address even if he is Inactive?
If he is deleted, we will create a new one.