I am currently making a custom JIRA plugin to fetch the issue-level permissions. Is there any java API through which we can get issue-level permissions for a particular issue?
There are GlobalPermissionManager and PermissionManager interfaces, you likely would want the latter, and it should contain methods in it to perform permission validations:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.