I've been attempting for days on how to authenticate using login credentials and trying to retrieve specific JSON data for transitions in Jira. Can someone please help me with this one? If anyone can give me any pointers on what library is easiest to use and how I can I easily parse the JSON. Thanks!!!
String username = "username";
String password = "password";
Authenticator userAuthenticator = new Authenticator(username, password);
String client = ClientBuilder.newClient()
.target("http://jira.corp.local:8080")
.register(HttpAuthenticationFeature.universalBuilder()
.credentialsForDigest(username, password)
.build())
.path("/rest/api/latest/issue/ORI-5714/transitions?expand=transitions.fields")
.request(MediaType.APPLICATION_JSON)
.get(String.class);
System.out.println(client);