I cannot find anywhere the documentation on how to use the jira-rest-java-client-api
(https://maven.artifacts.atlassian.com/com/atlassian/jira/jira-rest-java-client-api/7.0.1/)
I have tried to generate the client myself using swagger codegen but there are a lot of problems and compilation errors, so I am trying to use the client generated by Atlassian.
Any help is very appreciated.
Thank you all for your replies.I was building for cloud and not server/datacenter. I have managed somehow.I generated myself the client using the swagger file, but it is not that straightforward process. I had to modify the swagger file and also swagger codegen is not working, so I used the openapi one.Also needed to amend some generated classes because they were wrong. For example the Project pojo was missing a field and the api call was failing due to the Json parsing exception.Thank you again.
Hello @Francesco Raccuglia Welcome to the community.
Can you also post on the developer community, hope you can get help there.
https://community.developer.atlassian.com/
can we integrate it in all kind of situations
Hi @Francesco Raccuglia
Welcome to the community.
Within Jira cloud there is no JAVA API
The Java API is only for Server/DC
I managed to generate the java client using atlassian specifications file at https://developer.atlassian.com/cloud/jira/platform/swagger-v3.v3.json (after some tweaking as stated here: https://community.atlassian.com/forums/Jira-articles/Generating-a-REST-client-for-Jira-Cloud/ba-p/1307133Now I am looking for documentation on how to use this client but is nowhere to be found, that's why I tried to use the jar I mentioned earlier, but there is no documentation for it.
thanks in advance.
The rest java api you found is a server/DC one. This own't work with Cloud.
For more info on the swagger, see the developer community
Nice
Can you outline your steps, others may find this very useful as well?
Not easy to summarize 'cause I spent quite sometime to get it working.In short what worked for me was:
I found it disappointing that I had to manually modify the Swagger file in order to generate a usable client. The main value of having a Swagger/OpenAPI specification is to serve as a single source of truth from which clients can be reliably generated. If manual changes are required before generation, it defeats much of the purpose of providing a Swagger file in the first place. Moreover, it does not seem that all the endpoints were ever tested to ensure they work correctly with the generated client, which further undermines the usefulness of the specification.
It looks like you're new here. Sign in or register to get started.