Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

"No content to map to Object due to end of input" error when updating issue

lbanozic
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 10, 2019

Hello,

I'm trying to update an issue summary using Jira REST Java Client API with updateIssue method, and this is what I get in response:

{"errorMessages": ["No content to map to Object due to end of input"]}

Error: 

com.atlassian.jira.rest.client.api.RestClientException: [ErrorCollection{status=400, errors={}, errorMessages=[No content to map to Object due to end of input]}]

 

This is my code:

IssueRestClient issueClient = jiraClient.getRestClient().getIssueClient();

IssueInputBuilder issueInputBuilder = new IssueInputBuilder();
issueInputBuilder.setSummary("Test summary");

IssueInput issueInput = issueInputBuilder.build();

issueClient.updateIssue("MY-ISSUE-KEY", issueInput).claim();

 

Details:

1. I'm creating an issue using the same Jira Client API with no problems with createIssue method:

IssueRestClient issueClient = jiraClient.getRestClient().getIssueClient();

IssueInputBuilder issueInputBuilder = new IssueInputBuilder("MY-PROJECT-KEY", "MY-ISSUETYPE-ID");
issueInputBuilder.setSummary("Test summary");

IssueInput issueInput = issueInputBuilder.build();

BasicIssue basicIssue = issueClient.createIssue(issueInput).claim();

2. Calling a PUT method with Postman on my-company.atlassian.net/rest/api/latest/issue/MY-ISSUE-KEY with data {"fields" : {"summary": "Test summary"}} goes without any problems

3. My atlassian jira dependencies:

<dependency>
<groupId>com.atlassian.jira</groupId>
<artifactId>jira-rest-java-client-core</artifactId>
<version>5.0.4</version>
</dependency>

<dependency>
<groupId>com.atlassian.fugue</groupId>
<artifactId>fugue</artifactId>
<version>2.7.0</version>
</dependency>

 

I hope someone can help. Thanks!

 

Kind regards,

Luka

3 answers

0 votes
Ignacio A
Contributor
November 14, 2022

Hello, 

I'm having the same error with PUT /rest/api/2/user. I'm trying to deactivate users via API (Jira server 8.13, postgres).

This important guys, any answers?

0 votes
wangxueyuan
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 30, 2022

Same question. Why don't anyone anwser it?

0 votes
samridhi saxena
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 19, 2019

were you able to resolve the issue?

Suggest an answer

Log in or Sign up to answer