Linking issues to a story or a feature project using java jira client

pramod wadappi January 12, 2022

Hi All,

 

    I am using jira rest java client with the below maven dependency.

<dependency>
<groupId>com.atlassian.jira</groupId>
<artifactId>jira-rest-java-client-core</artifactId>
<version>${jira.client.version}</version>
</dependency>
<dependency>
<groupId>com.atlassian.fugue</groupId>
<artifactId>fugue</artifactId>
<version>${jira.fuge.version}</version>
</dependency>

I am able create stories. But I need help in linking the issues to the story. I tried below 

Issue initiative = issueClient.getIssue("EA-253").claim();
URI uri = initiative.getSelf();

issueLinkType= new IssueLinkType("Feature", "feature", IssueLinkType.Direction.OUTBOUND);
 
IssueLink link = new IssueLink(feature.getInitiative(),uri,issueLinkType);
newIssueBuilder.setFieldInput(new FieldInput(IssueFieldId.LINKS_FIELD,ComplexIssueInputFieldValue.with("issueLinks",link)));


B

B

but I am getting error as below 

Cannot generate value - unknown type for me: com.atlassian.jira.rest.client.api.domain.IssueLink 

 

Can somebody help me how to do it?

 

0 answers

Suggest an answer

Log in or Sign up to answer