jira-client icon indicating copy to clipboard operation
jira-client copied to clipboard

net.rcarz.jiraclient.JiraException: Project 'projectName' or issue type 'Bug' missing from create metadata. Do you have enough permissions?

Open SHASHI2208 opened this issue 5 years ago • 8 comments

Hi Team,

I am strugglig when i am calling to createIssue(String projectName, String issueType) Below is the sample code: BasicCredentials creds = new BasicCredentials("xyz", "pqr"); JiraClient jira = new JiraClient("RESTURL", creds);

FluentCreate newIssue = jira.createIssue("PROJECTNAME", "Bug"); //FluentCreate newIssue = jira.createIssue(String projectName, String issueType);

Note: I am sending String values in jira.createIssue(String, String) And i can update existing issue or all getMethods.

But when i am selecting project or create new issue getting below error:

net.rcarz.jiraclient.JiraException: Project 'projectName' or issue type 'Bug' missing from create metadata. Do you have enough permissions?

Please let me know if you need more information.

Thanks, Shashi

SHASHI2208 avatar Mar 20 '19 10:03 SHASHI2208

Hi @SHASHI2208 @rcarz ,, Did you find any solution? if yes please share. image

ghost avatar Jun 29 '19 16:06 ghost

Facing a similar issue. Did you get the fix? Thanks!

piyushbajaj0704 avatar Mar 27 '20 23:03 piyushbajaj0704

any news on this?

vzenzo avatar Apr 11 '20 23:04 vzenzo

@vzenzo I resolved this issue when I contacted my JIRA admin and it was indeed the permission issue with my JIRA API account. He reset my account and it was good to go.

piyushbajaj0704 avatar Apr 12 '20 00:04 piyushbajaj0704

@vzenzo I resolved this issue when I contacted my JIRA admin and it was indeed the permission issue with my JIRA API account. He reset my account and it was good to go.

thanks will try this tomorrow and let you know, I hope that is the only problem.

vzenzo avatar Apr 13 '20 14:04 vzenzo

Instead of this process I used API services call to create bug with json request

SHASHI2208 avatar Apr 13 '20 16:04 SHASHI2208

I had the same issue due to a mistake I did in the api call. I just want to share it, in case someone else does the same mistake like me.

I accidentally used as project key the project name in my request. If you face the same error message, try if the following request gives any results: http://localhost:8080/rest/api/2/issue/createmeta

If you don't get results you have a permission error, if you get all the projects as result listed then check your subset-parameters.

Princeptus avatar Feb 15 '21 13:02 Princeptus

I faced the same issue, and I fixed it simply by regenerating and updating my Jira API token key. So, I suggest to everyone who sees the same problem:

  1. Check and update your Jira password or
  2. If you use Jira cloud, update your API token by generating a new one

Anassatti avatar May 30 '22 10:05 Anassatti